Repository navigation
Add NotFilter for filter chains - #329
Sinkleberg wants to merge 2 commits into
Conversation
|
Thanks but I would prefer a solution where there is a NotFilter() which can be wrapped around a filter chain, so that inversion can be applied to any filter. |
|
Thanks for the suggestion. I switched this to |
lonvia
left a comment
There was a problem hiding this comment.
Why all this custom constructor handling? Why doesn't pybind11 take care of that in this case?
|
Construction still uses |
|
Ah, you don't need to keep the input argument. Not to speak of the fact that doing something like this would anyway create an endless loop where a dangling referece is the least of your worries. |
|
Agreed, the chain is fixed at construction. My concern is the temporary in |
|
Well, then that rather points to a potential bug in HandlerChain. That obviously shouldn't be silently worked around in a new filter implementation but be addressed. We are at the end of AI-driven coding here. I'll need to look into the code and see what's going on with HandlerChain. Until then this PR needs to be stalled. |
|
Uh, I just realised that you are repo hoping with mass AI-generated PRs. Those I don't take anyway. So closing. |
For #310.
NotFilter(*filters)keeps an object when the wrapped filter chain would drop it. It works with native filters and Python callbacks.I used Codex to help with this change. On Windows I rebuilt the filter module against the released native core. The suite passed 453 tests and skipped the optional Shapely example.