Skip to content

Commit 3664a9b

Browse files
authored
Prepare v0.4.0 release (frequenz-floss#96)
- Bump repo-config version in templates and docs - Prepare release notes for the new release - Add missing extension to the cookiecutter replay file - Update files by regenerating the cookiecutter template
2 parents ed6d44d + ce38285 commit 3664a9b

File tree

12 files changed

+66
-31
lines changed

12 files changed

+66
-31
lines changed

.cookiecutter-replay.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"default_codeowners": "@frequenz-floss/python-sdk-team",
1616
"_extensions": [
1717
"jinja2_time.TimeExtension",
18+
"local_extensions.as_identifier",
1819
"local_extensions.default_codeowners",
1920
"local_extensions.github_repo_name",
2021
"local_extensions.keywords",

.github/RELEASE_NOTES.template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
## Upgrading
88

9-
<!-- Here goes notes on how to upgrade from previous versions, including deprecations and what they should be replaced with -->
9+
<!-- Here goes notes on how to upgrade from previous versions, including deprecations and what they should be replaced with -->
1010

1111
## New Features
1212

RELEASE_NOTES.md

Lines changed: 33 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,24 +2,51 @@
22

33
## Summary
44

5-
<!-- Here goes a general summary of what this release is about -->
5+
This release only ships fixes and improvements for Cookiecutter templates, it is recommended for existing projects to regenerate the templates.
66

77
## Upgrading
88

9-
<!-- Here goes notes on how to upgrade from previous versions, including deprecations and what they should be replaced with -->
9+
### Cookiecutter templates
10+
11+
* You might want to remove the `_output_dir` from the
12+
`.cookiecutter-replay.json` file, if there is one in your project.
13+
* You will need to manually add `local_extensions.as_identifier` to the `_extensions` key in the `.cookiecutter-replay.json` file before running the replay.
1014

1115
## New Features
1216

1317
### Cookiecutter templates
1418

1519
* Add linting to the CI with `protolint` for API projects.
16-
* Bump SDK version to v0.22.0.
1720
* Capitalize project name in title and expand shortened words.
18-
* Add a few more default keywords.
19-
* Add variable reference documentation.
21+
* Add templates variables reference documentation in the genrated docs and when running Cookiecutter.
22+
* Do some basic templates variables validation.
23+
24+
* `labeler` workflow configuration
25+
26+
* Label `docs/*.py` as tooling.
27+
* Add example on how to exclude files.
28+
29+
* `pyproject.toml`
30+
31+
* Bump SDK version to v0.22.0.
32+
* Disable `pylint`'s `unsubscriptable-object` check.
33+
* Add a few more default keywords.
34+
* Run `isort` in `benchmarks/` too
35+
36+
* `mkdocs`
37+
38+
* Add more cross-reference inventories: `typing-extensions`, `frequenz-sdk`, `frequenz-channels`, `grpc`.
39+
* Add some extra markdown plugins: code annotations, copy button and line numbers, keys representation.
40+
* Be strict when building the docs (any warning will make the generation fail).
2041

2142
## Bug Fixes
2243

23-
### Cookiecutter
44+
### Cookiecutter templates
2445

2546
* Fix hardcoded MIT license headers. Now the user selected license is used instead.
47+
* Properly handle project names with `-` and `_` in them.
48+
49+
* `pyproject.toml`
50+
51+
* Add missing `repo-config` to `dev-mkdocs` dependencies.
52+
* Fix wrong optional dependency name for `dev` dependencies.

cookiecutter/{{cookiecutter.github_repo_name}}/pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
requires = [
66
"setuptools == 67.7.2",
77
"setuptools_scm[toml] == 7.1.0",
8-
"frequenz-repo-config[{{cookiecutter.type}}] == 0.3.0",
8+
"frequenz-repo-config[{{cookiecutter.type}}] == 0.4.0",
99
]
1010
build-backend = "setuptools.build_meta"
1111

@@ -70,7 +70,7 @@ dev-mkdocs = [
7070
"mkdocs-material == 9.1.16",
7171
"mkdocs-section-index == 0.3.5",
7272
"mkdocstrings[python] == 0.22.0",
73-
"frequenz-repo-config[{{cookiecutter.type}}] == 0.3.0",
73+
"frequenz-repo-config[{{cookiecutter.type}}] == 0.4.0",
7474
]
7575
dev-mypy = [
7676
"mypy == 1.2.0",
@@ -79,7 +79,7 @@ dev-mypy = [
7979
]
8080
dev-noxfile = [
8181
"nox == 2023.4.22",
82-
"frequenz-repo-config[{{cookiecutter.type}}] == 0.3.0",
82+
"frequenz-repo-config[{{cookiecutter.type}}] == 0.4.0",
8383
]
8484
dev-pylint = [
8585
"pylint == 2.17.3",

mkdocs.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ theme:
2222
repo: fontawesome/brands/github
2323
custom_dir: docs/overrides
2424
features:
25+
- content.code.annotate
26+
- content.code.copy
2527
- navigation.instant
2628
- navigation.tabs
2729
- navigation.top
@@ -62,16 +64,20 @@ markdown_extensions:
6264
- admonition
6365
- attr_list
6466
- pymdownx.details
65-
- pymdownx.superfences
66-
- pymdownx.tasklist
67-
- pymdownx.tabbed
67+
- pymdownx.highlight:
68+
anchor_linenums: true
69+
line_spans: __span
70+
pygments_lang_class: true
71+
- pymdownx.keys
6872
- pymdownx.snippets:
6973
check_paths: true
7074
- pymdownx.superfences:
7175
custom_fences:
7276
- name: mermaid
7377
class: mermaid
7478
format: "!!python/name:pymdownx.superfences.fence_code_format"
79+
- pymdownx.tabbed
80+
- pymdownx.tasklist
7581
- toc:
7682
permalink: "¤"
7783

@@ -103,6 +109,7 @@ plugins:
103109
- https://nox.thea.codes/en/stable/objects.inv
104110
- https://setuptools.pypa.io/en/latest/objects.inv
105111
- https://oprypin.github.io/mkdocs-gen-files/objects.inv
112+
- https://typing-extensions.readthedocs.io/en/stable/objects.inv
106113
- search
107114
- section-index
108115

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ dev-pytest = [
8787
"cookiecutter == 2.1.1", # For checking the cookiecutter scripts
8888
]
8989
dev = [
90-
"frequenz-repo-config[dev-mkdocs,dev-docstrings,dev-formatting,dev-gen-docs,dev-mypy,dev-noxfile,dev-pylint,dev-pytest]",
90+
"frequenz-repo-config[dev-mkdocs,dev-docstrings,dev-formatting,dev-mkdocs,dev-mypy,dev-noxfile,dev-pylint,dev-pytest]",
9191
]
9292

9393
[project.urls]
@@ -104,7 +104,7 @@ include = '\.pyi?$'
104104
[tool.isort]
105105
profile = "black"
106106
line_length = 88
107-
src_paths = ["src", "examples", "tests"]
107+
src_paths = ["benchmarks", "examples", "src", "tests"]
108108

109109
[tool.pylint.similarities]
110110
ignore-comments = ['yes']

src/frequenz/repo/config/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@
286286
requires = [
287287
"setuptools >= 67.3.2, < 68",
288288
"setuptools_scm[toml] >= 7.1.0, < 8",
289-
"frequenz-repo-config[api] >= 0.1.0, < 0.3.0",
289+
"frequenz-repo-config[api] >= 0.3.0, < 0.4.0",
290290
]
291291
build-backend = "setuptools.build_meta"
292292

tests_golden/integration/test_cookiecutter_generation/actor/frequenz-actor-test/pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
requires = [
66
"setuptools == 67.7.2",
77
"setuptools_scm[toml] == 7.1.0",
8-
"frequenz-repo-config[actor] == 0.3.0",
8+
"frequenz-repo-config[actor] == 0.4.0",
99
]
1010
build-backend = "setuptools.build_meta"
1111

@@ -52,7 +52,7 @@ dev-mkdocs = [
5252
"mkdocs-material == 9.1.16",
5353
"mkdocs-section-index == 0.3.5",
5454
"mkdocstrings[python] == 0.22.0",
55-
"frequenz-repo-config[actor] == 0.3.0",
55+
"frequenz-repo-config[actor] == 0.4.0",
5656
]
5757
dev-mypy = [
5858
"mypy == 1.2.0",
@@ -61,7 +61,7 @@ dev-mypy = [
6161
]
6262
dev-noxfile = [
6363
"nox == 2023.4.22",
64-
"frequenz-repo-config[actor] == 0.3.0",
64+
"frequenz-repo-config[actor] == 0.4.0",
6565
]
6666
dev-pylint = [
6767
"pylint == 2.17.3",

tests_golden/integration/test_cookiecutter_generation/api/frequenz-api-test/pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
requires = [
66
"setuptools == 67.7.2",
77
"setuptools_scm[toml] == 7.1.0",
8-
"frequenz-repo-config[api] == 0.3.0",
8+
"frequenz-repo-config[api] == 0.4.0",
99
]
1010
build-backend = "setuptools.build_meta"
1111

@@ -50,7 +50,7 @@ dev-mkdocs = [
5050
"mkdocs-material == 9.1.16",
5151
"mkdocs-section-index == 0.3.5",
5252
"mkdocstrings[python] == 0.22.0",
53-
"frequenz-repo-config[api] == 0.3.0",
53+
"frequenz-repo-config[api] == 0.4.0",
5454
]
5555
dev-mypy = [
5656
"mypy == 1.2.0",
@@ -59,7 +59,7 @@ dev-mypy = [
5959
]
6060
dev-noxfile = [
6161
"nox == 2023.4.22",
62-
"frequenz-repo-config[api] == 0.3.0",
62+
"frequenz-repo-config[api] == 0.4.0",
6363
]
6464
dev-pylint = [
6565
"pylint == 2.17.3",

tests_golden/integration/test_cookiecutter_generation/app/frequenz-app-test/pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
requires = [
66
"setuptools == 67.7.2",
77
"setuptools_scm[toml] == 7.1.0",
8-
"frequenz-repo-config[app] == 0.3.0",
8+
"frequenz-repo-config[app] == 0.4.0",
99
]
1010
build-backend = "setuptools.build_meta"
1111

@@ -51,7 +51,7 @@ dev-mkdocs = [
5151
"mkdocs-material == 9.1.16",
5252
"mkdocs-section-index == 0.3.5",
5353
"mkdocstrings[python] == 0.22.0",
54-
"frequenz-repo-config[app] == 0.3.0",
54+
"frequenz-repo-config[app] == 0.4.0",
5555
]
5656
dev-mypy = [
5757
"mypy == 1.2.0",
@@ -60,7 +60,7 @@ dev-mypy = [
6060
]
6161
dev-noxfile = [
6262
"nox == 2023.4.22",
63-
"frequenz-repo-config[app] == 0.3.0",
63+
"frequenz-repo-config[app] == 0.4.0",
6464
]
6565
dev-pylint = [
6666
"pylint == 2.17.3",

0 commit comments

Comments
 (0)