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

Latest arcade 2.6.17 requires pyglet 2.0.dev23 #2358

Open
cdeil opened this issue Aug 31, 2024 · 7 comments
Open

Latest arcade 2.6.17 requires pyglet 2.0.dev23 #2358

cdeil opened this issue Aug 31, 2024 · 7 comments
Labels

Comments

@cdeil
Copy link

cdeil commented Aug 31, 2024

This is the latest stable version of arcade: https://pypi.org/project/arcade/2.6.17/

The wheel on PyPI declares that it requires pyglet development version: 2.0.dev23

This causes https://pixi.sh/ to install by default a broken older arcade version 2.3 if I use pixi add --pypi arcade and import arcade.

Trying to install specifically the latest stable version:

$ pixi add --pypi 'arcade==2.6.17'               
  × failed to solve the pypi requirements of 'default' 'osx-arm64'
  ├─▶ failed to resolve pypi dependencies
  ╰─▶ Because there is no version of pyglet==2.0.dev23 and arcade==2.6.17 depends on pyglet==2.0.dev23, we can conclude that arcade==2.6.17 cannot be used.
      And because you require arcade==2.6.17, we can conclude that your requirements are unsatisfiable.
      
      hint: pyglet was requested with a pre-release marker (e.g., pyglet==2.0.dev23), but pre-releases weren't enabled (try: `--prerelease=allow`)

I see here that a stable version of pyglet is available: https://pypi.org/project/pyglet/2.0.17/

Could you please release a newer version of arcade that fixes this dependency to the stable one so that install "just works"?

@pushfoo
Copy link
Member

pushfoo commented Sep 1, 2024

TL;DR: Based on the pixi bug you filed, it seems pixi may have issues with Arcade's upcoming 3.0 release and its dev previews.

What you've proposed is worth considering. However, my understanding is:

  • It requires both Arcade 3.0 and pyglet 2.1 to finish their release cycles
  • It's difficult because pyglet dev previews allow us to quickly incorporate our ongoing pyglet fixes

Since it's worth verifying prefix-dev/pixi#1357 further, can you try installing arcade==3.0.0.dev34 with pixi? Based on my reading of your bug, it might fail because:

  1. pixi lacks support for dev preview packages in any form
  2. Arcade's development branch currenly uses a dev preview of pyglet 2.1
    'pyglet==2.1.dev5',

@cdeil
Copy link
Author

cdeil commented Sep 2, 2024

Hi, yes, pixi currently lacks support for dev preview releases from PyPI, that's an open feature request to them to add this support.

This request is independent though for you with Arcade to create a new release that uses stable and not dev versions though.

So you're aiming directly for a 3.0 release and the 2.x series is completely frozen I gather? Is it possible to give an ETA (weeks / months)?

@pushfoo
Copy link
Member

pushfoo commented Sep 7, 2024

Update: So far, there doesn't seem to be much opposition to a final 2.6.18

Recap of the Discord discussion:

  1. A final 2.6.X release could be useful ahead of 3.0
  2. It may be good to add a warning at the top of each page linking the /latest doc if possible
  3. We need to do a few tasks to make 2.6.18 possible

The tasks as I understand them:

  • Bump the experimental 3.12 compat branch with:
    • the latest pyglet 2.0.X pyglet from its current 2.0.10
    • "Pillow just need a couple of lines change I think related to flipping an image" (Discord link)
    • Pymunk 6.8.1 appears drop-in compatible
  • "We force old style win fonts for compatibility" (setting a config value on pyglet in our init) (Discord link)
  • Resolve lingering unit test failures
    • Resolve new non-hitbox failures
    • Verify that hitbox failure exists in 2.6.17 release tag
  • Figure out what Sphinx and config updates are necessary to get it to build
    • Don't run doc build on 3.12+ of cython + pyyaml get ugly
    • Bump to Sphinx 5.4.0
    • Verify that Pillow 10.4.0 doesn't break Sphinx
  • Close look at doc for:
    • HTML
    • epub
    • PDF
  • Test the Arcade code thoroughly (@cdeil, would you be up for helping?):
    • Linux
    • Intel Mac
    • ARM Mac
    • Windows

