idf-build-apps 2.6.2__py3-none-any.whl → 2.6.4__py3-none-any.whl
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/__init__.py +1 -1
- idf_build_apps/app.py +6 -1
- idf_build_apps/args.py +2 -16
- idf_build_apps/main.py +10 -2
- idf_build_apps/utils.py +16 -2
- {idf_build_apps-2.6.2.dist-info → idf_build_apps-2.6.4.dist-info}/METADATA +1 -1
- {idf_build_apps-2.6.2.dist-info → idf_build_apps-2.6.4.dist-info}/RECORD +10 -10
- {idf_build_apps-2.6.2.dist-info → idf_build_apps-2.6.4.dist-info}/LICENSE +0 -0
- {idf_build_apps-2.6.2.dist-info → idf_build_apps-2.6.4.dist-info}/WHEEL +0 -0
- {idf_build_apps-2.6.2.dist-info → idf_build_apps-2.6.4.dist-info}/entry_points.txt +0 -0
idf_build_apps/__init__.py
CHANGED
idf_build_apps/app.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# SPDX-FileCopyrightText: 2022-
|
|
1
|
+
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
|
|
2
2
|
# SPDX-License-Identifier: Apache-2.0
|
|
3
3
|
|
|
4
4
|
import copy
|
|
@@ -127,6 +127,11 @@ class App(BaseModel):
|
|
|
127
127
|
__EQ_IGNORE_FIELDS__ = [
|
|
128
128
|
'build_comment',
|
|
129
129
|
]
|
|
130
|
+
__EQ_TUNE_FIELDS__ = {
|
|
131
|
+
'app_dir': lambda x: (os.path.realpath(os.path.expanduser(x))),
|
|
132
|
+
'work_dir': lambda x: (os.path.realpath(os.path.expanduser(x))),
|
|
133
|
+
'build_dir': lambda x: (os.path.realpath(os.path.expanduser(x))),
|
|
134
|
+
}
|
|
130
135
|
|
|
131
136
|
def __init__(
|
|
132
137
|
self,
|
idf_build_apps/args.py
CHANGED
|
@@ -323,19 +323,6 @@ class DependencyDrivenBuildArguments(GlobalArguments):
|
|
|
323
323
|
root_path=to_absolute_path(self.manifest_rootpath),
|
|
324
324
|
)
|
|
325
325
|
|
|
326
|
-
if self.deactivate_dependency_driven_build_by_components is not None:
|
|
327
|
-
if self.modified_components is None:
|
|
328
|
-
raise InvalidCommand(
|
|
329
|
-
'Must specify --deactivate-dependency-driven-build-by-components '
|
|
330
|
-
'together with --modified-components'
|
|
331
|
-
)
|
|
332
|
-
|
|
333
|
-
if self.deactivate_dependency_driven_build_by_filepatterns is not None:
|
|
334
|
-
if self.modified_files is None:
|
|
335
|
-
raise InvalidCommand(
|
|
336
|
-
'Must specify --deactivate-dependency-driven-build-by-filepatterns together with --modified-files'
|
|
337
|
-
)
|
|
338
|
-
|
|
339
326
|
@property
|
|
340
327
|
def dependency_driven_build_enabled(self) -> bool:
|
|
341
328
|
"""
|
|
@@ -450,7 +437,7 @@ class FindBuildArguments(DependencyDrivenBuildArguments):
|
|
|
450
437
|
FieldMetadata(
|
|
451
438
|
deprecates={'size_file': {}},
|
|
452
439
|
),
|
|
453
|
-
description='`idf.py size` output file under the build directory when specified.
|
|
440
|
+
description='`idf.py size` output file under the build directory when specified. Can expand placeholders',
|
|
454
441
|
validation_alias=AliasChoices('size_json_filename', 'size_file'),
|
|
455
442
|
default=None, # type: ignore
|
|
456
443
|
)
|
|
@@ -654,8 +641,7 @@ class BuildArguments(FindBuildArguments):
|
|
|
654
641
|
},
|
|
655
642
|
nargs='+',
|
|
656
643
|
),
|
|
657
|
-
description='space-separated list of patterns. '
|
|
658
|
-
'Ignore the warnings in the build output that match the patterns',
|
|
644
|
+
description='space-separated list of patterns. Ignore the warnings in the build output that match the patterns',
|
|
659
645
|
validation_alias=AliasChoices('ignore_warning_strs', 'ignore_warning_str'),
|
|
660
646
|
default=None, # type: ignore
|
|
661
647
|
)
|
idf_build_apps/main.py
CHANGED
|
@@ -10,6 +10,7 @@ import os
|
|
|
10
10
|
import sys
|
|
11
11
|
import textwrap
|
|
12
12
|
import typing as t
|
|
13
|
+
from pathlib import Path
|
|
13
14
|
|
|
14
15
|
import argcomplete
|
|
15
16
|
from pydantic import (
|
|
@@ -99,7 +100,7 @@ def find_apps(
|
|
|
99
100
|
else:
|
|
100
101
|
app_cls = find_arguments.build_system
|
|
101
102
|
|
|
102
|
-
apps =
|
|
103
|
+
apps: t.Set[App] = set()
|
|
103
104
|
if find_arguments.target == 'all':
|
|
104
105
|
targets = ALL_TARGETS
|
|
105
106
|
else:
|
|
@@ -107,7 +108,7 @@ def find_apps(
|
|
|
107
108
|
|
|
108
109
|
for _t in targets:
|
|
109
110
|
for _p in find_arguments.paths:
|
|
110
|
-
apps.
|
|
111
|
+
apps.update(
|
|
111
112
|
_find_apps(
|
|
112
113
|
_p,
|
|
113
114
|
_t,
|
|
@@ -170,6 +171,13 @@ def build_apps(
|
|
|
170
171
|
LOGGER.debug('Remove existing collect file %s', f)
|
|
171
172
|
|
|
172
173
|
exit_code = 0
|
|
174
|
+
|
|
175
|
+
# create empty files, avoid no file when no app is built
|
|
176
|
+
if build_arguments.collect_app_info:
|
|
177
|
+
Path(build_arguments.collect_app_info).touch()
|
|
178
|
+
if build_arguments.collect_size_info:
|
|
179
|
+
Path(build_arguments.collect_size_info).touch()
|
|
180
|
+
|
|
173
181
|
for i, app in enumerate(apps):
|
|
174
182
|
index = i + 1 # we use 1-based
|
|
175
183
|
if index < start or index > stop:
|
idf_build_apps/utils.py
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# SPDX-FileCopyrightText: 2022-
|
|
1
|
+
# SPDX-FileCopyrightText: 2022-2025 Espressif Systems (Shanghai) CO LTD
|
|
2
2
|
# SPDX-License-Identifier: Apache-2.0
|
|
3
3
|
|
|
4
4
|
import fnmatch
|
|
@@ -340,6 +340,7 @@ class BaseModel(_BaseModel):
|
|
|
340
340
|
"""
|
|
341
341
|
|
|
342
342
|
__EQ_IGNORE_FIELDS__: t.List[str] = []
|
|
343
|
+
__EQ_TUNE_FIELDS__: t.Dict[str, t.Callable[[t.Any], t.Any]] = {}
|
|
343
344
|
|
|
344
345
|
def __lt__(self, other: t.Any) -> bool:
|
|
345
346
|
if isinstance(other, self.__class__):
|
|
@@ -350,6 +351,10 @@ class BaseModel(_BaseModel):
|
|
|
350
351
|
self_attr = getattr(self, k, '') or ''
|
|
351
352
|
other_attr = getattr(other, k, '') or ''
|
|
352
353
|
|
|
354
|
+
if k in self.__EQ_TUNE_FIELDS__:
|
|
355
|
+
self_attr = str(self.__EQ_TUNE_FIELDS__[k](self_attr))
|
|
356
|
+
other_attr = str(self.__EQ_TUNE_FIELDS__[k](other_attr))
|
|
357
|
+
|
|
353
358
|
if self_attr != other_attr:
|
|
354
359
|
return self_attr < other_attr
|
|
355
360
|
|
|
@@ -369,13 +374,22 @@ class BaseModel(_BaseModel):
|
|
|
369
374
|
self_model_dump.pop(_field, None)
|
|
370
375
|
other_model_dump.pop(_field, None)
|
|
371
376
|
|
|
377
|
+
for _field in self.__EQ_TUNE_FIELDS__:
|
|
378
|
+
self_model_dump[_field] = self.__EQ_TUNE_FIELDS__[_field](self_model_dump[_field])
|
|
379
|
+
other_model_dump[_field] = self.__EQ_TUNE_FIELDS__[_field](other_model_dump[_field])
|
|
380
|
+
|
|
372
381
|
return self_model_dump == other_model_dump
|
|
373
382
|
|
|
374
383
|
return NotImplemented
|
|
375
384
|
|
|
376
385
|
def __hash__(self) -> int:
|
|
377
386
|
hash_list = []
|
|
378
|
-
|
|
387
|
+
|
|
388
|
+
self_model_dump = self.model_dump()
|
|
389
|
+
for _field in self.__EQ_TUNE_FIELDS__:
|
|
390
|
+
self_model_dump[_field] = self.__EQ_TUNE_FIELDS__[_field](self_model_dump[_field])
|
|
391
|
+
|
|
392
|
+
for v in self_model_dump.values():
|
|
379
393
|
if isinstance(v, list):
|
|
380
394
|
hash_list.append(tuple(v))
|
|
381
395
|
elif isinstance(v, dict):
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
idf_build_apps/__init__.py,sha256=
|
|
1
|
+
idf_build_apps/__init__.py,sha256=4YQAUfHodWwG2N97CUD5qms_PxD1g8JuEWPO4q6vynY,650
|
|
2
2
|
idf_build_apps/__main__.py,sha256=8E-5xHm2MlRun0L88XJleNh5U50dpE0Q1nK5KqomA7I,182
|
|
3
|
-
idf_build_apps/app.py,sha256=
|
|
4
|
-
idf_build_apps/args.py,sha256=
|
|
3
|
+
idf_build_apps/app.py,sha256=v85SiN56-yOxxo48owo9JLgL56sQjsR6c5ScBES4wxA,37611
|
|
4
|
+
idf_build_apps/args.py,sha256=rNOzetQYyfCfz9RQq_bzLXL6FrFpJllvLU2VooL_p9s,34178
|
|
5
5
|
idf_build_apps/autocompletions.py,sha256=g-bx0pzXoFKI0VQqftkHyGVWN6MLjuFOdozeuAf45yo,2138
|
|
6
6
|
idf_build_apps/constants.py,sha256=HU0rtKqhvLj9nMsy6XvyQMjMEBliNi9xaS2D8CQEPsE,2421
|
|
7
7
|
idf_build_apps/finder.py,sha256=hY6uSMB2s65MqMKIDBSHABOfa93mOLT7x5hlMxC43EQ,5794
|
|
8
8
|
idf_build_apps/log.py,sha256=pyvT7N4MWzGjIXph5mThQCGBiSt53RNPW0WrFfLr0Kw,2650
|
|
9
|
-
idf_build_apps/main.py,sha256=
|
|
9
|
+
idf_build_apps/main.py,sha256=zp1MvX78qlrF2qZ3kqBQAo27Q3b8ZczsGicABdpXID4,16866
|
|
10
10
|
idf_build_apps/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
11
|
idf_build_apps/session_args.py,sha256=2WDTy40IFAc0KQ57HaeBcYj_k10eUXRKkDOWLrFCaHY,2985
|
|
12
|
-
idf_build_apps/utils.py,sha256=
|
|
12
|
+
idf_build_apps/utils.py,sha256=cQJ5N-53vrASa4d8WW0AQCPJzendArXyU3kB5Vx-AH8,10880
|
|
13
13
|
idf_build_apps/junit/__init__.py,sha256=IxvdaS6eSXp7kZxRuXqyZyGxuA_A1nOW1jF1HMi8Gns,231
|
|
14
14
|
idf_build_apps/junit/report.py,sha256=T7dVU3Sz5tqjfbcFW7wjsb65PDH6C2HFf73ePJqBhMs,6555
|
|
15
15
|
idf_build_apps/junit/utils.py,sha256=NXZxQD4tdbSVKjKMNx1kO2H3IoEiysXkDoDjLEf1RO8,1303
|
|
@@ -20,8 +20,8 @@ idf_build_apps/vendors/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3
|
|
|
20
20
|
idf_build_apps/vendors/pydantic_sources.py,sha256=cxSIPRc3eI5peVMhDxwf58YaGhuG4SCwPRVX2znFEek,4553
|
|
21
21
|
idf_build_apps/yaml/__init__.py,sha256=W-3z5no07RQ6eYKGyOAPA8Z2CLiMPob8DD91I4URjrA,162
|
|
22
22
|
idf_build_apps/yaml/parser.py,sha256=b3LvogO6do-eJPRsYzT-8xk8AT2MnXpLCzQutJqyC7M,2128
|
|
23
|
-
idf_build_apps-2.6.
|
|
24
|
-
idf_build_apps-2.6.
|
|
25
|
-
idf_build_apps-2.6.
|
|
26
|
-
idf_build_apps-2.6.
|
|
27
|
-
idf_build_apps-2.6.
|
|
23
|
+
idf_build_apps-2.6.4.dist-info/entry_points.txt,sha256=3pVUirUEsb6jsDRikkQWNUt4hqLK2ci1HvW_Vf8b6uE,59
|
|
24
|
+
idf_build_apps-2.6.4.dist-info/LICENSE,sha256=z8d0m5b2O9McPEK1xHG_dWgUBT6EfBDz6wA0F7xSPTA,11358
|
|
25
|
+
idf_build_apps-2.6.4.dist-info/WHEEL,sha256=CpUCUxeHQbRN5UGRQHYRJorO5Af-Qy_fHMctcQ8DSGI,82
|
|
26
|
+
idf_build_apps-2.6.4.dist-info/METADATA,sha256=jlNXdbm6ZA-m4j-vCpm9QUO0YT8OIZWLJ7IXGQN1Nqw,4693
|
|
27
|
+
idf_build_apps-2.6.4.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|