Add a workaround for setuptools erroring out on stale git checkouts.

This commit is contained in:
Catherine 2023-03-22 00:41:15 +00:00
parent 5f094a23eb
commit 46e0a00a08

View file

@ -26,5 +26,12 @@ remote-build = ["paramiko~=2.7"]
[project.scripts]
amaranth-rpc = "amaranth.rpc:main"
[tool.setuptools]
# If amaranth 0.3 is checked out with git (e.g. as a part of a persistent editable install or
# a git worktree cached by tools like poetry), it can have an empty `nmigen` directory left over,
# which causes a hard error because setuptools cannot determine the top-level package.
# Add a workaround to improve experience for people upgrading from old checkouts.
packages = ["amaranth"]
[tool.setuptools_scm]
local_scheme = "node-and-timestamp"