Skip to content

Commit 9d1593d

Browse files
committed
Merge branch 'release/v6.1.14'
2 parents ffacd17 + fcba901 commit 9d1593d

File tree

53 files changed

+458
-244
lines changed

Some content is hidden

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

53 files changed

+458
-244
lines changed

HISTORY.rst

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Release Notes
77
.. |INTERPOLATION| replace:: `Interpolation of Values <https://docs.platformio.org/en/latest/projectconf/interpolation.html>`__
88
.. |UNITTESTING| replace:: `Unit Testing <https://docs.platformio.org/en/latest/advanced/unit-testing/index.html>`__
99
.. |DEBUGGING| replace:: `Debugging <https://docs.platformio.org/en/latest/plus/debugging.html>`__
10+
.. |STATICCODEANALYSIS| replace:: `Static Code Analysis <https://docs.platformio.org/en/latest/advanced/static-code-analysis/index.html>`__
1011

1112
.. _release_notes_6:
1213

@@ -17,6 +18,19 @@ Unlock the true potential of embedded software development with
1718
PlatformIO's collaborative ecosystem, embracing declarative principles,
1819
test-driven methodologies, and modern toolchains for unrivaled success.
1920

21+
6.1.14 (2024-03-21)
22+
~~~~~~~~~~~~~~~~~~~
23+
24+
* Introduced the ``--json-output`` option to the `pio test <https://docs.platformio.org/en/latest/core/userguide/cmd_test.html>`__ command, enabling users to generate test results in the JSON format
25+
* Upgraded the build engine to the latest version of SCons (4.7.0) to improve build performance, reliability, and compatibility with other tools and systems (`release notes <https://github.com/SCons/scons/releases/tag/4.7.0>`__)
26+
* Broadened version support for the ``pyelftools`` dependency, enabling compatibility with lower versions and facilitating integration with a wider range of third-party tools (`issue #4834 <https://github.com/platformio/platformio-core/issues/4834>`_)
27+
* Addressed an issue where passing a relative path (``--project-dir``) to the `pio project init <https://docs.platformio.org/en/latest/core/userguide/project/cmd_init.html>`__ command resulted in an error (`issue #4847 <https://github.com/platformio/platformio-core/issues/4847>`_)
28+
* Enhanced |STATICCODEANALYSIS| to accommodate scenarios where custom ``src_dir`` or ``include_dir`` are located outside the project folder (`pull #4874 <https://github.com/platformio/platformio-core/pull/4874>`_)
29+
* Corrected the validation of ``symlink://`` `package specifications <https://docs.platformio.org/en/latest/core/userguide/pkg/cmd_install.html#local-folder>`__ , resolving an issue that caused the package manager to repeatedly reinstall dependencies (`pull #4870 <https://github.com/platformio/platformio-core/pull/4870>`_)
30+
* Resolved an issue related to the relative package path in the `pio pkg publish <https://docs.platformio.org/en/latest/core/userguide/pkg/cmd_publish.html>`__ command
31+
* Resolved an issue where the |LDF| selected an incorrect library version (`issue #4860 <https://github.com/platformio/platformio-core/issues/4860>`_)
32+
* Resolved an issue with the ``hexlify`` filter in the `device monitor <https://docs.platformio.org/en/latest/core/userguide/device/cmd_monitor.html>`__ command, ensuring proper representation of characters with Unicode code points higher than 127 (`issue #4732 <https://github.com/platformio/platformio-core/issues/4732>`_)
33+
2034
6.1.13 (2024-01-12)
2135
~~~~~~~~~~~~~~~~~~~
2236

platformio/__init__.py

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
VERSION = (6, 1, 13)
15+
VERSION = (6, 1, 14)
1616
__version__ = ".".join([str(s) for s in VERSION])
1717

1818
__title__ = "platformio"
@@ -38,15 +38,6 @@
3838
]
3939
__pioremote_endpoint__ = "ssl:host=remote.platformio.org:port=4413"
4040

