launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #25716
[Merge] ~pappacena/turnip:py3-repo-creation-check into turnip:master
Thiago F. Pappacena has proposed merging ~pappacena/turnip:py3-repo-creation-check into turnip:master with ~pappacena/turnip:py3-http-protocol-version as a prerequisite.
Commit message:
Python3 compatibility for repository creation check
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
For more details, see:
https://code.launchpad.net/~pappacena/turnip/+git/turnip/+merge/394373
--
Your team Launchpad code reviewers is requested to review the proposed merge of ~pappacena/turnip:py3-repo-creation-check into turnip:master.
diff --git a/Makefile b/Makefile
index 8ef2a72..a47e5aa 100644
--- a/Makefile
+++ b/Makefile
@@ -102,7 +102,6 @@ check: pip-check test lint check-python3-partial
check-python3-partial:
$(MAKE) build VENV_ARGS="-p python3" ENV="$(PY3_ENV)"
# XXX: Tests not passing on python3 yet:
- # turnip.pack.tests.test_functional.TestSmartHTTPFrontendFunctional
# turnip.pack.tests.test_functional.TestSmartHTTPFrontendWithAuthFunctional
$(PY3_ENV)/bin/python -m unittest \
turnip.api.tests.test_api \
@@ -116,7 +115,8 @@ check-python3-partial:
turnip.pack.tests.test_ssh \
turnip.pack.tests.test_functional.TestBackendFunctional \
turnip.pack.tests.test_functional.TestGitFrontendFunctional \
- turnip.pack.tests.test_functional.TestSmartSSHServiceFunctional
+ turnip.pack.tests.test_functional.TestSmartSSHServiceFunctional \
+ turnip.pack.tests.test_functional.TestSmartHTTPFrontendFunctional
check-python3:
$(MAKE) check VENV_ARGS="-p python3" ENV="$(PY3_ENV)"
diff --git a/turnip/pack/git.py b/turnip/pack/git.py
index b795616..854c385 100644
--- a/turnip/pack/git.py
+++ b/turnip/pack/git.py
@@ -760,8 +760,8 @@ class PackVirtServerProtocol(PackProxyServerProtocol):
the repository if it doesn't exist.
"""
creation_params = translated_path.get("creation_params")
- is_stateless_rpc = params.get('turnip-stateless-rpc')
- is_advertise_ref = params.get('turnip-advertise-refs')
+ is_stateless_rpc = params.get(b'turnip-stateless-rpc')
+ is_advertise_ref = params.get(b'turnip-advertise-refs')
is_write = permission == 'write'
should_create = not is_stateless_rpc or (is_advertise_ref and is_write)
if creation_params and should_create:
Follow ups