@cdeil
Copy link
Author

cdeil commented Sep 8, 2024

Wow, thanks. :-)

I am interested in helping. But realistically unfortunately I will only manage to spend an hour rarely. So please don't count on it and decide just what you prefer to do.

For now I changed to Python 3.11 and just using pip and then did the platformer tutorial and everything worked. :-)

So I think the full support for newer Python 3.12 and modern more strict package managers pixi / uv could also just come with Arcade 3.0 if you prefer to put your time into getting that done. For me as complete newbie to Arcade and game development just wanting to get started with two kids in the next weeks doing the platformer tutorial that is even nicer since I don't have old Arcade code and get the even nicer package. So if you go that way to focus on Arcade 3.0 I would read the docs and help test / contribute a bit there in the coming weeks.

Is it possible to change your dependency management to the usual style moving forward of only using stable releases of pyglet and just cutting stable releases there more often as needed to get fixes/improvements out?

Try to get rid of this linking to pyglet dev versions?

'pyglet==2.1.dev5',

@pushfoo
Copy link
Member

pushfoo commented Sep 10, 2024

TL;DR: I updated the tasks above, ty please help test 3.0, I also want stable releases in the future

Note: some of this comment may re-iterate / expand on my earlier comment to act as easy reference.

2.6.X vs 3.0?

just wanting to get started with two kids in the next weeks doing the platformer tutorial

The 1st party book teaching Python has a lesson plan you may find helpful, but it hasn't been updated for 3.0 like the Platformer Tutorial.

The fact the book and other non-core materials need to be updated separately is a major reason for considering a 2.6.18 release, especially since I'm not sure on what the timeline for updating the book is. The book's author (and Arcade's creator) isn't currently teaching as far as I know.

So I think the full support for newer Python 3.12 and modern more strict package managers... could also just come with Arcade 3.0 if you prefer to put your time into getting that done.

Since we also may want to add warnings to the 2.6.X doc, I've updated the task list in my earlier comment with points einarf raised on Discord.

Help with 3.0

So if you go that way to focus on Arcade 3.0 I would read the docs and help test / contribute a bit there in the coming weeks.

I appreciate the offer! If you're still planning on using 3.0 (or 2.6.18 doesn't work out):

  1. What operating systems do you have?
  2. Are any of them HiDPI Windows systems? (Enable HiDPI scaling on Windows by default #2361)

Regardless of the answers to those questions, we'll need proofreading for the 3.0 Platformer Tutorial. It's a rewrite to account for changes such as the brand new camera system, and that means there'll be rough edges to smooth out.

Stuff like a porting guide and (maybe) a 2to3-like utility may arrive incrementally after 3.0. Input on those would also be appreciated.

"Stable" releases?

Is it possible to change your dependency management to the usual style moving forward of only using stable releases of pyglet

My current personal opinion is:

  1. Starting to do "Stable" releases has merits beyond just compatibility with pixi
  2. We can't totally eliminate the dev releases:
    • Arcade's sort of a testing ground for pyglet features
    • It may become more of one since our strongest graphics devs have expressed interest in deduping our GL stack in favor of pyglet's
  3. I don't know what a good schedule would be for stable releases

Since I don't control the PyPI package, my opinion isn't the one that matters.

@pushfoo
Copy link
Member

pushfoo commented Oct 1, 2024

Update on this:

  1. The failing bounds check unit test was failing in the 2.6.17 release tag
  2. For end users, it looks like unit tests + the pymunk joint builder work with:
    • Pillow 10.4.0 to get the latest sec patches (buffer overflows, etc)
    • Pymunk 6.8.1 for speed optimzations
  3. Things get ugly with doc build
  4. We may want to quick-patch in arcade.gui UIManager (ui_manager.py) clear methods does not remove all widgets from the UImanager #2374 since that's ugly but easy to fix

@pushfoo
Copy link
Member

pushfoo commented Oct 4, 2024

Update: discovered a doc resource embed issue, started fixing it.

The ticket is #2387 (binding development breaks prior doc versions):

  • A rough proof of concept is on the 2.6-py-312 branch
  • It probably still needs refinement ahead of a release
  • development will likely need slightly different fixes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants