Skip to content
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

Drop Python2.7 support #1395

Closed
9 tasks
ssteinbach opened this issue Sep 15, 2022 · 5 comments · Fixed by #1423
Closed
9 tasks

Drop Python2.7 support #1395

ssteinbach opened this issue Sep 15, 2022 · 5 comments · Fixed by #1423
Labels
maintenance General cleanup and good code hygiene needs discussion python Pull requests that update Python code

Comments

@ssteinbach
Copy link
Collaborator

ssteinbach commented Sep 15, 2022

As noted by #1094, VFX platform 2019 is the last VFX platform that includes python 2.7. This issue is to prepare for when we drop python 2.7 support.

  • update check in setup.py:
  • update README.md
  • update files that reference 2.7, especially places marked # python2 or # python 2.7 (this is a rough list from grep)
tests/test_builtin_adapters.py
tests/test_console.py
tests/test_timeline.py
tests/test_cmx_3600_adapter.py
tests/test_otioz.py
tests/test_adapter_plugin.py
tests/baselines/plugin_module/otio_mockplugin/__init__.py
tests/test_hooks_plugins.py
tests/test_examples.py
contrib/opentimelineio_contrib/adapters/tests/test_hls_playlist_adapter.py
src/py-opentimelineio/opentimelineio/adapters/file_bundle_utils.py
src/py-opentimelineio/opentimelineio/adapters/otiod.py
src/py-opentimelineio/opentimelineio/adapters/fcp_xml.py
src/py-opentimelineio/opentimelineio/url_utils.py
  • update .github/workflows/python-package.yml - python-package.yml
  • update pybind11 to 2.10+
  • try pyupgrade to move to newer syntax where available
@ssteinbach ssteinbach added bug A problem, flaw, or broken functionality. needs discussion maintenance General cleanup and good code hygiene python Pull requests that update Python code and removed bug A problem, flaw, or broken functionality. labels Sep 15, 2022
@JeanChristopheMorinPerso
Copy link
Member

Do we also want to update the code base to use newer syntax? If so then we can use https://github.com/asottile/pyupgrade to automatically upgrade code to use newer syntax. It also handles changing imports, and a bunch of different things. When running the tool, you basically tell it to target a specific Python version and it will take care of the rest.

@JeanChristopheMorinPerso
Copy link
Member

We might also want to update Pybind11 to 2.10+.

@meshula
Copy link
Collaborator

meshula commented Sep 17, 2022

it would be interesting to try pyupgrade and see what happens, and yes we'll want to update pybind11 to latest. we've been frozen for a whle

@ssteinbach
Copy link
Collaborator Author

@JeanChristopheMorinPerso great suggestion. It sounds like we want to do this after making release 0.15.0.

@ssteinbach ssteinbach added this to the Public Beta 16 milestone Sep 17, 2022
@ssteinbach
Copy link
Collaborator Author

(I added your notes as todo list items)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance General cleanup and good code hygiene needs discussion python Pull requests that update Python code
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants