-
Notifications
You must be signed in to change notification settings - Fork 27
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
✨ Enhance compatibility-check for catalog service's ports including units #2913
✨ Enhance compatibility-check for catalog service's ports including units #2913
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2913 +/- ##
========================================
+ Coverage 78.2% 79.6% +1.3%
========================================
Files 671 671
Lines 27787 27828 +41
Branches 3224 3229 +5
========================================
+ Hits 21743 22162 +419
+ Misses 5259 4914 -345
+ Partials 785 752 -33
Flags with carried forward coverage won't be shown. Click here to find out more.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 Works for me, please check some questions and especially the yarl
pinning. Not sure why we would like to do that.
packages/models-library/src/models_library/function_service/demo_units.py
Show resolved
Hide resolved
# SEE services/web/server/tests/unit/isolated/test_utils.py::test_yarl_url_compose_changed_with_latest_release | ||
yarl<1.6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you add when this could be unpinned? I cannot find the reference from the comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you mean? I think the line 26 is pretty clear, ritgh? This is the test
def test_yarl_url_compose_changed_with_latest_release(): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very cool, but please not ureg...
services/web/server/src/simcore_service_webserver/catalog_utils.py
Outdated
Show resolved
Hide resolved
very cool - excited to see this in action! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👌
6e3920c
to
61e0102
Compare
61e0102
to
4f279c3
Compare
What do these changes do?
This PR enhances port's compatibility-check logic between catalog services which is used by the front-end to determine how "two services can connect" (see
catalog_utils.py
and screenshot below).Port units are now parsed, validated and formatted using pint. Notice that this PR only adds this library on the catalog plugin.
Highlights
can_connect
rules :miles
can connect withmm
). Notice that in later PR we will introduce the conversion of these units when the data flows from one service to the next.unitLong
andunitShort
Extras
Related issue/s
How to test
$ cd services/web/server $ make install-dev $ pytest --pdb -vv tests/**/test_catalog*.py
demo units
function serviceChecklist
make openapi-specs
,git commit ...
and thenmake version-*
)