amalgd Posted January 31, 2023 Posted January 31, 2023 I need more details about the error from the following Django website: https://mainstay.heliohost.org/mainstayerp/admin The log says: TypeError: sequence of byte string values expected, value of type str found, referer: https://mainstay.heliohost.org/mainstayerp/login/?next=/mainstayerp/admin/ The login page load and then fails during POST request. username: amalgd main domain: mainstay.heliohost.org server: johnny Thank you!
wolstech Posted February 2, 2023 Posted February 2, 2023 Let's see if Krydos can get any additional info on this for you.
Krydos Posted February 2, 2023 Posted February 2, 2023 LMGTFY https://stackoverflow.com/a/34839029/2336864 It looks like Python was expecting a sequence of byte string values, but you gave it a str instead.
amalgd Posted February 2, 2023 Author Posted February 2, 2023 Thank you for your time. I appreciate it.
amalgd Posted February 2, 2023 Author Posted February 2, 2023 Solved it by adding, "<meta charset="utf-8">" in the html templates. It is embarrassing to say this, but thanks for pointing to Google. Now I see another problem: NotSupportedError deterministic=True requires SQLite 3.8.3 or higher Would there be a quick fix for this?
Krydos Posted February 3, 2023 Posted February 3, 2023 The best fix is to switch to MySQL or PostgreSQL. Not only do they provide much better performance, you don't have to worry about file and directory permissions and disk io. If you insist on using SQLite for some reason you'll have to deal with version 3.7.17 because it can't be upgraded to anything newer. Another option if you refuse to use MySQL or PostgreSQL and need a newer version of SQLite is you could switch to a VPS plan where you could install any version you want, but that starts at $4 per month.
amalgd Posted February 3, 2023 Author Posted February 3, 2023 Thank you Krydos! Will try setting up to use PostgreSQL for now. Planning to purchase a VPS soon.
Recommended Posts