File List Sort By Defaults

I've searched for an setting, and/or a plugin, that controls the file list default sort order when loading up the OctoPrint web page. But I've came up empty.

I've done some cool CSS modifications with Themify , but don't see a way to trigger events, such as those that trigger the sort by options from the file list settings popup menu, from within Themify.

Is there some way to change the default sort by options, or have them remembered between browser sessions, or automatically trigger the built in events to do so?

Instead of the current defaults, I prefer to have the file list sorted by: "Sort by "upload date (descending)"

and the "Folders" option set to: "Sort by Files, Folders"

Unfortunately I haven't found any way to do this other than having to manually set both options every time I start up a new browser session. Am I missing a simple (or even a not so simple) way to permanently set the sort by defaults?

Have you tried the wrench at the top of the file list?

Thank you for your reply, and yes, I know all too well about the wrench.

That's how I manually set the sort order every time I start a new session. What I'd like is a way to set it and have it remembered between sessions.

Unfortunately that isn't how it works, at least it hasn't been the case on any of my OctoPrint installs I've used over the last several years of using OctoPrint.

I see. Does OctoPrint save the settings in the tabs? And does OctoPrint save setting for files in safemode?

I'm not sure what settings in the tabs you might be referring to, or what tab setting would need to be set. Safe mode has no affect on the issue I'm inquiring about.

OctoPrint always starts a new browser session, with my logon, with the file list sorted with the Folders on top of the list ("Folders, Files") regardless.

I always change it to "Files, Folders" to get the folders to be at the bottom of the list because I prefer to have the newest files at the top, descending to the oldest, and then the folders below all the files.

Unfortunately OctoPrint doesn't seem to want to remember my preference. I came here to ask if anyone knows of a way to set it to do so.

OctoPrint does remember this by default, but it remembers it in the browser. It persists the info into local storage (think cookies, but not really). It should always use the last set order in the same browser, but if you keep nuking the browser settings it can't.


It's good to know that is the way it should work, so I know mine should be able to be fixed.

I have two OctoPrint installations running on Ubuntu 19.x on HP Intel i5 based mini desktops. I've been running this setup for years, and recently upgraded to 1.4.0 but my sorting issue has been like this forever. I was just hoping it would change with the 1.4 update.

I regularly use three different Windows based computers using both the latest Firefox and Chrome browsers, plus Firefox on an iPad to access both OctoPrint setups.

I don't intentionally nuke anything regarding OctoPriint in any of my browsers, on any of my computers/tablets, and they all act the same. The sort by "Upload date descending" seems to stick, but the folder sort, "Files, folders" always reverts back to folders first wherever I start a new browser session on any of the browser/computer combinations.

This option isn't getting saved for some reason on any of my setups. I'll have to dig deeper now that I know from you what it is supposed to do, and apparently does for everyone else.

See, that's why it's always a good idea to open bug reports for issues right away instead of letting them sit for years. If you'd opened a ticket with the information you just gave me I'd immediately have told you that this is in fact an oversight and a bug in OctoPrint, fixed it and you'd already be rocking a fixed version for a long long time.

Instead you'll now have to wait until 1.4.1.

The thing is, the sorting itself does get saved, but this specific thing is implemented slightly differently and so far didn't get saved. Not a problem, I'll change that.

edit There you go:


Yes, I know, I know. You're absolutely right and I should have taken the time to open a bug report.

I guess I've really never found much of anything wrong with OctoPrint and just kept happily using it every day. Then after the 1.4 upgrade and making some more Themify changes to the UI, this just kind of struck me as something I'd like to change as well, but couldn't find how.

Thanks for your reply, thanks for fixing this, and most of all thanks for OctoPrint.

1 Like