41-
__core_packages__ = {
42-
"contrib-piohome": "~3.4.2",
43-
"contrib-pioremote": "~1.0.0",
44-
"tool-scons": "~4.40600.0",
45-
"tool-cppcheck": "~1.21100.0",
46-
"tool-clangtidy": "~1.150005.0",
47-
"tool-pvs-studio": "~7.18.0",
48-
}
49-
5041
__check_internet_hosts__ = [
5142
"185.199.110.153", # Github.com
5243
"88.198.170.159", # platformio.org

platformio/account/team/commands/list.py

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,13 @@ def team_list_cmd(orgname, json_output):
4848
table_data.append(
4949
(
5050
"Members:",
51-
", ".join(
52-
(member.get("username") for member in team.get("members"))
53-
)
54-
if team.get("members")
55-
else "-",
51+
(
52+
", ".join(
53+
(member.get("username") for member in team.get("members"))
54+
)
55+
if team.get("members")
56+
else "-"
57+
),
5658
)
5759
)
5860
click.echo(tabulate(table_data, tablefmt="plain"))

platformio/assets/system/99-platformio-udev.rules

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ ATTRS{idVendor}=="067b", ATTRS{idProduct}=="2303", MODE:="0666", ENV{ID_MM_DEVIC
3636

3737
# QinHeng Electronics HL-340 USB-Serial adapter
3838
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="7523", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
39+
# QinHeng Electronics CH343 USB-Serial adapter
40+
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="55d3", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
3941
# QinHeng Electronics CH9102 USB-Serial adapter
4042
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="55d4", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
4143

@@ -85,6 +87,8 @@ ATTRS{idVendor}=="2e8a", ATTRS{idProduct}=="[01]*", MODE:="0666", ENV{ID_MM_DEVI
8587
# AIR32F103
8688
ATTRS{idVendor}=="0d28", ATTRS{idProduct}=="0204", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
8789

90+
# STM32 virtual COM port
91+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="5740", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
8892

8993
#
9094
# Debuggers
@@ -173,4 +177,4 @@ ATTRS{product}=="*CMSIS-DAP*", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID
173177
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2107", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
174178

175179
# Espressif USB JTAG/serial debug unit
176-
ATTRS{idVendor}=="303a", ATTR{idProduct}=="1001", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
180+
ATTRS{idVendor}=="303a", ATTR{idProduct}=="1001", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"

platformio/builder/tools/piobuild.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ def GetBuildType(env):
5454
modes.append("debug")
5555
if "__test" in COMMAND_LINE_TARGETS or env.GetProjectOption("build_type") == "test":
5656
modes.append("test")
57-
return "+".join(modes or ["release"])
57+
return ", ".join(modes or ["release"])
5858

5959

6060
def BuildProgram(env):

platformio/builder/tools/piolib.py

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -309,10 +309,10 @@ def process_dependencies(self):
309309
if not self.dependencies or self._deps_are_processed:
310310
return
311311
self._deps_are_processed = True
312-
for item in self.dependencies:
312+
for dependency in self.dependencies:
313313
found = False
314314
for lb in self.env.GetLibBuilders():
315-
if item["name"] != lb.name:
315+
if not lb.is_dependency_compatible(dependency):
316316
continue
317317
found = True
318318
if lb not in self.depbuilders:
@@ -322,9 +322,20 @@ def process_dependencies(self):
322322
if not found and self.verbose:
323323
sys.stderr.write(
324324
"Warning: Ignored `%s` dependency for `%s` "
325-
"library\n" % (item["name"], self.name)
325+
"library\n" % (dependency["name"], self.name)
326326
)
327327

328+
def is_dependency_compatible(self, dependency):
329+
pkg = PackageItem(self.path)
330+
qualifiers = {"name": self.name, "version": self.version}
331+
if pkg.metadata:
332+
qualifiers = {"name": pkg.metadata.name, "version": pkg.metadata.version}
333+
if pkg.metadata.spec and pkg.metadata.spec.owner:
334+
qualifiers["owner"] = pkg.metadata.spec.owner
335+
return PackageCompatibility.from_dependency(
336+
{k: v for k, v in dependency.items() if k in ("owner", "name", "version")}
337+
).is_compatible(PackageCompatibility(**qualifiers))
338+
328339
def get_search_files(self):
329340
return [
330341
os.path.join(self.src_dir, item)

platformio/builder/tools/piomaxlen.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,10 @@
2323
from platformio.compat import IS_WINDOWS, hashlib_encode_data
2424

2525
# There are the next limits depending on a platform:
26-
# - Windows = 8192
26+
# - Windows = 8191
2727
# - Unix = 131072
2828
# We need ~512 characters for compiler and temporary file paths
29-
MAX_LINE_LENGTH = (8192 if IS_WINDOWS else 131072) - 512
29+
MAX_LINE_LENGTH = (8191 if IS_WINDOWS else 131072) - 512
3030

3131
WINPATHSEP_RE = re.compile(r"\\([^\"'\\]|$)")
3232

platformio/builder/tools/pioplatform.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -75,9 +75,11 @@ def LoadPioPlatform(env):
7575
continue
7676
env.PrependENVPath(
7777
"PATH",
78-
os.path.join(pkg.path, "bin")
79-
if os.path.isdir(os.path.join(pkg.path, "bin"))
80-
else pkg.path,
78+
(
79+
os.path.join(pkg.path, "bin")
80+
if os.path.isdir(os.path.join(pkg.path, "bin"))
81+
else pkg.path
82+
),
8183
)
8284
if (
8385
not IS_WINDOWS

platformio/check/cli.py

Lines changed: 25 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -103,10 +103,21 @@ def cli(
103103
"%s: %s" % (k, ", ".join(v) if isinstance(v, list) else v)
104104
)
105105

106-
default_src_filters = [
107-
"+<%s>" % os.path.basename(config.get("platformio", "src_dir")),
108-
"+<%s>" % os.path.basename(config.get("platformio", "include_dir")),
109-
]
106+
default_src_filters = []
107+
for d in (
108+
config.get("platformio", "src_dir"),
109+
config.get("platformio", "include_dir"),
110+
):
111+
try:
112+
default_src_filters.append("+<%s>" % os.path.relpath(d))
113+
except ValueError as exc:
114+
# On Windows if sources are located on a different logical drive
115+
if not json_output and not silent:
116+
click.echo(
117+
"Error: Project cannot be analyzed! The project folder `%s`"
118+
" is located on a different logical drive\n" % d
119+
)
120+
raise exception.ReturnErrorCode(1) from exc
110121

111122
env_src_filters = (
112123
src_filters
@@ -122,9 +133,11 @@ def cli(
122133
silent=silent,
123134
src_filters=env_src_filters,
124135
flags=flags or env_options.get("check_flags"),
125-
severity=[DefectItem.SEVERITY_LABELS[DefectItem.SEVERITY_HIGH]]
126-
if silent
127-
else severity or config.get("env:" + envname, "check_severity"),
136+
severity=(
137+
[DefectItem.SEVERITY_LABELS[DefectItem.SEVERITY_HIGH]]
138+
if silent
139+
else severity or config.get("env:" + envname, "check_severity")
140+
),
128141
skip_packages=skip_packages or env_options.get("check_skip_packages"),
129142
platform_packages=env_options.get("platform_packages"),
130143
)
@@ -142,9 +155,11 @@ def cli(
142155

143156
result = {"env": envname, "tool": tool, "duration": time()}
144157
rc = ct.check(
145-
on_defect_callback=None
146-
if (json_output or verbose)
147-
else lambda defect: click.echo(repr(defect))
158+
on_defect_callback=(
159+
None
160+
if (json_output or verbose)
161+
else lambda defect: click.echo(repr(defect))
162+
)
148163
)
149164

150165
result["defects"] = ct.get_defects()

0 commit comments

Comments
 (0)