Skip to content
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

Add a name to the EventManagerPlugin #571

Merged
merged 2 commits into from
Jun 5, 2024

Conversation

mdickinson
Copy link
Member

This tiny PR adds a name to the EventManagerPlugin, to prevent a WARNING being logged on computing the repr of the plugin.

On main:

Python 3.11.9 (main, Apr  4 2024, 05:29:26) [Clang 15.0.0 (clang-1500.1.0.2.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import logging
>>> logging.basicConfig()
>>> from envisage.plugins.event_manager.api import EventManagerPlugin
>>> plugin = EventManagerPlugin()
>>> plugin
WARNING:envisage.plugin:plugin <envisage.plugins.event_manager.plugin.EventManagerPlugin object at 0x100d8a160> has no name - using <Event Manager Plugin>
EventManagerPlugin(id='envisage.event_manager', name='Event Manager Plugin')

On this branch:

Python 3.11.9 (main, Apr  4 2024, 05:29:26) [Clang 15.0.0 (clang-1500.1.0.2.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import logging
>>> logging.basicConfig()
>>> from envisage.plugins.event_manager.api import EventManagerPlugin
>>> plugin = EventManagerPlugin()
>>> plugin
EventManagerPlugin(id='envisage.event_manager', name='Event Manager')

@mdickinson
Copy link
Member Author

@siddhantwahal Would you be willing to review? This warning was showing up unexpectedly during debugging in some project code that uses Envisage.

@mdickinson mdickinson merged commit d358e7d into main Jun 5, 2024
12 checks passed
@mdickinson mdickinson deleted the fix/add-name-to-event-manager-plugin branch June 5, 2024 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants