hatch-vcs icon indicating copy to clipboard operation
hatch-vcs copied to clipboard

Cannot set setuptools_scm root to "../.."

Open mangelajo opened this issue 5 months ago • 1 comments

I have a project with multiple sub-directories for packages. With setuptools_scm you can do root="../.." but with hatch-vcs I suspect that is fixed to the root of the project. https://github.com/ofek/hatch-vcs/blob/master/hatch_vcs/version_source.py#L54

I end up with:

LookupError: Error getting the version from source vcs: setuptools-scm was unable to detect version for /home/majopela/jumpstarter/contrib/can.

while building wheels, and I'd need to pass down the relative path to setuptools_scm

I guess I may need to add an option to hatch-vcs version plugin, i.e.

[tool.hatch.version]
source = "vcs"
root = "../.."

?

would that make sense?

mangelajo avatar Sep 25 '24 14:09 mangelajo