@@ -6,6 +6,13 @@ requires = [
66 " setuptools == 68.1.0" ,
77 " setuptools_scm[toml] == 7.1.0" ,
88 " frequenz-repo-config[api] == 0.9.1" ,
9+ # We need to pin the protobuf, grpcio and grpcio-tools dependencies to make
10+ # sure the code is generated using the minimum supported versions, as older
11+ # versions can't work with code that was generated with newer versions.
12+ # https://protobuf.dev/support/cross-version-runtime-guarantee/#backwards
13+ " protobuf == 4.25.3" ,
14+ " grpcio-tools == 1.51.1" ,
15+ " grpcio == 1.51.1" ,
916]
1017build-backend = " setuptools.build_meta"
1118
@@ -26,9 +33,15 @@ classifiers = [
2633]
2734requires-python = " >= 3.11, < 4"
2835dependencies = [
29- " frequenz-api-common >= 0.6.1 , < 0.7" ,
36+ " frequenz-api-common >= 0.6.2 , < 0.7" ,
3037 " googleapis-common-protos >= 1.56.4, < 2" ,
31- " grpcio >= 1.51.1, < 2" ,
38+ # We can't widen beyond 6 because of protobuf cross-version runtime guarantees
39+ # https://protobuf.dev/support/cross-version-runtime-guarantee/#major
40+ " protobuf >= 4.25.3, < 6" , # Do not widen beyond 6!
41+ # We couldn't find any document with a spec about the cross-version runtime
42+ # guarantee for grpcio, so unless we find one in the future, we'll assume
43+ # major version jumps are not compatible
44+ " grpcio >= 1.51.1, < 2" , # Do not widen beyond 2!
3245]
3346dynamic = [" version" ]
3447
@@ -50,7 +63,8 @@ dev-mkdocs = [
5063 " mkdocs-gen-files == 0.5.0" ,
5164 " mkdocs-literate-nav == 0.6.1" ,
5265 " mkdocs-material == 9.5.20" ,
53- " mkdocstrings[python] == 0.23.0" ,
66+ " mkdocstrings[python] == 0.26.1" ,
67+ " mkdocstrings-python == 1.11.1" ,
5468 " frequenz-repo-config[api] == 0.9.1" ,
5569]
5670dev-mypy = [
@@ -59,10 +73,7 @@ dev-mypy = [
5973 # For checking the noxfile, docs/ script, and tests
6074 " frequenz-api-microgrid[dev-mkdocs,dev-noxfile,dev-pytest]" ,
6175]
62- dev-noxfile = [
63- " nox == 2024.4.15" ,
64- " frequenz-repo-config[api] == 0.9.1" ,
65- ]
76+ dev-noxfile = [" nox == 2024.4.15" , " frequenz-repo-config[api] == 0.9.1" ]
6677dev-pylint = [
6778 " pylint == 3.1.0" ,
6879 # For checking the noxfile, docs/ script, and tests
0 commit comments