Tornado Error when trying to refresh upload directory

What is the problem?
Octoprint is not showing files list or space available. No uploaded files are displayed

What did you already try to solve it?
I downgraded to 1.3.12 to see if I still had the problem, and then reinstalled 1.4.0, also tried booting in safe mode. I also gave my user every permission to see if that would help.

Logs (octoprint.log, serial.log or output on terminal tab at a minimum, browser error console if UI issue ... no logs, no support!)

2020-03-25 20:10:29,318 - octoprint.startup - INFO - ******************************************************************************
2020-03-25 20:10:29,320 - octoprint.startup - INFO - Starting OctoPrint 1.4.0
2020-03-25 20:10:29,321 - octoprint.startup - INFO - ******************************************************************************
2020-03-25 20:10:29,857 - octoprint.util.connectivity_checker - INFO - Connectivity changed from offline to online
2020-03-25 20:10:29,863 - octoprint.startup - INFO - Blacklist processing done, adding 1 blacklisted plugin versions: roomtemp (any)
2020-03-25 20:10:29,905 - 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...
2020-03-25 20:10:31,031 - octoprint.plugin.core - INFO - Found 16 plugin(s) providing 16 mixin implementations, 29 hook handlers
2020-03-25 20:10:31,146 - octoprint.server.heartbeat - INFO - Starting server heartbeat, 900.0s interval
2020-03-25 20:10:31,169 - octoprint.server - INFO - Intermediary server started
2020-03-25 20:10:31,170 - 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...
2020-03-25 20:10:31,285 - octoprint.plugin.core - INFO - Found 16 plugin(s) providing 16 mixin implementations, 29 hook handlers
2020-03-25 20:10:31,315 - octoprint.filemanager.storage - INFO - Initializing the file metadata for /home/pi/.octoprint/uploads...
2020-03-25 20:10:31,808 - octoprint.filemanager.storage - INFO - ... file metadata for /home/pi/.octoprint/uploads initialized successfully.
2020-03-25 20:10:31,816 - 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')")
2020-03-25 20:10:31,818 - octoprint.server - INFO - Added new permission from plugin announcements: PLUGIN_ANNOUNCEMENTS_READ (needs: u"Need(method='role', value=u'plugin_announcements_read')")
2020-03-25 20:10:31,822 - 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')")
2020-03-25 20:10:31,825 - octoprint.server - INFO - Added new permission from plugin appkeys: PLUGIN_APPKEYS_ADMIN (needs: u"Need(method='role', value=u'plugin_appkeys_admin')")
2020-03-25 20:10:31,828 - octoprint.server - INFO - Added new permission from plugin backup: PLUGIN_BACKUP_ACCESS (needs: u"Need(method='role', value=u'plugin_backup_access')")
2020-03-25 20:10:31,832 - octoprint.server - INFO - Added new permission from plugin logging: PLUGIN_LOGGING_MANAGE (needs: u"Need(method='role', value=u'plugin_logging_manage')")
2020-03-25 20:10:31,834 - 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')")
2020-03-25 20:10:31,836 - octoprint.server - INFO - Added new permission from plugin pluginmanager: PLUGIN_PLUGINMANAGER_MANAGE (needs: u"Need(method='role', value=u'plugin_pluginmanager_manage')")
2020-03-25 20:10:31,837 - 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')")
2020-03-25 20:10:31,839 - octoprint.server - INFO - Added new permission from plugin printer_safety_check: PLUGIN_PRINTER_SAFETY_CHECK_DISPLAY (needs: u"Need(method='role', value=u'plugin_printer_safety_check_display')")
2020-03-25 20:10:31,840 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_CHECK (needs: u"Need(method='role', value=u'plugin_softwareupdate_check')")
2020-03-25 20:10:31,841 - octoprint.server - INFO - Added new permission from plugin softwareupdate: PLUGIN_SOFTWAREUPDATE_UPDATE (needs: u"Need(method='role', value=u'plugin_softwareupdate_update')")
2020-03-25 20:10:31,935 - octoprint.plugins.softwareupdate - INFO - Loaded version cache from disk
2020-03-25 20:10:32,930 - octoprint.util.pip - INFO - Using "/home/pi/oprint/bin/python2 -m pip" as command to invoke pip
2020-03-25 20:10:33,913 - octoprint.util.pip - INFO - Version of pip is 19.3.1
2020-03-25 20:10:33,915 - octoprint.util.pip - INFO - pip installs to /home/pi/oprint/lib/python2.7/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes
2020-03-25 20:10:33,915 - octoprint.util.pip - INFO - ==> pip ok -> yes
2020-03-25 20:10:33,921 - octoprint.plugin.core - INFO - Initialized 16 plugin implementation(s)
2020-03-25 20:10:33,933 - octoprint.plugin.core - INFO - 16 plugin(s) registered with the system:
|  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
|  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
|  Logging (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/logging
|  Login UI (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/loginui
|  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
|  Printer Safety Check (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/printer_safety_check
|  Software Update (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/softwareupdate
|  TouchUI (0.3.14) = /home/pi/oprint/local/lib/python2.7/site-packages/octoprint_touchui
|  Virtual Printer (bundled) = /home/pi/oprint/lib/python2.7/site-packages/octoprint/plugins/virtual_printer
Prefix legend: ! = disabled, # = blacklisted, * = incompatible
2020-03-25 20:10:33,937 - octoprint.environment - ERROR - Error while detecting hardware environment
Traceback (most recent call last):
  File "/home/pi/oprint/local/lib/python2.7/site-packages/octoprint/environment.py", line 104, in _detect_hardware
    cores = psutil.cpu_count()
AttributeError: 'module' object has no attribute 'cpu_count'
2020-03-25 20:10:33,948 - octoprint.environment - INFO - Detected environment is Python 2.7.16 under Linux (linux2). Details:
|  hardware:
|      cores: unknown
|      freq: unknown
|      ram: unknown
|  os:
|      id: linux
|      platform: linux2
|  plugins:
|      pi_support:
|          model: Raspberry Pi 3 Model B Plus Rev 1.3
|          octopi_version: 0.17.0
|  python:
|      pip: 19.3.1
|      version: 2.7.16
|      virtualenv: /home/pi/oprint
2020-03-25 20:10:33,960 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/webassets...
2020-03-25 20:10:33,979 - octoprint.server - INFO - Reset webasset folder /home/pi/.octoprint/generated/.webassets-cache...
2020-03-25 20:10:34,797 - octoprint.server - INFO - Shutting down intermediary server...
2020-03-25 20:10:34,848 - octoprint.server - INFO - Intermediary server shut down
2020-03-25 20:10:34,852 - octoprint.events - INFO - Processing startup event, this is our first event
2020-03-25 20:10:34,853 - octoprint.events - INFO - Adding 1 events to queue that were held back before startup event
2020-03-25 20:10:34,856 - octoprint.filemanager - INFO - Adding backlog items from all storage types to analysis queue...
2020-03-25 20:10:34,857 - octoprint.server - INFO - Autoconnect on startup is configured, trying to connect to the printer...
2020-03-25 20:10:34,863 - octoprint.filemanager - INFO - Added 0 items from storage type "local" to analysis queue
2020-03-25 20:10:34,899 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2020-03-25 20:10:36,051 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2020-03-25 20:10:36,228 - octoprint.server - INFO - Trying to connect to configured serial port None
2020-03-25 20:10:36,282 - octoprint.util.comm - INFO - Changing monitoring state from "Offline" to "Detecting serial port"
2020-03-25 20:10:36,289 - octoprint.server.util.watchdog - INFO - Running initial scan on watched folder...
2020-03-25 20:10:36,290 - octoprint.server.util.watchdog - INFO - ... initial scan done.
2020-03-25 20:10:36,313 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on octopi' for _http._tcp
2020-03-25 20:10:36,323 - octoprint.util.comm - INFO - Changing monitoring state from "Detecting serial port" to "Opening serial port"
2020-03-25 20:10:36,328 - octoprint.util.comm - INFO - Changing monitoring state from "Opening serial port" to "Detecting baudrate"
2020-03-25 20:10:36,329 - octoprint.plugins.discovery - INFO - Registered 'OctoPrint instance on octopi' for _octoprint._tcp
2020-03-25 20:10:36,339 - octoprint.plugins.discovery - INFO - Registered OctoPrint instance on octopi for SSDP
2020-03-25 20:10:36,365 - octoprint.server - INFO - Listening on http://127.0.0.1:5000
2020-03-25 20:10:36,475 - octoprint.plugins.pluginmanager - INFO - Loaded plugin repository data from disk, was still valid
2020-03-25 20:10:36,612 - octoprint.server.util.sockjs - INFO - New connection from client: ::ffff:192.168.0.237
2020-03-25 20:10:36,815 - octoprint.server.util.sockjs - INFO - New connection from client: ::1
2020-03-25 20:10:37,168 - octoprint.server.util.flask - INFO - Passively logging in user <REDACTED> from <REDACTED>
2020-03-25 20:10:37,181 - octoprint.access.users - INFO - Logged in user: <REDACTED>
2020-03-25 20:10:37,248 - octoprint.server.util.flask - INFO - Passively logging in user <REDACTED> from ::1
2020-03-25 20:10:37,261 - octoprint.access.users - INFO - Logged in user: <REDACTED>
2020-03-25 20:10:37,389 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2020-03-25 20:10:37,837 - octoprint.util.comm - INFO - Changing monitoring state from "Detecting baudrate" to "Operational"
2020-03-25 20:10:37,842 - octoprint.util.pip - INFO - Using "/home/pi/oprint/bin/python2 -m pip" as command to invoke pip
2020-03-25 20:10:37,851 - octoprint.util.pip - INFO - pip installs to /home/pi/oprint/lib/python2.7/site-packages (writable -> yes), --user flag needed -> no, virtual env -> yes
2020-03-25 20:10:37,853 - octoprint.util.pip - INFO - ==> pip ok -> yes
2020-03-25 20:10:37,864 - octoprint.util.comm - INFO - M110 detected, setting current line number to 0
2020-03-25 20:10:38,384 - octoprint.plugins.pluginmanager - INFO - Loaded notice data from disk, was still valid
2020-03-25 20:10:38,574 - tornado.access - ERROR - 500 GET /api/files?recursive=true (::ffff:192.168.0.237) 22.60ms
2020-03-25 20:10:38,808 - tornado.access - ERROR - 500 GET /api/files?recursive=true (::1) 17.01ms
2020-03-25 20:10:40,602 - tornado.access - WARNING - 404 GET /static/webassets/packed_libs.css?ec88168c (<REDACTED>) 18.73ms
2020-03-25 20:10:40,610 - tornado.access - WARNING - 404 GET /static/webassets/packed_core.css?b577b523 (<REDACTED>) 3.26ms
2020-03-25 20:10:40,965 - tornado.access - WARNING - 404 GET /static/webassets/packed_libs.js?3339d949 (:<REDACTED>) 166.64ms
2020-03-25 20:10:41,056 - tornado.access - WARNING - 404 GET /static/webassets/packed_client.js?313d9a0c (<REDACTED>) 39.13ms
2020-03-25 20:10:41,064 - tornado.access - WARNING - 404 GET /static/webassets/packed_core.js?3514a079 (<REDACTED>) 4.19ms
2020-03-25 20:10:41,075 - tornado.access - WARNING - 404 GET /static/webassets/packed_plugins.js?554034b2 (<REDACTED>) 6.54ms
2020-03-25 20:10:41,135 - tornado.access - WARNING - 404 GET /static/webassets/packed_core.js?3514a079 (<REDACTED>) 6.26ms
2020-03-25 20:10:42,874 - tornado.access - ERROR - 500 GET /api/files?recursive=true (::1) 285.49ms
2020-03-25 20:10:58,485 - tornado.access - ERROR - 500 GET /api/files?recursive=true <REDACTED>) 23.64ms
2020-03-25 20:14:59,971 - tornado.access - ERROR - 500 GET /api/files?recursive=true&force=true (<REDACTED>) 56.28ms
2020-03-25 20:19:57,419 - tornado.access - ERROR - 500 GET /api/files?recursive=true (::1) 33.17ms
2020-03-25 20:23:36,522 - tornado.access - ERROR - 500 GET /api/files?recursive=true (<REDACTED>) 21.58ms
2020-03-25 20:28:01,153 - tornado.access - ERROR - 500 GET /api/files?recursive=true (<REDACTED>) 22.16ms
2020-03-25 20:33:11,458 - tornado.access - ERROR - 500 GET /api/files?recursive=true (<REDACTED>) 23.35ms
2020-03-25 20:37:47,176 - tornado.access - ERROR - 500 GET /api/files?recursive=true (<REDACTED>) 23.90ms
2020-03-25 20:38:42,446 - tornado.access - ERROR - 500 GET /api/files?recursive=true (<REDACTED>) 22.41ms
2020-03-25 20:54:41,702 - tornado.access - ERROR - 500 GET /api/files?recursive=true&force=true (<REDACTED>) 27.92ms
2020-03-25 20:54:42,789 - tornado.access - ERROR - 500 GET /api/files?recursive=true&force=true (<REDACTED>) 29.63ms

This error is printed every time I try to refresh the files list:
tornado.access - ERROR - 500 GET /api/files?recursive=true

Additional information about your setup (OctoPrint version, OctoPi version, printer, firmware, browser, operating system, ... as much data as possible)
Octoprint: 1.4.0
OctoPi: 0.17.0
Raspberry Pi 3B+
OS: Raspbian GNU/Linux 10 (buster)
Printer: Ender 3 Pro
Firmware: Marlin 1.1.9.1

Are you trying to connect to the virtual printer?

Im trying to connect my ocotpi to my ender 3 pro through a USB port. I'm not trying to connect to a virtual printer. Do the logs show that's what's happening?

I have attached a screenshot from my page using the touchUI plugin. It's displaying the printer status just fine, but the files are not displayed.

There is an error related to the virtual printer in the logs. It's why I asked.

Next time, you might indicate that this is TouchUI (which is probably the client which tornado is referring to).

1 Like

I've previously completed this step when I set my octopi up a few days ago (but did not connect it to my printer until today).

I have solved this issue. I noticed some other performance issues on my octopi, so after my nap today I decided to reinstall everything with a fresh Octopi 0.17.0 image.

Everything is working now! I've upgraded to 1.4.0 and can see the files. I guess something messed up in the original install or upgrade.

Thanks for your help while I worked through this issue!

1 Like