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

feat!: expose per-release edx-sandbox dependency pins #34509

Merged
merged 5 commits into from
Apr 18, 2024

Conversation

kdmccormick
Copy link
Member

@kdmccormick kdmccormick commented Apr 12, 2024

Description

We want to upgrade edx-sandbox to Python 3.11 before the Redwood cut. However, we want to allow operators on master and in Redwood to continue running edx-sandbox Python 3.8 for some amount of time amount of time, as it can be very difficult to upgrade both edx-platform and edx-sandbox (plus all of a site's instructor-authored code) all in one go.

So, we make these changes, each of which has its own commit:

  • rename py38.in to base.in and py38.txt to base.txt -- going forward, base.txt will be the latest pins.
  • freeze a releases/quince.txt file from the current state of base.txt while it is still Py38-compatible
  • link py38.txt to quince.txt for backwards compatibility

plus two tangential bonus commits:

  • remove the unused shared.txt and shared.in files.
  • switch make upgrade impl from wget to curl so that works in more places (eg tutor)

Testing

None needed

Merged considerations

  • This should land ASAP
  • I will notify 2U that they should stop using py38.txt and start using either base.txt or quince.txt.
  • I will add a release process step: copy a new releases/<release>txt. file every cut, starting with redwood.txt on ~5/9. I'll link the quince.txt commit here as an example.

@kdmccormick kdmccormick force-pushed the kdmccormick/versioned-sandbox branch 2 times, most recently from 37c17d8 to ab5b031 Compare April 12, 2024 20:20
@kdmccormick kdmccormick changed the title feat: expose per-release edx-sandbox dependency pins feat!: expose per-release edx-sandbox dependency pins Apr 12, 2024
@kdmccormick kdmccormick force-pushed the kdmccormick/versioned-sandbox branch 4 times, most recently from 1a9918e to 1eaac83 Compare April 16, 2024 20:14
@kdmccormick kdmccormick reopened this Apr 16, 2024
@kdmccormick kdmccormick force-pushed the kdmccormick/versioned-sandbox branch 2 times, most recently from d2ab74c to d20e71a Compare April 16, 2024 20:42
@kdmccormick kdmccormick marked this pull request as ready for review April 16, 2024 20:43
@kdmccormick
Copy link
Member Author

@feanil How does this look?

Copy link
Contributor

@feanil feanil left a comment

Choose a reason for hiding this comment

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

One small comment and one nit that you can take or leave. Then I think this is good to merge, I don't need to re-review unless there are major changes.

@@ -130,7 +130,7 @@ endef
COMMON_CONSTRAINTS_TXT=requirements/common_constraints.txt
.PHONY: $(COMMON_CONSTRAINTS_TXT)
$(COMMON_CONSTRAINTS_TXT):
wget -O "$(@)" https://raw.githubusercontent.com/edx/edx-lint/master/edx_lint/files/common_constraints.txt
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: curl has a -O which will do the same thing as the wget -O so maybe just use curl -OL here?

Ref: https://curl.se/docs/manpage.html#-O

Copy link
Member Author

Choose a reason for hiding this comment

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

they're a bit different:

wget -O "$(@)" means "write to a file named $(@)", which means "write to the Makefile target", which is requirements/common_constraints.txt

curl -O means "write to a file of the same name as the remote file", which would be just common_constraints.txt (no requirements/ prefix)

@@ -0,0 +1,97 @@
#
Copy link
Contributor

Choose a reason for hiding this comment

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

It looks like this is a copy rather than a symlink, was that intentional? I think it makes more sense to make this a symlink.

Copy link
Member Author

Choose a reason for hiding this comment

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

Whoops, that was a git mixup.

I actually made a shell requirements file with -r releases/quince.txt instead of a symlink. My thinking is that this is more explicit and also allows us to include an explanatory comment. Let me know what you think.

tutor's containers don't have wget installed, and curl -L works
just as well and is installed into basically everything
These files were used to assist the Python 3.5 -> 3.8 upgrade,
but they are no longer needed nor referened anywhere. They haven't
been updated for years.
See requirements/edx-sandbox/README.rst for more info

BREAKING CHANGE: edx-sandbox/py38.txt will not longer
be updated. Please install from either edx-sandbox/base.txt or
edx-sandbox/releases/*.txt instead.
We ran:

    cp requirements/edx-sandbox/base.txt \
       requirements/edx-sandbox/releases/quince.txt
@kdmccormick kdmccormick force-pushed the kdmccormick/versioned-sandbox branch from a47a210 to 85643a1 Compare April 18, 2024 15:04
@kdmccormick kdmccormick requested a review from feanil April 18, 2024 18:08
@kdmccormick kdmccormick merged commit f04532d into openedx:master Apr 18, 2024
66 checks passed
@kdmccormick kdmccormick deleted the kdmccormick/versioned-sandbox branch April 18, 2024 19:35
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

1 similar comment
@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX staging environment in preparation for a release to production.

@edx-pipeline-bot
Copy link
Contributor

2U Release Notice: This PR has been deployed to the edX production environment.

@timmc-edx
Copy link
Contributor

I've created edx/edx-arch-experiments#630 to track 2U's work to switch to base.txt.

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.

4 participants