Skip to content

Commit 5a492e8

Browse files
authored
Merge branch 'master' into pr-osparc-move-service-extras-to-catalog2
2 parents cbd09d3 + 00d3690 commit 5a492e8

File tree

57 files changed

+550
-150
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

57 files changed

+550
-150
lines changed

.github/dependabot.yml

Lines changed: 6 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,9 @@ updates:
1111
- sanderegg
1212
assignees:
1313
- pcrespov
14+
- sanderegg
15+
labels:
16+
- t:maintenance
1417
ignore:
1518
- dependency-name: docker-compose
1619
versions:
@@ -26,32 +29,10 @@ updates:
2629
- dependency-name: httpx
2730
versions:
2831
- 0.17.0
29-
- package-ecosystem: pip
30-
directory: "/packages/service-library"
31-
schedule:
32-
interval: weekly
33-
time: "04:00"
34-
open-pull-requests-limit: 10
35-
reviewers:
36-
- pcrespov
37-
- sanderegg
38-
assignees:
39-
- pcrespov
40-
ignore:
4132
- dependency-name: openapi-core
4233
versions:
4334
- "> 0.12.0, < 1"
44-
- package-ecosystem: pip
45-
directory: "/packages/postgres-database"
46-
schedule:
47-
interval: weekly
48-
time: "04:00"
49-
open-pull-requests-limit: 10
50-
reviewers:
51-
- pcrespov
52-
- sanderegg
53-
assignees:
54-
- pcrespov
35+
5536
- package-ecosystem: "github-actions"
5637
directory: "/"
5738
schedule:
@@ -62,3 +43,5 @@ updates:
6243
- pcrespov
6344
assignees:
6445
- sanderegg
46+
labels:
47+
- t:maintenance

.github/workflows/ci-testing-deploy.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1730,15 +1730,13 @@ jobs:
17301730
matrix:
17311731
python: ["3.11"]
17321732
os: [ubuntu-22.04]
1733-
docker_buildx: [v0.10.4]
17341733
fail-fast: false
17351734
steps:
17361735
- uses: actions/checkout@v4
17371736
- name: setup docker buildx
17381737
id: buildx
17391738
uses: docker/setup-buildx-action@v3
17401739
with:
1741-
version: ${{ matrix.docker_buildx }}
17421740
driver: docker-container
17431741
- name: setup python environment
17441742
uses: actions/setup-python@v5

ci/helpers/install_pylint.bash

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ PYLINT_VERSION="$(grep pylint== $REQUIREMENTS | awk '{print $1}')"
1616
uv pip install "$PYLINT_VERSION"
1717

1818
# Minimal packages to pass linter
19-
echo "$CURDIR/requirements.txt"
20-
uv pip install -r "$CURDIR/requirements.txt"
19+
echo "$CURDIR/requirements/requirements.txt"
20+
uv pip install -r "$CURDIR/requirements/requirements.txt"
2121

2222
echo "INFO:" "$(pylint --version)" "@" "$(command -v pylint)"

ci/helpers/requirements/Makefile

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#
2+
# Targets to pip-compile requirements
3+
#
4+
include ../../../requirements/base.Makefile
5+
6+
# Add here any extra explicit dependency: e.g. _migration.txt: _base.txt

ci/helpers/requirements.in renamed to ci/helpers/requirements/requirements.in

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
#
33
# Installing these void e.g. E0611: No name 'UploadFile' in module 'fastapi' (no-name-in-module)
44
#
5-
--constraint ../../requirements/constraints.txt
5+
--constraint ../../../requirements/constraints.txt
66

