Skip to content

Commit

Permalink
Resolved an issue where native debugging failed on the host machine //
Browse files Browse the repository at this point in the history
…Resolve #4745
  • Loading branch information
ivankravets committed Dec 9, 2023
1 parent 77e6d1b commit e4c4f2a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 10 deletions.
1 change: 1 addition & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ test-driven methodologies, and modern toolchains for unrivaled success.
* 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>`_)

6.1.11 (2023-08-31)
~~~~~~~~~~~~~~~~~~~
Expand Down
16 changes: 6 additions & 10 deletions platformio/debug/config/factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,13 @@ def get_clsname(name):

@classmethod
def new(cls, platform, project_config, env_name):
board_config = platform.board_config(
project_config.get("env:" + env_name, "board")
)
tool_name = (
board_config.get_debug_tool_name(
project_config.get("env:" + env_name, "debug_tool")
)
if board_config
else None
)
board_id = project_config.get("env:" + env_name, "board")
config_cls = None
tool_name = None
if board_id:
tool_name = platform.board_config(
project_config.get("env:" + env_name, "board")
).get_debug_tool_name(project_config.get("env:" + env_name, "debug_tool"))
try:
mod = importlib.import_module("platformio.debug.config.%s" % tool_name)
config_cls = getattr(mod, cls.get_clsname(tool_name))
Expand Down
1 change: 1 addition & 0 deletions platformio/platform/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,7 @@ def _append_board(board_id, manifest_path):
return self._BOARDS_CACHE[id_] if id_ else self._BOARDS_CACHE

def board_config(self, id_):
assert id_
return self.get_boards(id_)

def get_package_type(self, name):
Expand Down

0 comments on commit e4c4f2a

Please sign in to comment.