-
Notifications
You must be signed in to change notification settings - Fork 192
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ORM: fix deprecation warning always being shown in link managers (#5011)
The link managers for the `Node` class which are used for the `inputs` and `outputs` attributes and facilitate the tab-completion of incoming and outgoing links, was recently changed to deprecate the direct use of double underscores in link labels in favor of treating them as normal nested dictionaries. The deprecation warning was thrown whenever the label contained a double underscore, but this would therefore also trigger on dunder methods, which is not desirable behaviour. This inaccuracy manifested itself in the deprecation method being printed even when just activating the tab-completion on `node.outputs` or `node.inputs` without even specifying a label with a double underscore. It is not fully understood how `_get_node_by_link_label` is called in doing this, but it seems some caching mechanism is calling the `__wrapped__` attribute on the link manager, which in turn triggers the deprecation warning. An additional clause in the condition to exclude dunder methods fixes the behaviour. Cherry-pick: 53c5564
- Loading branch information
Showing
2 changed files
with
38 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters