editable installs ignore exceptions as of v64.0.2 #3972
-
I have a custom subcommand that I'm using to generate pkg data. I'm also using an env var to instigate a "dirty" build. But this is where I need to raise an exception during an editable install: If the dirty option is asserted and the would-be generated pkg data does not exist, then I would like to prevent the build from completing properly. As a workaround, I'm pinning to Is there a more conventional approach that I'm missing? I noticed the src names Aug 2023 as the date of repealing the setuptools/setuptools/command/editable_wheel.py Lines 287 to 322 in cd9c6a4 But the comment below in _safely_run() seems to contradict the Aug 2023 date:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
Hi @2bndy5 please note that "suggested due date" is not the same thing as a final, definite, due date exposed to the final users... so I don't see any contradiction here.
Not that I am aware, but please don't rely on the fact that a specific kind of exception is raised. It is not part of the public API that setuptools will let exceptions to pass through without attempting to use exception handlers... If you need to handle an exception maybe the best option is to do it directly whenever/wherever it occurs instead of waiting for it to propagate through the call stack... |
Beta Was this translation helpful? Give feedback.
Hi @2bndy5, I don't think I will be able to help towards understanding why this expectation is not met without a better look on the source code. If you can provide a minimal reproducer maybe we can have a better look and discuss different options.
The rationale here is …