OpenTreeMap is a collaborative platform for crowdsourced tree inventory, ecosystem services calculations, urban forestry analysis, and community engagement.
NOTE: ~This PR is currently has its base set tofeature/provision-py3. When that branch is merged into python3 the base for this PR should be set to python3~ The base for this branch is set to our long-running python3 branch.
Overview
A preliminary set of changes to the Python codebase that begin the conversion from Python 2 to Python 3. The application is not functional after these changes, but we want to avoid creating one massive PR that is difficult to review.
Connects #3284
Notes
These are the high-level tasks covered by the commits in this PR.
Run 2to3 and commit the results
Fix errors reported by flake8
Fix the first error blocking tests from running successfully
Add migrations required after reformatting model field choice lists.
See the individual commit messages for more detail.
Testing Instructions
Check out the feature/provision-py3 branch of otm-cloud
Check out the feature/2to3 branch of otm-addons
Run vagrant provision app
From your host run flake8 using the command below and verify that the only output is a FutureWarning (which will be resolved when we update to a new version of flake8).
NOTE: ~This PR is currently has its base set to
feature/provision-py3
. When that branch is merged intopython3
the base for this PR should be set topython3
~ The base for this branch is set to our long-runningpython3
branch.Overview
A preliminary set of changes to the Python codebase that begin the conversion from Python 2 to Python 3. The application is not functional after these changes, but we want to avoid creating one massive PR that is difficult to review.
Connects #3284
Notes
These are the high-level tasks covered by the commits in this PR.
2to3
and commit the resultsflake8
See the individual commit messages for more detail.
Testing Instructions
feature/provision-py3
branch ofotm-cloud
feature/2to3
branch ofotm-addons
vagrant provision app
FutureWarning
(which will be resolved when we update to a new version offlake8
)../scripts/manage.sh shell_plus
and verify that the application loads without error.Checklist
fixup!
commits have been squashed