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

fix: Exclude packaging 22.0 to avoid breakage #1568

Merged
merged 2 commits into from
Dec 12, 2022
Merged

fix: Exclude packaging 22.0 to avoid breakage #1568

merged 2 commits into from
Dec 12, 2022

Conversation

frostming
Copy link
Collaborator

@frostming frostming commented Dec 12, 2022

Pull Request Check List

  • A news fragment is added in news/ describing what is new.
  • Test cases added for changed code.

Describe what you have changed in this PR.

It resolves the following issues, while still allows future packaging versions to be installed

@codecov-commenter
Copy link

codecov-commenter commented Dec 12, 2022

Codecov Report

Base: 85.33% // Head: 85.38% // Increases project coverage by +0.04% 🎉

Coverage data is based on head (4bfaebd) compared to base (7db1e17).
Patch has no changes to coverable lines.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1568      +/-   ##
==========================================
+ Coverage   85.33%   85.38%   +0.04%     
==========================================
  Files          91       91              
  Lines        8068     8068              
  Branches     1911     1911              
==========================================
+ Hits         6885     6889       +4     
+ Misses        795      791       -4     
  Partials      388      388              
Flag Coverage Δ
unittests 85.21% <ø> (+0.04%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
src/pdm/models/repositories.py 80.39% <0.00%> (-0.79%) ⬇️
src/pdm/termui.py 89.85% <0.00%> (-0.73%) ⬇️
src/pdm/models/caches.py 88.88% <0.00%> (+1.16%) ⬆️
src/pdm/models/specifiers.py 79.15% <0.00%> (+1.76%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@frostming frostming merged commit 7f09f24 into main Dec 12, 2022
@frostming frostming deleted the packaging-22 branch December 12, 2022 05:02
@ferminho
Copy link

Hi there, won't this happen again if packaging releases another version?

@frostming
Copy link
Collaborator Author

Hi there, won't this happen again if packaging releases another version?

so you don't want to pull in any future updates?

i hope you are clear what the issue is here. we only exclude versions that are known to be buggy, removing the old behavior isn't a bug but a feature.

@ferminho
Copy link

I might not have the full picture of the issue and I'd indeed like future updates. I simply asked to understand if we could face the same issue when, say, packaging 22.1 is released.
If so, the recommendation is to pin packaging in our side in every project?

Honest questions, no intention to debate. Thanks a lot for your support!

@franzhaas
Copy link
Contributor

@ferminho
There is a discussion about how to have repeatable deployments of pdm over there.: #1558

@pawamoy
Copy link
Contributor

pawamoy commented Dec 12, 2022

If so, the recommendation is to pin packaging in our side in every project?

Locally, you probably have a single installation of PDM. In that case you could simply restrict its packaging dependency to exclude the new, unsupported version of packaging, until PDM excludes it itself or becomes compatible with it. This will fix it for all of your local projects.

pipx inject pdm 'packaging!=22.0,!=22.1'

In CI, you'll need to add an instruction to your steps/workflow to restrict it as well, until, again, PDM excludes or supports it.

@ferminho
Copy link

Locally, you probably have a single installation of PDM. In that case you could simply restrict its packaging dependency to exclude the new, unsupported version of packaging, until PDM excludes it itself or becomes compatible with it. This will fix it for all of your local projects.

We have recently adopted pdm as our standard package manager and we have many installations in Python services, libraries and also environments such as JupyterLab or Databricks. This is why the issue created a bit of havoc everywhere when an old, unused version of pyzqm couldn't be parsed as candidate.

Thanks! moving to the other conversation

@frostming
Copy link
Collaborator Author

This is why the issue created a bit of havoc everywhere when an old, unused version of pyzqm couldn't be parsed as candidate.

If this is what blocks you, it has been already solved by the latest version of unearth, those legacy illegal packages will be skipped.

@lyz-code
Copy link
Contributor

@frostming can you please make a release with this fix? all my CI pipelines will thank you for it

@j178 j178 mentioned this pull request Apr 3, 2024
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.

6 participants