Skip to content

Commit 828b732

Browse files
authored
Merge branch 'master' into ik/hardcode-spec-yaml-path
2 parents 4c52f33 + 617cdb8 commit 828b732

File tree

203 files changed

+17871
-2162
lines changed

Some content is hidden

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

203 files changed

+17871
-2162
lines changed

.coveragerc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,3 +55,6 @@ exclude_lines =
5555

5656
# Ignore non-runnable code
5757
if __name__ == .__main__.:
58+
59+
# Ignore TYPE_CHECKING blocks
60+
if TYPE_CHECKING:

.cursor/rules/documentation.mdc

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
---
2+
description:
3+
globs: *md
4+
alwaysApply: false
5+
---
6+
## New files added
7+
When a new file is added make sure to make it available through the navigation configuration in the mkdocs file. If it is not clear where it should go, ask.
8+
9+
## Style
10+
Maintain style consistent. The style should be technical and professional.
11+
12+
Do not start lines/paragraphs with an inline code.

.cursor/rules/python-type-hinting.mdc

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
---
2+
description:
3+
globs: **/*.py
4+
alwaysApply: false
5+
---
6+
## Generating new code
7+
When generating python code, always add type hinting to the methods. Use modern syntaxis, for example, instead of using `Optional[str]` use `str | None` and instead of using `List[str]` use `list[str]`.
8+
9+
If a method yields a value but we are not returning anything or we do not accept anything sent to the generator, it is better to type the method as Iterator to explicitely expose the API of the method as simply something the caller can iterate over.
10+
11+
## Refactoring code
12+
When refactoring existing code, never add type hints to method that are not type hinted unless asked explicitely.
13+
14+
## The case of AnyStr
15+
AnyStr is normally used to define the type of a variable that can be either a string or bytes. This is soon to be deprecated and, instead, type parameter lits are a better solution. If AnyStr is used as type of several arguments in a given method signature, it is better to use type parameter lists and define the function as a generic function.
16+
17+
```python
18+
# Soon to be deprecated
19+
def func(a: AnySTr, b: AnyStr):
20+
pass
21+
22+
# Preferred
23+
def func[T: (str, bytes)](a: T, b: T):
24+
pass
25+
```
26+
27+
This way, whether a and b are either strings or bytes, they cannot be mixed.
28+
29+
If a single argument is present in the function, `str | bytes` is preferred.

.cursor/rules/testing.mdc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ globs: **/*.py
44
alwaysApply: false
55
---
66
Run unit and integration tests with `ddev --no-interactive test <INTEGRATION>`. For example, for the pgbouncer integration, run `ddev --no-interactive test pgbouncer`.
7-
Run E2E tests with `ddev ddev --no-interactive env test <INTEGRATION> --dev`. For example, for the pgbouncer integration, run `ddev ddev --no-interactive env test pgbouncer --dev`.
7+
Run E2E tests with `ddev --no-interactive env test <INTEGRATION> --dev`. For example, for the pgbouncer integration, run `ddev --no-interactive env test pgbouncer --dev`.

.ddev/config.toml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,8 @@ semver = ['BSD-3-Clause']
9393
simplejson = ['MIT']
9494
# https://github.com/Supervisor/supervisor/blob/master/LICENSES.txt
9595
supervisor = ['BSD-3-Clause-Modification']
96+
# https://github.com/prometheus/client_python/issues/1110
97+
prometheus-client = ['Apache-2.0']
9698

9799
[overrides.dependencies.repo]
98100
PyYAML = 'https://github.com/yaml/pyyaml'
@@ -149,7 +151,6 @@ unsorted = [
149151

150152
[overrides.dep.updates]
151153
exclude = [
152-
'ddtrace', # https://github.com/DataDog/integrations-core/pull/9132
153154
'pyasn1', # https://github.com/pyasn1/pyasn1/issues/52
154155
'pysmi', # pysnmp dependent on pysmi version 1.2.1
155156
'pysnmp', # Breaking snmp tests

.deps/image_digests.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"linux-aarch64": "sha256:1a4a3ea10f1c2cafb3dc1fd9eda02826026e0e660f670f9c065b6b0782f4d901",
3-
"linux-x86_64": "sha256:00483449e9a400fc6e5a8433cb063f0946e20e1feda5f70b910d1bd451b63936",
4-
"windows-x86_64": "sha256:9f34e9b4e33bb55f8e25ef12d7ec6e7e9f6916691a0b849bb1ebfb65e153f2d9"
2+
"linux-aarch64": "sha256:fe7765187251f8ad4b944de52ac93aae21e0b05b3cd132f18949365ef83480c8",
3+
"linux-x86_64": "sha256:0b78aff97c081fe3e478f29eeb19f54473812a7510eed1527c269051d1ba8534",
4+
"windows-x86_64": "sha256:e35fdbbd4fb4201ee6d203a437175ccf527775a8c371cefd5888bdcfabc3af9c"
55
}

.deps/metadata.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
{
2-
"sha256": "486cd5ab2b0575197336c221ce98d41fe816fc4f90dff63f4556fb6646f01745"
2+
"sha256": "ad5ab7530687a62ff2ff0cffc75902d1998a727ad410f3e59d9e0fae0236d25d"
33
}

.deps/resolved/linux-aarch64_3.12.txt

Lines changed: 25 additions & 25 deletions
Large diffs are not rendered by default.

.deps/resolved/linux-aarch64_py2.txt

Lines changed: 0 additions & 91 deletions
This file was deleted.

.deps/resolved/linux-aarch64_py3.txt

Lines changed: 0 additions & 127 deletions
This file was deleted.

.deps/resolved/linux-x86_64_3.12.txt

Lines changed: 26 additions & 26 deletions
Large diffs are not rendered by default.

.deps/resolved/linux-x86_64_py2.txt

Lines changed: 0 additions & 92 deletions
This file was deleted.

.deps/resolved/linux-x86_64_py3.txt

Lines changed: 0 additions & 128 deletions
This file was deleted.

.deps/resolved/macos-x86_64_3.12.txt

Lines changed: 23 additions & 23 deletions
Large diffs are not rendered by default.

.deps/resolved/macos-x86_64_py2.txt

Lines changed: 0 additions & 91 deletions
This file was deleted.

.deps/resolved/macos-x86_64_py3.txt

Lines changed: 0 additions & 127 deletions
This file was deleted.

.deps/resolved/windows-x86_64_3.12.txt

Lines changed: 23 additions & 23 deletions
Large diffs are not rendered by default.

.deps/resolved/windows-x86_64_py2.txt

Lines changed: 0 additions & 86 deletions
This file was deleted.

0 commit comments

Comments
 (0)