idf-build-apps 2.0.0b5__tar.gz → 2.0.0rc1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/check-pre-commit.yml +4 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/test-build-idf-apps.yml +3 -3
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/CHANGELOG.md +36 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/PKG-INFO +1 -1
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/find_build.md +1 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/index.rst +1 -0
- idf_build_apps-2.0.0rc1/docs/migration/1.x_to_2.x.md +135 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/__init__.py +4 -3
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/app.py +131 -134
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/config.py +10 -10
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/constants.py +8 -11
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/finder.py +3 -2
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/main.py +45 -7
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/manifest/manifest.py +21 -24
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/manifest/soc_header.py +12 -12
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/session_args.py +17 -9
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/utils.py +50 -24
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/pyproject.toml +1 -1
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/setup.py +1 -1
- idf_build_apps-2.0.0rc1/tests/test_app.py +95 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/tests/test_build.py +11 -11
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/tests/test_finder.py +57 -35
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/tests/test_manifest.py +29 -2
- idf_build_apps-2.0.0b5/tests/test_app.py +0 -34
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.editorconfig +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.git-blame-ignore-revs +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.gitattributes +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/dependabot.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/issue_comment.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/new_issues.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/new_prs.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/publish-pypi.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/test-build-docs.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.gitignore +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.pre-commit-config.yaml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.readthedocs.yml +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/CONTRIBUTING.md +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/LICENSE +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/README.md +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/CHANGELOG.md +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/CONTRIBUTING.md +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/Makefile +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/_apidoc_templates/module.rst_t +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/_apidoc_templates/package.rst_t +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/_apidoc_templates/toc.rst_t +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/_static/espressif-logo.svg +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/_static/theme_overrides.css +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/_templates/layout.html +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/cli.rst +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/conf.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/config_file.md +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/docs/manifest.md +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/__main__.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/build_apps_args.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/junit/__init__.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/junit/report.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/junit/utils.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/log.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/manifest/__init__.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/idf_build_apps/manifest/if_parser.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/license_header.txt +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/tests/conftest.py +0 -0
- {idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/tests/test_utils.py +0 -0
{idf_build_apps-2.0.0b5 → idf_build_apps-2.0.0rc1}/.github/workflows/test-build-idf-apps.yml
RENAMED
|
@@ -28,7 +28,7 @@ jobs:
|
|
|
28
28
|
pip install flit
|
|
29
29
|
flit build
|
|
30
30
|
- name: Upload built python packages
|
|
31
|
-
uses: actions/upload-artifact@
|
|
31
|
+
uses: actions/upload-artifact@v4
|
|
32
32
|
with:
|
|
33
33
|
name: wheel
|
|
34
34
|
path: dist/idf_build_apps-*.whl
|
|
@@ -38,13 +38,13 @@ jobs:
|
|
|
38
38
|
needs: build-python-packages
|
|
39
39
|
strategy:
|
|
40
40
|
matrix:
|
|
41
|
-
idf-branch: [ release-v5.0, release-v5.1 ]
|
|
41
|
+
idf-branch: [ release-v5.0, release-v5.1, release-v5.2 ]
|
|
42
42
|
runs-on: ubuntu-latest
|
|
43
43
|
container:
|
|
44
44
|
image: espressif/idf:${{ matrix.idf-branch }}
|
|
45
45
|
steps:
|
|
46
46
|
- name: Download wheel
|
|
47
|
-
uses: actions/download-artifact@
|
|
47
|
+
uses: actions/download-artifact@v4
|
|
48
48
|
with:
|
|
49
49
|
name: wheel
|
|
50
50
|
- name: Build the Apps
|
|
@@ -2,6 +2,36 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## v2.0.0rc1 (2024-01-05)
|
|
6
|
+
|
|
7
|
+
### BREAKING CHANGE
|
|
8
|
+
|
|
9
|
+
- - Turn `app.build()` arguments to kwargs
|
|
10
|
+
|
|
11
|
+
### Feat
|
|
12
|
+
|
|
13
|
+
- support custom `_pre_build`, `_post_build` in App instances
|
|
14
|
+
- add `json_to_app` method with support custom classes
|
|
15
|
+
|
|
16
|
+
### Fix
|
|
17
|
+
|
|
18
|
+
- remove os-specific `os.mknod`
|
|
19
|
+
- sort App instance correctly
|
|
20
|
+
- modify yaml dict shared by yaml anchors
|
|
21
|
+
- make build_comment a `dump_only` field
|
|
22
|
+
- improve error message when env var IDF_PATH not set
|
|
23
|
+
- search sdkconfig path
|
|
24
|
+
|
|
25
|
+
## v2.0.0rc0 (2023-12-18)
|
|
26
|
+
|
|
27
|
+
### Refactor
|
|
28
|
+
|
|
29
|
+
- remove useless code
|
|
30
|
+
|
|
31
|
+
### Perf
|
|
32
|
+
|
|
33
|
+
- optimize pathlib and os call
|
|
34
|
+
|
|
5
35
|
## v2.0.0b5 (2023-12-13)
|
|
6
36
|
|
|
7
37
|
### Feat
|
|
@@ -96,6 +126,12 @@ All notable changes to this project will be documented in this file.
|
|
|
96
126
|
- migrate `App` class to pydantic model
|
|
97
127
|
- update dependencies and do code upgrade to python 3.7
|
|
98
128
|
|
|
129
|
+
## v1.1.4 (2023-12-29)
|
|
130
|
+
|
|
131
|
+
### Fix
|
|
132
|
+
|
|
133
|
+
- stop modifying yaml dict shared by yaml anchors
|
|
134
|
+
|
|
99
135
|
## v1.1.3 (2023-11-13)
|
|
100
136
|
|
|
101
137
|
### Fix
|
|
@@ -225,6 +225,7 @@ Placeholders are a set of symbols, which could be used when setting work directo
|
|
|
225
225
|
- `@w`: Would be replaced by the wildcard if exists, otherwise would be replaced by the config name.
|
|
226
226
|
- `@n`: Would be replaced by the project name.
|
|
227
227
|
- `@f`: Would be replaced by the escaped project path (replaced "/" to "_").
|
|
228
|
+
- `@v`: Would be replaced by the ESP-IDF version like `5_3_0`.
|
|
228
229
|
- `@i`: Would be replaced by the build index. (only available in `build` command)
|
|
229
230
|
- `@p`: Would be replaced by the parallel build index. (default to `1`, only available in `build` command)
|
|
230
231
|
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
# Migration From 1.x to 2.x
|
|
2
|
+
|
|
3
|
+
There are a few breaking changes in 2.x. This document will help you migrate your code from 1.x to 2.x.
|
|
4
|
+
|
|
5
|
+
## Python Version Support
|
|
6
|
+
|
|
7
|
+
idf-build-apps 1.x supports Python 2.7 and Python 3.4 or newer. idf-build-apps 2.x only supports Python 3.7 or newer.
|
|
8
|
+
|
|
9
|
+
## Logging Related Changes
|
|
10
|
+
|
|
11
|
+
In 2.x, we're following the standard Python logging convention.
|
|
12
|
+
|
|
13
|
+
Before:
|
|
14
|
+
|
|
15
|
+
```python
|
|
16
|
+
from idf_build_apps import LOGGER
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
After:
|
|
20
|
+
|
|
21
|
+
```python
|
|
22
|
+
import logging
|
|
23
|
+
idf_build_apps_logger = logging.getLogger('idf_build_apps')
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Normal Arguments to Keyword-only Arguments
|
|
27
|
+
|
|
28
|
+
In 2.x, we move some arguments from normal arguments to keyword-only arguments. This is to make the API more consistent and easier to use.
|
|
29
|
+
|
|
30
|
+
To understand the difference between these terms better, here's a quick summary:
|
|
31
|
+
- "positonal-only argument" means the argument is a positional-only argument. (python 3.8+ only)
|
|
32
|
+
- "keyword-only argument" means the argument is a keyword-only argument.
|
|
33
|
+
- "normal argument" means the argument is not a positional-only argument, nor a keyword-only argument.
|
|
34
|
+
|
|
35
|
+
For example, in the following function:
|
|
36
|
+
|
|
37
|
+
```python
|
|
38
|
+
def foo(a, /, b, c, *, d=1, e=2, f=3):
|
|
39
|
+
pass
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
- "a" is a positional-only argument.
|
|
43
|
+
- "b" and "c" are normal arguments.
|
|
44
|
+
- "d", "e", and "f" are keyword-only arguments.
|
|
45
|
+
|
|
46
|
+
The following calls are valid:
|
|
47
|
+
|
|
48
|
+
```python
|
|
49
|
+
foo(1, 2, 3, d=4, e=5, f=6)
|
|
50
|
+
foo(1, 2, c=3, d=4, e=5, f=6)
|
|
51
|
+
foo(1, b=2, c=3, d=4, e=5, f=6)
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
The following calls are invalid:
|
|
55
|
+
|
|
56
|
+
```python
|
|
57
|
+
foo(1, 2, 3, 4, 5, 6)
|
|
58
|
+
foo(1, b=2, 3, d=4, e=5, f=6)
|
|
59
|
+
foo(a=1, b=2, c=3, d=4, e=5, f=6)
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### `App.__init__()`
|
|
63
|
+
|
|
64
|
+
The `__init__` function of `App` class, and all its sub-classes, like `CMakeApp`, and `MakeApp`, now takes only `app_dir`, and `target` as normal arguments. All the rest of the arguments are keyword-only arguments.
|
|
65
|
+
|
|
66
|
+
Before:
|
|
67
|
+
|
|
68
|
+
```python
|
|
69
|
+
app = App('foo', 'esp32', 'sdkconfig.ci', 'default')
|
|
70
|
+
```
|
|
71
|
+
|
|
72
|
+
After:
|
|
73
|
+
|
|
74
|
+
```python
|
|
75
|
+
app = App('foo', 'esp32', sdkconfig_path='sdkconfig.ci', config_name='default')
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
or all in keyword-only arguments:
|
|
79
|
+
|
|
80
|
+
```python
|
|
81
|
+
app = App(app_dir='foo', target='esp32', sdkconfig_path='sdkconfig.ci', config_name='default')
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
### `App.build()`
|
|
85
|
+
|
|
86
|
+
The `build` function of `App` class, and all its sub-classes, like `CMakeApp`, and `MakeApp`, now takes all arguments as keyword-only arguments.
|
|
87
|
+
|
|
88
|
+
### `find_apps()`
|
|
89
|
+
|
|
90
|
+
The `find_apps` function now takes only `paths` and `target` as normal arguments. All the rest of the arguments are keyword-only arguments.
|
|
91
|
+
|
|
92
|
+
### `build_apps()`
|
|
93
|
+
|
|
94
|
+
The `build_apps` function now takes only `apps` as normal argument. All the rest of the arguments are keyword-only arguments.
|
|
95
|
+
|
|
96
|
+
## Function Signature Changes
|
|
97
|
+
|
|
98
|
+
In 2.x, we change the signature of some functions to make them more intuitive and self-explanatory.
|
|
99
|
+
|
|
100
|
+
### `find_apps()`
|
|
101
|
+
|
|
102
|
+
- `build_log_path` is renamed to `build_log_filename`. The file will be generated under `build_dir` if specified.
|
|
103
|
+
- `size_json_path` is renamed to `size_json_filename`. The file will be generated under `build_dir` if specified.
|
|
104
|
+
|
|
105
|
+
## CLI Changes
|
|
106
|
+
|
|
107
|
+
In 2.x, we change the separator for some options to better differentiate them from `None` and empty list.
|
|
108
|
+
|
|
109
|
+
- `--modified-components`
|
|
110
|
+
- `--modified-files`
|
|
111
|
+
- `--ignore-app-dependencies-filepatterns`
|
|
112
|
+
|
|
113
|
+
Before:
|
|
114
|
+
|
|
115
|
+
```shell
|
|
116
|
+
idf-build-apps build -p foo -t esp32 --modified-components foo bar --modified-files foo bar --ignore-app-dependencies-filepatterns foo bar
|
|
117
|
+
```
|
|
118
|
+
|
|
119
|
+
After:
|
|
120
|
+
|
|
121
|
+
```shell
|
|
122
|
+
idf-build-apps build -p foo -t esp32 --modified-components 'foo;bar' --modified-files 'foo;bar' --ignore-app-dependencies-filepatterns 'foo;bar'
|
|
123
|
+
```
|
|
124
|
+
|
|
125
|
+
passing `''` to specify it as `None`
|
|
126
|
+
|
|
127
|
+
```shell
|
|
128
|
+
idf-build-apps build -p foo -t esp32 --modified-components ''
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
or passing `';'` to specify it as an empty list
|
|
132
|
+
|
|
133
|
+
```shell
|
|
134
|
+
idf-build-apps build -p foo -t esp32 --modified-components ';'
|
|
135
|
+
```
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# SPDX-FileCopyrightText: 2022-
|
|
1
|
+
# SPDX-FileCopyrightText: 2022-2024 Espressif Systems (Shanghai) CO LTD
|
|
2
2
|
# SPDX-License-Identifier: Apache-2.0
|
|
3
3
|
|
|
4
4
|
"""
|
|
@@ -8,7 +8,7 @@ Tools for building ESP-IDF related apps.
|
|
|
8
8
|
# ruff: noqa: E402
|
|
9
9
|
# avoid circular imports
|
|
10
10
|
|
|
11
|
-
__version__ = '2.0.
|
|
11
|
+
__version__ = '2.0.0rc1'
|
|
12
12
|
|
|
13
13
|
from .session_args import (
|
|
14
14
|
SessionArgs,
|
|
@@ -28,6 +28,7 @@ from .log import (
|
|
|
28
28
|
from .main import (
|
|
29
29
|
build_apps,
|
|
30
30
|
find_apps,
|
|
31
|
+
json_to_app,
|
|
31
32
|
)
|
|
32
33
|
|
|
33
34
|
__all__ = [
|
|
@@ -37,6 +38,6 @@ __all__ = [
|
|
|
37
38
|
'MakeApp',
|
|
38
39
|
'find_apps',
|
|
39
40
|
'build_apps',
|
|
41
|
+
'json_to_app',
|
|
40
42
|
'setup_logging',
|
|
41
|
-
'SESSION_ARGS',
|
|
42
43
|
]
|