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

Core, CI: Add Python 3.12 support #3290

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

black-sliver
Copy link
Member

What is this fixing or adding?

Add/fix Python 3.12 support. and use 3.12 in CI

  • Use a pony fork that works with 3.12 (Unit tests there look all good)
  • Need to fix Stardew's use of deprecated assertEquals since it's now gone
  • Slight change to ModuleUpdate.py because Python 3.12's ensure_pip does not ship pkg_resources anymore and some tests would fail because they import ModuleUpdate without --yes.

Stardew and ModuleUpdate could be cherry-picked if we want to give upstream pony more time.

How was this tested?

  • Unit tests
  • Generate of one multi
  • Upload of one game to an empty WebHost and checked user-content - I did not check for DB "upgrade" since I deleted my local DB recently.

@github-actions github-actions bot added affects: core Issues/PRs that touch core and may need additional validation. affects: webhost Issues/PRs that touch webhost and may need additional validation. waiting-on: peer-review Issue/PR has not been reviewed by enough people yet. labels May 12, 2024
Copy link
Collaborator

@agilbert1412 agilbert1412 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stardew changes are totally fine.
Other changes look okay, but my expertise is low so I wouldn't put much weight on that approval

Copy link
Collaborator

@remyjette remyjette left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Created a Python 3.12.3 venv in Windows, tested

  • Webhost: launching the webhost which didn't work before sending a location, making sure the tracker updated, closing and relaunching the server to validate the load from the savefile. Didn't see any errors in the log, no warnings other than options deprecations
  • Generate: Just did a simple clique generate and looked for errors in the log. Didn't see any. Only warnings were again options deprecations.
  • Kivy: Ran the launcher, checked the logs for any Kivy errors, didn't see any. Opened the text client, connected to a slot, still didn't see any errors.

@Exempt-Medic Exempt-Medic added the is: maintenance Regular updates to requirements and utilities that do not fix bugs or change/add features. label May 14, 2024
@beauxq
Copy link
Collaborator

beauxq commented May 15, 2024

docs/running from source.md has some lines that say "Python 3.12 is currently unsupported"
I don't know if we want to remove them or change them or change them to 3.13
I don't like the idea of having to change more things in more places with every version change, so I think probably remove.

@black-sliver
Copy link
Member Author

I think it is still undecided how we are going to handle this exactly once we drop 3.8, but kivy sometimes being slow to update might be a problem regardless of our plans, so I think the versions should be mentioned explicitly. We had a bunch of people that were on unsupported python versions and didn't know.

My personal preference would be to roughly follow github ubuntu-latest python for the oldest, which changes around the time when the latest Ubuntu LTS gets its point 1 release. And bleeding edge for the newest. I use arch btw. This is hard to put into words if we don't know when our dependencies will update.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
affects: core Issues/PRs that touch core and may need additional validation. affects: webhost Issues/PRs that touch webhost and may need additional validation. is: maintenance Regular updates to requirements and utilities that do not fix bugs or change/add features. waiting-on: peer-review Issue/PR has not been reviewed by enough people yet.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants