-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add packaging tests, support blocks defined in __main__ (#252)
Add local packaging run to workflow tests, with an abbreviated (blinky-only) unittest and top-level test. Resolves #251, where blocks defined in `__main__` cause an error when the HDL server tries to resolve those blocks, because the HDL server is a separate Python instance and thinks itself is `__main__` (instead of the original file). The fix is to detect when a library's module is `__main__` and effectively guess the correct original module name by using the filename. Might be a better way to do it, but this works, and is largely what a websearch turned out for finding the original module name for `__main__`. Bumps the package version since this is a significant bugfix.
- Loading branch information
Showing
6 changed files
with
57 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,4 +28,3 @@ def edg_to_dict(obj: Union[BasePort, BaseBlock]) -> Dict[str, Any]: | |
} | ||
else: | ||
raise ValueError | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" | |
|
||
[project] | ||
name = "edg" | ||
version = "0.0.0" | ||
version = "0.0.1" | ||
description = "Hardware description language for circuit boards" | ||
readme = "README.md" | ||
authors = [{ name = "Ducky", email = "[email protected]" }] | ||
|