-
-
Notifications
You must be signed in to change notification settings - Fork 429
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding a plugin in editable mode fails #3407
Comments
After some digging, it seems the issue occurs at line 273 in pdm.models.requirements. I'm unsure as to the correct fix, or even if i'm just doing something wrong! If the latter then pdm developer docs need updating or clarifying. |
Oh, this is worse than i thought. The same issue occurs for dev-dependencies, it just doesn't result in an exception:
|
Workaround is |
This conclusion is not quite correct. For path dependency, the name of the dependency should be set in L316-317 and the |
I did check. Here;s the debug prints below. Branch with debugging in here: https://github.com/robtaylor/pdm/tree/debug-3407
|
Actually, self.path isn't set at entry to _parse_url, so lines 316-317 are not executed for this case. It appears that for "file:///${PROJECT_ROOT}/../pdm-autoexport", _file_req_re.groupdict() returns i.e. it seems the first subpattern ( |
So the fix should be to make L316-317 run after the else-branch, right? |
I don't think so, as we can only call Setup.from_directory after we have a path. |
ah, this solution breaks one of the requirement tests. WIll dig in further. |
Describe the bug
gives:
To reproduce
See above!
Expected Behavior
No excepetion and plugin is installed.
Environment Information
% pdm info
PDM version:
2.22.3
Python Interpreter:
/Users/roberttaylor/Code/ChipFlow/Backend/test/.venv/bin/python (3.11)
Project Root:
/Users/roberttaylor/Code/ChipFlow/Backend/test
Local Packages:
% pdm info --env
{
"implementation_name": "cpython",
"implementation_version": "3.13.2",
"os_name": "posix",
"platform_machine": "arm64",
"platform_release": "24.3.0",
"platform_system": "Darwin",
"platform_version": "Darwin Kernel Version 24.3.0: Thu Jan 2 20:24:22 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T6041",
"python_full_version": "3.11.0",
"platform_python_implementation": "CPython",
"python_version": "3.11",
"sys_platform": "darwin"
}
Verbose Command Output
No response
Additional Context
No response
Are you willing to submit a PR to fix this bug?
The text was updated successfully, but these errors were encountered: