Introduced the PLATFORMIO_RUN_JOBS environment variable // Resolve #5077

This commit is contained in:
Ivan Kravets
2025-02-08 17:15:34 +02:00
parent c9016d6939
commit 1be6e10f99
5 changed files with 10 additions and 7 deletions

View File

@ -21,6 +21,7 @@ test-driven methodologies, and modern toolchains for unrivaled success.
6.1.17 (2024-??-??)
~~~~~~~~~~~~~~~~~~~
* Introduced the `PLATFORMIO_RUN_JOBS <https://docs.platformio.org/en/latest/envvars.html#envvar-PLATFORMIO_RUN_JOBS>`__ environment variable, allowing manual override of the number of parallel build jobs (`issue #5077 <https://github.com/platformio/platformio-core/issues/5077>`_)
* Added support for ``tar.xz`` tarball dependencies (`pull #4974 <https://github.com/platformio/platformio-core/pull/4974>`_)
* Ensured that dependencies of private libraries are no longer unnecessarily re-installed, optimizing dependency management and reducing redundant operations (`issue #4987 <https://github.com/platformio/platformio-core/issues/4987>`_)
* Resolved an issue where the ``compiledb`` target failed to properly escape compiler executable paths containing spaces (`issue #4998 <https://github.com/platformio/platformio-core/issues/4998>`_)

2
docs

Submodule docs updated: 9f64f54adc...93c46bdf3f

View File

@ -33,9 +33,11 @@ from platformio.test.runners.base import CTX_META_TEST_IS_RUNNING
# pylint: disable=too-many-arguments,too-many-locals,too-many-branches
try:
DEFAULT_JOB_NUMS = cpu_count()
SYSTEM_CPU_COUNT = cpu_count()
except NotImplementedError:
DEFAULT_JOB_NUMS = 1
SYSTEM_CPU_COUNT = 1
DEFAULT_JOB_NUMS = int(os.getenv("PLATFORMIO_RUN_JOBS", SYSTEM_CPU_COUNT))
@click.command("run", short_help="Run project targets (build, upload, clean, etc.)")

View File

@ -31,7 +31,7 @@ PROJECT_CONFIG_TPL = """
[env]
platform = platformio/atmelavr@^3.4.0
lib_deps =
milesburton/DallasTemperature@^3.9.1
milesburton/DallasTemperature@^4.0.4
https://github.com/esphome/ESPAsyncWebServer/archive/refs/tags/v2.1.0.zip
[env:baremetal]
@ -215,7 +215,7 @@ def test_project(
PackageSpec("toolchain-atmelavr@1.70300.191015"),
]
assert config.get("env:devkit", "lib_deps") == [
"milesburton/DallasTemperature@^3.9.1",
"milesburton/DallasTemperature@^4.0.4",
"https://github.com/esphome/ESPAsyncWebServer/archive/refs/tags/v2.1.0.zip",
]
@ -241,7 +241,7 @@ def test_private_lib_deps(
"version": "1.0.0",
"dependencies": {
"bblanchon/ArduinoJson": "^5",
"milesburton/DallasTemperature": "^3.9.1"
"milesburton/DallasTemperature": "^4.0.4"
}
}
"""

View File

@ -235,7 +235,7 @@ def test_global_lib_update_check(clirunner, validate_cliresult):
validate_cliresult(result)
output = json.loads(result.output)
assert set(
["Adafruit PN532", "AsyncMqttClient", "ESPAsyncTCP", "NeoPixelBus"]
["Adafruit PN532", "AsyncMqttClient", "AsyncTCP", "ESPAsyncTCP", "NeoPixelBus"]
) == set(lib["name"] for lib in output)