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 support for Python 3.8 and replace pkg_resources with importlib.resources #28

Merged
merged 10 commits into from
Feb 11, 2025

Conversation

luisfelipec95
Copy link
Contributor

Description

  • Dropped support for Python 3.8
  • Upgrade requirements
  • Replace pkg_resources lib with importlib.resources:

pkg_resources (from setuptools) is deprecated and will be removed in future Python versions.
The new implementation uses importlib.resources, which is the recommended alternative and is fully available in Python 3.9+.

Testing instructions

1, Create a Sumac environment using Tutor or TVM.
2. Install xblock-imagesgallery using this branch you can follow the official tutor documentation.
3. In a course of study:
Navigate to Settings -> Advanced Settings and go to Advanced Module List settings.
Add:
image
4. Create Unit -> Advance ->imagesgallery

Other Information

openedx/public-engineering#273

@luisfelipec95 luisfelipec95 requested a review from a team as a code owner February 5, 2025 06:07
Copy link

@DeimerM DeimerM left a comment

Choose a reason for hiding this comment

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

Hi @luisfelipec95 I saw in other PRs that you added importlib-resources in requirements/base.in but I can't see it on this PR, isn't this requirement needed?

@DeimerM
Copy link

DeimerM commented Feb 7, 2025

I checked this xblock in the release sumac instance and everything seems to work very well https://studio.sumac.releases.edunext.link/container/block-v1:OpenedX+101+2025+type@vertical+block@25d1f39f06924f46ae5007acba34ac20

@luisfelipec95 luisfelipec95 requested review from DeimerM and a team February 10, 2025 05:03
@luisfelipec95
Copy link
Contributor Author

Hi @luisfelipec95 I saw in other PRs that you added importlib-resources in requirements/base.in but I can't see it on this PR, isn't this requirement needed?

Thanks @DeimerM, You're right, I have already updated the other PRs since it's not necessary to add importlib-resources in Python 3.11.

Copy link
Contributor

@magajh magajh left a comment

Choose a reason for hiding this comment

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

LGTM

@luisfelipec95 luisfelipec95 merged commit f6f1570 into main Feb 11, 2025
4 checks passed
@luisfelipec95 luisfelipec95 deleted the lfc/deprecate-pkg-resources branch February 11, 2025 22:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants