Skip to content

Commit

Permalink
Merge pull request #1199 from cutwater/fix/compatibility-python3
Browse files Browse the repository at this point in the history
Fix python 3 compatibility
  • Loading branch information
cutwater authored Oct 15, 2018
2 parents df9477a + 57d11d4 commit d5cff5d
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions galaxy/api/views/notification.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@
import logging

from hashlib import sha256
from urlparse import urlparse

import requests
from six.moves.urllib import parse as urlparse

from OpenSSL import crypto
from django.conf import settings
from django.db import IntegrityError
Expand Down
1 change: 1 addition & 0 deletions galaxy/importer/utils/git.py
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ def make_clone_dir(basedir=None):
# Note(cutwater): Suppress exception if directory
# has been deleted already.
if e.errno != errno.ENOENT:
# noinspection PyCompatibility
raise


Expand Down
5 changes: 4 additions & 1 deletion galaxy/main/mixins.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@
# You should have received a copy of the Apache License
# along with Galaxy. If not, see <http://www.apache.org/licenses/>.

import six


__all__ = ['DirtyMixin']


Expand All @@ -29,7 +32,7 @@ def __init__(self, *args, **kwargs):
@property
def is_dirty(self):
missing = object()
for key, value in self._original_state.iteritems():
for key, value in six.iteritems(self._original_state):
if value != self.__dict__.get(key, missing):
return True
return False
Expand Down

0 comments on commit d5cff5d

Please sign in to comment.