-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade to Python3 and disable the old admin interface #3027
Conversation
docker/build/Dockerfile
Outdated
@@ -1,4 +1,4 @@ | |||
FROM python:2 | |||
FROM python:3 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3.5
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not 3.6?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because 3.6 is not available on Debian stable, and we want the same version every where :-)
docker/build/Dockerfile
Outdated
@@ -25,6 +25,6 @@ COPY run /usr/bin/ | |||
|
|||
WORKDIR /src | |||
|
|||
ENV PYTHONPATH /build/venv/lib/python2.7/site-packages/ | |||
ENV PYTHONPATH /build/venv/lib/python3.6/site-packages/ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
3.5
c2cgeoportal/scripts/urllogin.py
Outdated
@@ -46,10 +47,11 @@ def create_token(aeskey, user, password, valid): | |||
exit(1) | |||
cipher = AES.new(aeskey) | |||
data = json.dumps(auth) | |||
print(type(data)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
remove
c2cgeoportal/views/entry.py
Outdated
@@ -240,6 +240,7 @@ def _wms_getcap_cached(self, url, auth, role_id): | |||
|
|||
try: | |||
resp, content = http.request(url, method="GET", headers=headers) | |||
content.decode("utf-8") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
useless
c2cgeoportal/views/entry.py
Outdated
@@ -1133,6 +1134,7 @@ def _external_themes_role(self, interface, role_id): # pragma nocover | |||
|
|||
try: | |||
resp, content = http.request(ext_url, method="GET", headers=headers) | |||
content.decode("utf-8") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
useless
Disable api and related language checks
1c09371
to
dbc3f0e
Compare
bb0eaf1
to
69c9499
Compare
c2cgeoportal/lib/__init__.py
Outdated
@@ -220,23 +221,19 @@ def get_typed(name, value, types, request, errors): | |||
|
|||
|
|||
def add_url_params(url, params): | |||
if len(params.items()) == 0: | |||
if len(list(params.items())) == 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can be simplified to if len(params) == 0:
No description provided.