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

Pin napari and pydantic when installing a plugin #6022

Merged
merged 1 commit into from
Jul 4, 2023

Conversation

Czaki
Copy link
Collaborator

@Czaki Czaki commented Jun 30, 2023

Fixes/Closes

Closes #5279

Description

Backport changes from new plugin dialog to 0.4.18 release

References

Type of change

  • Enhancement (non-breaking improvements of an existing feature)

How has this been tested?

  • example: the test suite for my feature covers cases x, y, and z
  • example: all tests pass with my change
  • example: I check if my changes works with both PySide and PyQt backends
    as there are small differences between the two Qt bindings.

Final checklist:

  • My PR is the minimum possible work for the desired functionality
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works
  • If I included new strings, I have used trans. to make them localizable.
    For more information see our translations guide.

@Czaki Czaki added the maintenance PR with maintance changes, label Jun 30, 2023
@Czaki Czaki added this to the 0.4.18 milestone Jun 30, 2023
@github-actions github-actions bot added the qt Relates to qt label Jun 30, 2023
@Czaki Czaki marked this pull request as draft June 30, 2023 11:55
@codecov
Copy link

codecov bot commented Jun 30, 2023

Codecov Report

Merging #6022 (8cf1c5c) into v0.4.18x (59d5a09) will decrease coverage by 0.02%.
The diff coverage is 50.00%.

@@             Coverage Diff              @@
##           v0.4.18x    #6022      +/-   ##
============================================
- Coverage     88.70%   88.69%   -0.02%     
============================================
  Files           623      623              
  Lines         52631    52646      +15     
============================================
+ Hits          46686    46693       +7     
- Misses         5945     5953       +8     
Impacted Files Coverage Δ
napari/_qt/dialogs/qt_plugin_dialog.py 61.88% <50.00%> (-0.37%) ⬇️

@Czaki
Copy link
Collaborator Author

Czaki commented Jun 30, 2023

@goanpeca Did the assumption (present currentyl in the code) that the installer could be only pip or mamba?

@Czaki Czaki marked this pull request as ready for review June 30, 2023 13:04
Copy link
Member

@jni jni left a comment

Choose a reason for hiding this comment

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

@goanpeca @jaimergp I'd love your input on whether this will work for napari 0.4.18 on conda-forge — it is the last PR holding up 0.4.18! 🥳

@Czaki Czaki mentioned this pull request Jun 30, 2023
@jni
Copy link
Member

jni commented Jul 4, 2023

Well, I'm going to merge and assume this is ok as I'd like to get the final RC out today. Since afaik this fixes a problem that existed in many prior versions, I don't think it's a huge deal if it doesn't actually work. 😅

@jni jni changed the title Pin napari and pydantic when install plugin Pin napari and pydantic when installing a plugin Jul 4, 2023
@jni jni merged commit a390099 into napari:v0.4.18x Jul 4, 2023
31 of 33 checks passed


def _conda_constraints():
return [f"napari={__version__}", "pydantic<2.0a0"]
Copy link
Contributor

Choose a reason for hiding this comment

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

This is better handled in a repodata patch (pip doesn't have this mechanism but conda-forge does). Now this constraint will be tied to that release forever, which is maybe not a problem in this case, but we need to be careful about internalizing "external" problems in our codebase.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Could you point where? Also this release is not compatibility with pydantic 2 and never will be.

Copy link
Member

Choose a reason for hiding this comment

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

Yeah @jaimergp note that this change is on a branch that won't live beyond this release. So nothing is internalised, it is forgotten tomorrow. 😂

Copy link
Member

Choose a reason for hiding this comment

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

Looks like _conda_constraints is not used anywhere anyway, so I'll delete it in the now-necessary follow-up PR.

@imagesc-bot
Copy link

This pull request has been mentioned on Image.sc Forum. There might be relevant details there:

https://forum.image.sc/t/request-for-testing-napari-0-4-18-release-candidate/82833/21

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance PR with maintance changes, qt Relates to qt
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants