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

[1.4.0rc5] self._printer injected into plugins is broken under py3 and can't be used #3455

foosel opened this issue Feb 18, 2020 · 2 comments


Copy link

@foosel foosel commented Feb 18, 2020


2020-02-18 16:04:04,936 - octoprint.plugin - ERROR - Error while calling plugin test_self_printer
Traceback (most recent call last):
  File "C:\Devel\OctoPrint\OctoPrint\src\octoprint\plugin\", line 224, in call_plugin
    result = getattr(plugin, method)(*args, **kwargs)
  File "C:\Devel\OctoPrint\OctoPrint\src\octoprint\plugins\", line 8, in on_event"Connected to printer: {}".format(self._printer))
  File "C:\Devel\OctoPrint\devenv3\lib\site-packages\wrapt\", line 118, in __str__
    return str(self.__wrapped__)
  File "C:\Devel\OctoPrint\devenv3\lib\site-packages\wrapt\", line 194, in __getattr__
    raise ValueError('wrapper has not been initialised')
ValueError: wrapper has not been initialised

Test plugin:

import octoprint.plugin

from import Events

class TestSelfPrinterPlugin(octoprint.plugin.EventHandlerPlugin):
	def on_event(self, event, payload):
		if event == Events.CONNECTED:"Connected to printer: {}".format(self._printer))

__plugin_implementation__ = TestSelfPrinterPlugin()


Already fixed in b42c753


This comment has been minimized.

Copy link

@GitIssueBot GitIssueBot commented Feb 26, 2020

This issue has been mentioned on OctoPrint Community Forum. There might be relevant details there:


This comment has been minimized.

Copy link
Member Author

@foosel foosel commented Feb 26, 2020

1.4.0rc6 is out

@foosel foosel closed this Feb 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
2 participants
You can’t perform that action at this time.