77
aiohttp
88
fastapi
9+
docker
Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
# This file was autogenerated by uv via the following command:
2-
# uv pip compile requirements.in -o requirements.txt
31
aiohttp==3.9.5
4-
# via
5-
# -c ../../requirements/constraints.txt
6-
# -r requirements.in
72
aiosignal==1.3.1
83
# via aiohttp
94
annotated-types==0.7.0
@@ -12,36 +7,43 @@ anyio==4.3.0
127
# via starlette
138
attrs==23.2.0
149
# via aiohttp
10+
certifi==2024.12.14
11+
# via requests
12+
charset-normalizer==3.4.1
13+
# via requests
14+
docker==7.1.0
1515
fastapi==0.115.0
16-
# via -r requirements.in
1716
frozenlist==1.4.1
1817
# via
1918
# aiohttp
2019
# aiosignal
2120
idna==3.7
2221
# via
2322
# anyio
23+
# requests
2424
# yarl
2525
multidict==6.0.5
2626
# via
2727
# aiohttp
2828
# yarl
29-
pydantic==2.9.2
30-
# via
31-
# -c ../../requirements/constraints.txt
32-
# fastapi
33-
pydantic-core==2.23.4
29+
pydantic==2.10.5
30+
# via fastapi
31+
pydantic-core==2.27.2
3432
# via pydantic
33+
requests==2.32.3
34+
# via docker
3535
sniffio==1.3.1
3636
# via anyio
3737
starlette==0.38.6
38-
# via
39-
# -c ../../requirements/constraints.txt
40-
# fastapi
41-
typing-extensions==4.11.0
38+
# via fastapi
39+
typing-extensions==4.12.2
4240
# via
4341
# fastapi
4442
# pydantic
4543
# pydantic-core
44+
urllib3==2.3.0
45+
# via
46+
# docker
47+
# requests
4648
yarl==1.9.4
4749
# via aiohttp

packages/common-library/tests/test_pydantic_fields_extension.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,4 +69,4 @@ class MyModel(BaseModel):
6969
],
7070
)
7171
def test_field_fn(fn: Callable[[Any], Any], expected: Any, name: str):
72-
assert expected == fn(MyModel.model_fields[name])
72+
assert expected == fn(MyModel.model_fields.get(name))

packages/models-library/src/models_library/user_preferences.py

Lines changed: 16 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -98,19 +98,30 @@ def to_db(self) -> dict:
9898

9999
@classmethod
100100
def update_preference_default_value(cls, new_default: Any) -> None:
101-
expected_type = get_type(cls.model_fields["value"])
101+
expected_type = get_type(
102+
cls.model_fields["value"] # pylint: disable=unsubscriptable-object
103+
)
102104
detected_type = type(new_default)
103105
if expected_type != detected_type:
104106
msg = (
105107
f"Error, {cls.__name__} {expected_type=} differs from {detected_type=}"
106108
)
107109
raise TypeError(msg)
108110

109-
if cls.model_fields["value"].default is None:
110-
cls.model_fields["value"].default_factory = lambda: new_default
111+
if (
112+
cls.model_fields["value"].default # pylint: disable=unsubscriptable-object
113+
is None
114+
):
115+
cls.model_fields[ # pylint: disable=unsubscriptable-object
116+
"value"
117+
].default_factory = lambda: new_default
111118
else:
112-
cls.model_fields["value"].default = new_default
113-
cls.model_fields["value"].default_factory = None
119+
cls.model_fields[ # pylint: disable=unsubscriptable-object
120+
"value"
121+
].default = new_default
122+
cls.model_fields[ # pylint: disable=unsubscriptable-object
123+
"value"
124+
].default_factory = None
114125

115126
cls.model_rebuild(force=True)
116127

packages/models-library/tests/test_rest_ordering.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -197,7 +197,7 @@ def test_ordering_query_model_class__defaults():
197197
model = OrderQueryParamsModel.model_validate({"order_by": {"field": "name"}})
198198
assert model.order_by
199199
assert model.order_by.field == "name"
200-
assert model.order_by.direction == OrderBy.model_fields["direction"].default
200+
assert model.order_by.direction == OrderBy.model_fields.get("direction").default
201201

202202
# direction alone is invalid
203203
with pytest.raises(ValidationError) as err_info:

packages/postgres-database/docker/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# syntax=docker/dockerfile:1
22
ARG PYTHON_VERSION="3.11.9"
3-
ARG UV_VERSION="0.4"
3+
ARG UV_VERSION="0.5"
44
FROM ghcr.io/astral-sh/uv:${UV_VERSION} AS uv_build
55
# we docker image is built based on debian
66
FROM python:${PYTHON_VERSION}-slim-bookworm AS base

0 commit comments

Comments
 (0)