Skip to content
This repository has been archived by the owner on Sep 16, 2022. It is now read-only.

Commit

Permalink
CSCMETAX-61: [ADD] New python dependency versions. New flake8 version…
Browse files Browse the repository at this point in the history
… complaints fixed
  • Loading branch information
junsk1 committed Oct 30, 2018
1 parent b8d8240 commit c80027a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .flake8
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,8 @@ ignore =
E128
# do not use bare except
E722
# line break after binary operator
W504

# often contains "unused" imports, too long lines (generated files), and such
exclude = __init__.py,src/metax_api/migrations/*,src/static,swagger/*
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
coveralls==1.5.1 # code coverage reportin in travis
datacite==1.0.1 # BSD-license. convert datasets to datacite xml. datacite metadata store api wrappers
dicttoxml==1.7.4
python-dateutil==2.7.3
python-dateutil==2.7.5
Django==2.1.2 # BSD-license
elasticsearch<6.0.0
hiredis==0.2.0 # Used by redis (redis-py) for parser
djangorestframework==3.9.0 # BSD-license
django-rainbowtests==0.6.0 # colored test output
flake8==3.5.0 # MIT-license
flake8==3.6.0 # MIT-license
gevent==1.3.7 # gunicorn dep
gunicorn==19.9.0 # MIT-license
ipdb==0.11 # dev tool
Expand Down
2 changes: 1 addition & 1 deletion src/metax_api/api/rest/base/views/file_view.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@

# i.e. /rest/v6/files, but must NOT end in /
# or: /rest/files, but must NOT end in /
RE_PATTERN_FILES_CREATE = re.compile('^/rest/(v\d/)?files(?!/)')
RE_PATTERN_FILES_CREATE = re.compile(r'^/rest/(v\d/)?files(?!/)')


# none of the methods in this class use atomic requests by default! see method dispatch()
Expand Down
4 changes: 2 additions & 2 deletions src/metax_api/services/datacite_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -353,8 +353,8 @@ def _spatials(spatials):
for wkt in spatial.get('as_wkt', []):
if wkt.startswith('POINT'):
geo_location['geoLocationPoint'] = {
'pointLongitude': float(re.search('POINT\((.*) ', wkt, re.IGNORECASE).group(1)),
'pointLatitude': float(re.search(' (.*)\)', wkt, re.IGNORECASE).group(1)),
'pointLongitude': float(re.search(r'POINT\((.*) ', wkt, re.IGNORECASE).group(1)),
'pointLatitude': float(re.search(r' (.*)\)', wkt, re.IGNORECASE).group(1)),
}
# only one point can be placed
break
Expand Down

0 comments on commit c80027a

Please sign in to comment.