Skip to content

Commit

Permalink
Merge branch 'release/v6.1.12'
Browse files Browse the repository at this point in the history
  • Loading branch information
ivankravets committed Jan 10, 2024
2 parents c2b3097 + a2f3e85 commit ca1f633
Show file tree
Hide file tree
Showing 45 changed files with 441 additions and 209 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-20.04, windows-latest, macos-latest]
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10", "3.11"]
python-version: ["3.6", "3.7", "3.11", "3.12"]

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
submodules: "recursive"

Expand All @@ -37,7 +37,7 @@ jobs:
tox -e lint
- name: Integration Tests
if: ${{ matrix.python-version == '3.9' }}
if: ${{ matrix.python-version == '3.11' }}
run: |
tox -e testcore
Expand Down
7 changes: 4 additions & 3 deletions .github/workflows/deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,14 @@ jobs:
environment: production

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
submodules: "recursive"

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.9"
python-version: "3.11"

- name: Install dependencies
run: |
Expand All @@ -35,7 +35,8 @@ jobs:
tox -e testcore
- name: Build Python source tarball
run: python setup.py sdist bdist_wheel
# run: python setup.py sdist bdist_wheel
run: python setup.py sdist

- name: Publish package to PyPI
if: ${{ github.ref == 'refs/heads/master' }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ jobs:
name: Build Docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
submodules: "recursive"
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9
python-version: "3.11"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down Expand Up @@ -78,7 +78,7 @@ jobs:
fi
- name: Checkout latest Docs
continue-on-error: true
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
repository: ${{ env.DOCS_REPO }}
path: ${{ env.DOCS_DIR }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,14 @@ jobs:
PIO_INSTALL_DEVPLATFORM_NAMES: "aceinna_imu,atmelavr,atmelmegaavr,atmelsam,espressif32,espressif8266,nordicnrf52,raspberrypi,ststm32,teensy"

steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
submodules: "recursive"

- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.9"
python-version: "3.11"

- name: Install dependencies
run: |
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/projects.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,20 +40,20 @@ jobs:

runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
with:
submodules: "recursive"

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: 3.9
python-version: 3.11

- name: Install PlatformIO
run: pip install -U .

- name: Check out ${{ matrix.project.repository }}
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
submodules: "recursive"
repository: ${{ matrix.project.repository }}
Expand Down
20 changes: 20 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,26 @@ Unlock the true potential of embedded software development with
PlatformIO's collaborative ecosystem, embracing declarative principles,
test-driven methodologies, and modern toolchains for unrivaled success.

6.1.12 (2024-01-10)
~~~~~~~~~~~~~~~~~~~

* Added support for Python 3.12
* Introduced the capability to launch the debug server in a separate process (`issue #4722 <https://github.com/platformio/platformio-core/issues/4722>`_)
* Introduced a warning during the verification of MCU maximum RAM usage, signaling when the allocated RAM surpasses 100% (`issue #4791 <https://github.com/platformio/platformio-core/issues/4791>`_)
* Drastically enhanced the speed of project building when operating in verbose mode (`issue #4783 <https://github.com/platformio/platformio-core/issues/4783>`_)
* Upgraded the build engine to the latest version of SCons (4.6.0) to improve build performance, reliability, and compatibility with other tools and systems (`release notes <https://github.com/SCons/scons/releases/tag/4.6.0>`__)
* Enhanced the handling of built-in variables in |PIOCONF| during |INTERPOLATION| (`issue #4695 <https://github.com/platformio/platformio-core/issues/4695>`_)
* Enhanced PIP dependency declarations for improved reliability and extended support to include Python 3.6 (`issue #4819 <https://github.com/platformio/platformio-core/issues/4819>`_)
* Implemented automatic installation of missing dependencies when utilizing a SOCKS proxy (`issue #4822 <https://github.com/platformio/platformio-core/issues/4822>`_)
* Implemented a fail-safe mechanism to terminate a debugging session if an unknown CLI option is passed (`issue #4699 <https://github.com/platformio/platformio-core/issues/4699>`_)
* Rectified an issue where ``${platformio.name}`` erroneously represented ``None`` as the default `project name <https://docs.platformio.org/en/latest/projectconf/sections/platformio/options/generic/name.html>`__ (`issue #4717 <https://github.com/platformio/platformio-core/issues/4717>`_)
* Resolved an issue where the ``COMPILATIONDB_INCLUDE_TOOLCHAIN`` setting was not correctly applying to private libraries (`issue #4762 <https://github.com/platformio/platformio-core/issues/4762>`_)
* Resolved an issue where ``get_systype()`` inaccurately returned the architecture when executed within a Docker container on a 64-bit kernel with a 32-bit userspace (`issue #4777 <https://github.com/platformio/platformio-core/issues/4777>`_)
* Resolved an issue with incorrect handling of the ``check_src_filters`` option when used in multiple environments (`issue #4788 <https://github.com/platformio/platformio-core/issues/4788>`_)
* Resolved an issue where running `pio project metadata <https://docs.platformio.org/en/latest/core/userguide/project/cmd_metadata.html>`__ resulted in duplicated "include" entries (`issue #4723 <https://github.com/platformio/platformio-core/issues/4723>`_)
* Resolved an issue where native debugging failed on the host machine (`issue #4745 <https://github.com/platformio/platformio-core/issues/4745>`_)
* Resolved an issue where custom debug configurations were being inadvertently overwritten in VSCode's ``launch.json`` (`issue #4810 <https://github.com/platformio/platformio-core/issues/4810>`_)

6.1.11 (2023-08-31)
~~~~~~~~~~~~~~~~~~~

Expand Down
2 changes: 1 addition & 1 deletion docs
Submodule docs updated 116 files
23 changes: 2 additions & 21 deletions platformio/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

VERSION = (6, 1, 11)
VERSION = (6, 1, 12)
__version__ = ".".join([str(s) for s in VERSION])

__title__ = "platformio"
Expand Down Expand Up @@ -41,7 +41,7 @@
__core_packages__ = {
"contrib-piohome": "~3.4.2",
"contrib-pioremote": "~1.0.0",
"tool-scons": "~4.40502.0",
"tool-scons": "~4.40600.0",
"tool-cppcheck": "~1.21100.0",
"tool-clangtidy": "~1.150005.0",
"tool-pvs-studio": "~7.18.0",
Expand All @@ -52,22 +52,3 @@
"88.198.170.159", # platformio.org
"github.com",
] + __registry_mirror_hosts__

__install_requires__ = [
# Core requirements
"bottle == 0.12.*",
"click >=8.0.4, <=8.2",
"colorama",
"marshmallow == 3.*",
"pyelftools == 0.29",
"pyserial == 3.5.*", # keep in sync "device/monitor/terminal.py"
"requests == 2.*",
"semantic_version == 2.10.*",
"tabulate == 0.*",
] + [
# PIO Home requirements
"ajsonrpc == 1.2.*",
"starlette >=0.19, <0.32",
"uvicorn >=0.16, <0.24",
"wsproto == 1.*",
]
3 changes: 3 additions & 0 deletions platformio/assets/system/99-platformio-udev.rules
Original file line number Diff line number Diff line change
Expand Up @@ -171,3 +171,6 @@ ATTRS{product}=="*CMSIS-DAP*", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID

# Atmel AVR Dragon
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2107", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"

# Espressif USB JTAG/serial debug unit
ATTRS{idVendor}=="303a", ATTR{idProduct}=="1001", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
6 changes: 6 additions & 0 deletions platformio/builder/tools/piobuild.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,10 @@ def _append_pio_macros():
# remove specified flags
env.ProcessUnFlags(env.get("BUILD_UNFLAGS"))

env.ProcessCompileDbToolchainOption()


def ProcessCompileDbToolchainOption(env):
if "compiledb" in COMMAND_LINE_TARGETS:
# Resolve absolute path of toolchain
for cmd in ("CC", "CXX", "AS"):
Expand All @@ -138,6 +142,7 @@ def _append_pio_macros():
)

if env.get("COMPILATIONDB_INCLUDE_TOOLCHAIN"):
print("Warning! `COMPILATIONDB_INCLUDE_TOOLCHAIN` is scoping")
for scope, includes in env.DumpIntegrationIncludes().items():
if scope in ("toolchain",):
env.Append(CPPPATH=includes)
Expand Down Expand Up @@ -376,6 +381,7 @@ def generate(env):
env.AddMethod(GetBuildType)
env.AddMethod(BuildProgram)
env.AddMethod(ProcessProgramDeps)
env.AddMethod(ProcessCompileDbToolchainOption)
env.AddMethod(ProcessProjectDeps)
env.AddMethod(ParseFlagsExtended)
env.AddMethod(ProcessFlags)
Expand Down
7 changes: 1 addition & 6 deletions platformio/builder/tools/piointegration.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,7 @@ def IsIntegrationDump(_):
def DumpIntegrationIncludes(env):
result = dict(build=[], compatlib=[], toolchain=[])

result["build"].extend(
[
env.subst("$PROJECT_INCLUDE_DIR"),
env.subst("$PROJECT_SRC_DIR"),
]
)
# `env`(project) CPPPATH
result["build"].extend(
[os.path.abspath(env.subst(item)) for item in env.get("CPPPATH", [])]
)
Expand Down
5 changes: 4 additions & 1 deletion platformio/builder/tools/piolib.py
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,7 @@ def build(self):
self.is_built = True

self.env.PrependUnique(CPPPATH=self.get_include_dirs())
self.env.ProcessCompileDbToolchainOption()

if self.lib_ldf_mode == "off":
for lb in self.env.GetLibBuilders():
Expand Down Expand Up @@ -791,7 +792,9 @@ def get_include_dirs(self):
include_dirs.append(os.path.join(self.path, "utility"))

for path in self.env.get("CPPPATH", []):
if path not in self.envorigin.get("CPPPATH", []):
if path not in include_dirs and path not in self.envorigin.get(
"CPPPATH", []
):
include_dirs.append(self.env.subst(path))

return include_dirs
Expand Down
11 changes: 5 additions & 6 deletions platformio/builder/tools/pioupload.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,12 +218,11 @@ def _format_availale_bytes(value, total):
if int(ARGUMENTS.get("PIOVERBOSE", 0)):
print(output)

# raise error
# if data_max_size and data_size > data_max_size:
# sys.stderr.write(
# "Error: The data size (%d bytes) is greater "
# "than maximum allowed (%s bytes)\n" % (data_size, data_max_size))
# env.Exit(1)
if data_max_size and data_size > data_max_size:
sys.stderr.write(
"Warning! The data size (%d bytes) is greater "
"than maximum allowed (%s bytes)\n" % (data_size, data_max_size)
)
if program_size > program_max_size:
sys.stderr.write(
"Error: The program size (%d bytes) is greater "
Expand Down
4 changes: 2 additions & 2 deletions platformio/check/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ def cli(
"+<%s>" % os.path.basename(config.get("platformio", "include_dir")),
]

src_filters = (
env_src_filters = (
src_filters
or pattern
or env_options.get(
Expand All @@ -120,7 +120,7 @@ def cli(
tool_options = dict(
verbose=verbose,
silent=silent,
src_filters=src_filters,
src_filters=env_src_filters,
flags=flags or env_options.get("check_flags"),
severity=[DefectItem.SEVERITY_LABELS[DefectItem.SEVERITY_HIGH]]
if silent
Expand Down
9 changes: 5 additions & 4 deletions platformio/commands/upgrade.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@

import click

from platformio import VERSION, __install_requires__, __version__, app, exception
from platformio import VERSION, __version__, app, exception
from platformio.http import fetch_remote_content
from platformio.package.manager.core import update_core_packages
from platformio.pipdeps import get_pip_dependencies
from platformio.proc import get_pythonexe_path

PYPI_JSON_URL = "https://pypi.org/pypi/platformio/json"
Expand All @@ -37,7 +38,7 @@
@click.option("--verbose", "-v", is_flag=True)
def cli(dev, only_dependencies, verbose):
if only_dependencies:
return upgrade_pypi_dependencies(verbose)
return upgrade_pip_dependencies(verbose)

update_core_packages()

Expand Down Expand Up @@ -102,7 +103,7 @@ def cli(dev, only_dependencies, verbose):
return True


def upgrade_pypi_dependencies(verbose):
def upgrade_pip_dependencies(verbose):
subprocess.run(
[
get_pythonexe_path(),
Expand All @@ -111,7 +112,7 @@ def upgrade_pypi_dependencies(verbose):
"install",
"--upgrade",
"pip",
*__install_requires__,
*get_pip_dependencies(),
],
check=True,
stdout=subprocess.PIPE if not verbose else None,
Expand Down
Loading

0 comments on commit ca1f633

Please sign in to comment.