What is the problem?
The developed Plugin (named Cmfgdataacquisition
) has compatible issues with OctoPrint environment. The Plugin was developed on Python 3.7.9. In the code, I also added __plugin_pythoncompat__ = ">=3,<4"
to tell OctoPrint about Python 3 environment. But in the log, there was a warning as follows:
WARNING - Plugin Cmfgdataacquisition Plugin (0.1.0) is not compatible to Python 2.7.16 (compatibility string: >=3,<4).
So, if I upgrade OctoPrint's environment to Python 3, the problem will be solved? And, how do I update OctoPrint's environment to Python 3?
PS: I also installed a Plugin named helloworld_test
. But I have already removed it via Plugin Manager. But I have no idea about why there is an error related to the helloworld_test
Plugin.
What did you already try to solve it?
I built a virtual environment based on Python 3 (only Python 3 is installed).
Have you tried running in safe mode?
No
Complete Logs
2021-02-04 21:50:31,207 - octoprint.startup - INFO - ******************************************************************************
2021-02-04 21:50:31,209 - octoprint.startup - INFO - Starting OctoPrint 1.5.3
2021-02-04 21:50:31,209 - octoprint.startup - INFO - ******************************************************************************
2021-02-04 21:50:31,495 - octoprint.util.connectivity.connectivity_checker - INFO - Connectivity state is currently: online
2021-02-04 21:50:31,496 - octoprint.util.connectivity.connectivity_checker - INFO - Connecting to 8.8.8.8:53 is working
2021-02-04 21:50:31,497 - octoprint.util.connectivity.connectivity_checker - INFO - Resolving octoprint.org is working
2021-02-04 21:50:31,517 - octoprint.plugin.core - INFO - Loading plugins from /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins, /home/pi/.octoprint/plugins and installed plugin packages...
2021-02-04 21:50:32,159 - octoprint.plugin.core - ERROR - Error loading plugin helloworld_test
Traceback (most recent call last):
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/plugin/core.py", line 1298, in _import_plugin
module = _load_module(module_name, spec)
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/plugin/core.py", line 69, in _load_module
return imp.load_module(name, f, filename, details)
File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint_helloworld_test/__init__.py", line 13, in <module>
import influxdb_client
ImportError: No module named influxdb_client
2021-02-04 21:50:32,232 - octoprint.plugin.core - WARNING - Plugin Cmfgdataacquisition Plugin (0.1.0) is not compatible to Python 2.7.16 (compatibility string: >=3,<4).
2021-02-04 21:50:32,274 - octoprint.plugin.core - INFO - Found 19 plugin(s) providing 18 mixin implementations, 35 hook handlers
2021-02-04 21:50:32,378 - octoprint.server.heartbeat - INFO - Starting server heartbeat, 900.0s interval
2021-02-04 21:50:32,392 - octoprint.server - INFO - Intermediary server started
2021-02-04 21:50:32,409 - octoprint.filemanager.storage - INFO - Initializing the file metadata for /home/pi/.octoprint/uploads...
2021-02-04 21:50:32,624 - octoprint.filemanager.storage - INFO - ... file metadata for /home/pi/.octoprint/uploads initialized successfully.
2021-02-04 21:50:32,627 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_SHOW (needs: u"Need(method='role', value=u'plugin_action_command_notification_show')")
2021-02-04 21:50:32,627 - octoprint.server - INFO - Added new permission from plugin action_command_notification: PLUGIN_ACTION_COMMAND_NOTIFICATION_CLEAR (needs: u"Need(method='role', value=u'plugin_action_command_notification_clear')")
2021-02-04 21:50:32,628 - octoprint.server - INFO - Added new permission from plugin action_command_prompt: PLUGIN_ACTION_COMMAND_PROMPT_INTERACT (needs: u"Need(method='role', value=u'plugin_action_command_prompt_interact')")
2021-02-04 21:50:32,629 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_READ (needs: u"Need(method='role', value=u'plugin_announcements_read')")
2021-02-04 21:50:32,630 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_MANAGE (needs: u"Need(method='role', value=u'plugin_announcements_manage'), Need(method='role', value=u'plugin_announcements_read')")
2021-02-04 21:50:32,631 - octoprint.server - INFO - Added new permission from plugin appkeys: PLUGIN_APPKEYS_ADMIN (needs: u"Need(method='role', value=u'plugin_appkeys_admin')")
2021-02-04 21:50:32,632 - octoprint.server - INFO - Added new permission from plugin backup: PLUGIN_BACKUP_ACCESS (needs: u"Need(method='role', value=u'plugin_backup_access')")
2021-02-04 21:50:32,633 - octoprint.server - INFO - Added new permission from plugin firmware_check: PLUGIN_FIRMWARE_CHECK_DISPLAY (needs: u"Need(method='role', value=u'plugin_firmware_check_display')")
2021-02-04 21:50:32,634 - octoprint.server - INFO - Added new permission from plugin logging: PLUGIN_LOGGING_MANAGE (needs: u"Need(method='role', value=u'plugin_logging_manage')")
2021-02-04 21:50:32,635 - octoprint.server - INFO - Added new permission from plugin pi_support: PLUGIN_PI_SUPPORT_STATUS (needs: u"Need(method='role', value=u'plugin_pi_support_check')")
2021-02-04 21:50:32,636 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_MANAGE (needs: u"Need(method='role', value=u'plugin_pluginmanager_manage')")
2021-02-04 21:50:32,637 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_INSTALL (needs: u"Need(method='role', value=u'plugin_pluginmanager_install'), Need(method='role', value=u'plugin_pluginmanager_manage')")
2021-02-04 21:50:32,638 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CHECK (needs: u"Need(method='role', value=u'plugin_softwareupdate_check')")
2021-02-04 21:50:32,638 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_UPDATE (needs: u"Need(method='role', value=u'plugin_softwareupdate_update')")
2021-02-04 21:50:32,639 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CONFIGURE (needs: u"Need(method='role', value=u'plugin_softwareupdate_configure')")
2021-02-04 21:50:32,748 - octoprint.plugins.softwareupdate - INFO - Loaded version cache from disk
2021-02-04 21:50:33,338 - octoprint.util.pip - INFO - Using "/home/pi/oprint/bin/python2 -m pip" as command to invoke pip
2021-02-04 21:50:33,898 - octoprint.util.pip - INFO - Version of pip is 19.3.1
2021-02-04 21:50:33,899 - octoprint.util.pip - INFO - pip installs to /home/pi/oprint/lib/python2.7/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes
2021-02-04 21:50:33,900 - octoprint.util.pip - INFO - ==> pip ok -> yes
2021-02-04 21:50:33,912 - octoprint.plugin.core - INFO - Initialized 18 plugin implementation(s)
2021-02-04 21:50:33,924 - octoprint.plugin.core - INFO - 19 plugin(s) registered with the system:
| Action Command Notification Support (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/action_command_notification
| Action Command Prompt Support (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/action_command_prompt
| Announcement Plugin (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/announcements
| Anonymous Usage Tracking (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/tracking
| Application Keys Plugin (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/appkeys
| Backup & Restore (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/backup
| *Cmfgdataacquisition Plugin (0.1.0) = /home/pi/oprint/local/lib/python2.7/site-packages/octoprint_CMfgDataAcquisition
| Core Wizard (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/corewizard
| Discovery (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/discovery
| Error Tracking (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/errortracking
| File Check (2020.8.7) (bundled) = /home/pi/oprint/local/lib/python2.7/site-packages/octoprint_file_check
| Firmware Check (2020.9.23) (bundled) = /home/pi/oprint/local/lib/python2.7/site-packages/octoprint_firmware_check
| GCode Viewer (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/gcodeviewer
| Logging (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/logging
| Pi Support Plugin (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/pi_support
| Plugin Manager (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/pluginmanager
| Python 3 Check (0.1.5) = /home/pi/oprint/local/lib/python2.7/site-packages/octoprint_python3plugincompatibilitycheck
| Software Update (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/softwareupdate
| Virtual Printer (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/virtual_printer
Prefix legend: ! = disabled, # = blacklisted, * = incompatible
2021-02-04 21:50:33,951 - octoprint.environment - INFO - Detected environment is Python 2.7.16 under Linux (linux2). Details:
| hardware:
| cores: 4
| freq: 1500.0
| ram: 4041732096
| os:
| bits: 32
| id: linux
| platform: linux2
| plugins:
| pi_support:
| model: Raspberry Pi 4 Model B Rev 1.2
| octopi_version: 0.17.0
| throttle_state: '0x0'
| python:
| pip: 19.3.1
| version: 2.7.16
| virtualenv: /home/pi/oprint
2021-02-04 21:50:33,961 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/webassets...
2021-02-04 21:50:33,979 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/.webassets-cache...
2021-02-04 21:50:34,518 - octoprint.server - INFO - Shutting down intermediary server...
2021-02-04 21:50:34,873 - octoprint.server - INFO - Intermediary server shut down
2021-02-04 21:50:34,875 - octoprint.events - INFO - Processing startup event, this is our first event
2021-02-04 21:50:34,875 - octoprint.events - INFO - Adding 1 events to queue that were held back before startup event
2021-02-04 21:50:34,878 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue...
2021-02-04 21:50:34,879 - octoprint.server - INFO - Autoconnect on startup is configured, trying to connect to the printer...
2021-02-04 21:50:34,886 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue
2021-02-04 21:50:34,923 - octoprint.server - INFO - Trying to connect to configured serial port /dev/ttyUSB0
2021-02-04 21:50:34,953 - octoprint.server.util.watchdog - INFO - Running initial scan on watched folder...
2021-02-04 21:50:34,955 - octoprint.util.comm - INFO - Changing monitoring state from "Offline" to "Opening serial connection"
2021-02-04 21:50:34,956 - octoprint.server.util.watchdog - INFO - ... initial scan done.
2021-02-04 21:50:34,959 - octoprint.util.comm - INFO - Connecting to port /dev/ttyUSB0, baudrate 250000
2021-02-04 21:50:34,987 - octoprint.util.comm - INFO - Changing monitoring state from "Opening serial connection" to "Connecting"
2021-02-04 21:50:34,992 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2021-02-04 21:50:35,772 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on octopi._http._tcp.local.' for _http._tcp.local.
2021-02-04 21:50:35,909 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2021-02-04 21:50:35,992 - octoprint.plugins.tracking - INFO - Sent tracking event system_unthrottled, payload: {u'throttled_mask': 0, u'throttled_voltage_now': False, u'throttled_voltage_past': False, u'throttled_overheat_now': False, u'throttled_now': False, u'throttled_past': False, u'throttled_overheat_past': False}
2021-02-04 21:50:36,582 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on octopi._octoprint._tcp.local.' for _octoprint._tcp.local.
2021-02-04 21:50:36,591 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on octopi for SSDP
2021-02-04 21:50:36,642 - octoprint.server - INFO - Listening on http://127.0.0.1:5000
2021-02-04 21:50:36,769 - octoprint.server.util.sockjs - INFO - New connection from client: ::ffff:192.168.43.193
2021-02-04 21:50:36,803 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2021-02-04 21:50:37,500 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2021-02-04 21:50:37,499 - octoprint.util.pip - INFO - Using "/home/pi/oprint/bin/python2 -m pip" as command to invoke pip
2021-02-04 21:50:37,524 - octoprint.util.pip - INFO - pip installs to /home/pi/oprint/lib/python2.7/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes
2021-02-04 21:50:37,528 - octoprint.util.pip - INFO - ==> pip ok -> yes
2021-02-04 21:50:37,542 - octoprint.server.util.flask - INFO - Passively logging in user zhaojun from ::ffff:192.168.43.193
2021-02-04 21:50:37,543 - octoprint.util.comm - INFO - Changing monitoring state from "Connecting" to "Operational"
2021-02-04 21:50:37,566 - octoprint.plugins.softwareupdate - INFO - Minimum free storage across all update relevant locations is 234.1GB. That is considered sufficient for updating.
2021-02-04 21:50:37,570 - octoprint.plugins.softwareupdate - INFO - Fetching check overlays from https://plugins.octoprint.org/update_check_overlay.json
2021-02-04 21:50:37,647 - octoprint.server.util.sockjs - INFO - User zhaojun logged in on the socket from client ::ffff:192.168.43.193
2021-02-04 21:50:37,719 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2021-02-04 21:50:37,999 - octoprint.util.comm - INFO - Printer reports firmware name "Marlin V1; Sprinter/grbl mashup for gen6"
2021-02-04 21:50:38,116 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2021-02-04 21:50:38,832 - octoprint.server.preemptive_cache - INFO - Preemptively caching / (ui _default) for {'query_string': 'l10n=en', 'path': '/', 'base_url': 'http://octopi.local/'}
2021-02-04 21:50:39,031 - octoprint.plugins.tracking - INFO - Sent tracking event printer_connected, payload: {u'printer_baudrate': 250000, u'printer_port': '/dev/ttyUSB0', u'firmware_name': u'Marlin V1; Sprinter/grbl mashup for gen6'}
2021-02-04 21:50:40,116 - octoprint.plugins.tracking - INFO - Sent tracking event ping, payload: {'octoprint_uptime': 6}
2021-02-04 21:50:41,853 - octoprint.plugins.tracking - INFO - Sent tracking event startup, payload: {u'python': '2.7.16', u'os': u'linux', u'ram': 4041732096L, u'octopi_version': u'0.17.0', u'version': u'1.5.3', u'pip': '19.3.1', u'cores': 4, u'freq': 1500.0, u'pi_model': u'Raspberry Pi 4 Model B Rev 1.2', u'bits': 32}
2021-02-04 21:50:42,567 - octoprint.server.util.flask - INFO - Passively logging in user zhaojun from ::ffff:192.168.43.193
2021-02-04 21:50:42,961 - octoprint.plugins.tracking - INFO - Sent tracking event pong, payload: {u'python': '2.7.16', u'os': u'linux', u'ram': 4041732096L, u'octopi_version': u'0.17.0', u'version': u'1.5.3', u'plugins': u'python3plugincompatibilitycheck:0.1.5', u'pip': '19.3.1', u'cores': 4, u'freq': 1500.0, u'pi_model': u'Raspberry Pi 4 Model B Rev 1.2', u'bits': 32}
2021-02-04 21:51:05,315 - octoprint.server.preemptive_cache - INFO - ... done in 26.48s
2021-02-04 21:51:05,349 - octoprint.server.util.sockjs - INFO - Client connection closed: ::ffff:192.168.43.193
2021-02-04 21:51:05,937 - octoprint.server.util.sockjs - INFO - New connection from client: ::ffff:192.168.43.193
2021-02-04 21:51:06,005 - octoprint.server.util.flask - INFO - Passively logging in user zhaojun from ::ffff:192.168.43.193
2021-02-04 21:51:07,526 - octoprint.server.util.sockjs - INFO - User zhaojun logged in on the socket from client ::ffff:192.168.43.193
Additional information about your setup
| hardware:
| cores: 4
| freq: 1500.0
| ram: 4041732096
| os:
| bits: 32
| id: linux
| platform: linux2
| plugins:
| pi_support:
| model: Raspberry Pi 4 Model B Rev 1.2
| octopi_version: 0.17.0
| throttle_state: '0x0'
| python:
| pip: 19.3.1
| version: 2.7.16
| virtualenv: /home/pi/oprint
Cheers