Skip to content

Commit 31661d6

Browse files
committed
compile: New implementation of multi-file compilation using mpy-tool.
Add a new implementation of `compile_multi_file()` that uses `mpy-tool` to find imports. This will work better than the previous implementation that used Python's `ModuleFinder`, which had several shortcomings. This is only implemented for MPY ABI v6 for now. To make it work for older ABIs, we would need to get an older copy of `mpy-tool`, and backport the json output feature to it.
1 parent f162083 commit 31661d6

File tree

6 files changed

+2946
-12
lines changed

6 files changed

+2946
-12
lines changed

CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
66

77
## [Unreleased]
88

9+
### Changed
10+
- Changed `pybricksdev.compile.compile_multi_file()` to use `mpy-tool` to find imports
11+
instead of Python's `ModuleFinder`.
12+
13+
### Fixed
14+
- Fixed compiling multi-file projects with implicit namespace packages.
15+
916
## [2.3.0] - 2025-10-31
1017

1118
### Added

0 commit comments

Comments
 (0)