2.5.0 setup problem

Hi,
does everyone have the same setup problem of new release 2.5.0?

i installed TOTAL NEW plone 5.2.14 and new release senaite 2.5.0.
when i open http://localhost:8080 in browser and setup the site (Create a new SENAITE site).

input the username/password, always have the problem as in below:

2024-01-08 00:16:50,689 ERROR [waitress:358][waitress-2] Exception while serving /@@senaite-addsite
Traceback (most recent call last):
File “/home/senaite/buildout-cache/eggs/cp27mu/waitress-1.4.4-py2.7.egg/waitress/channel.py”, line 350, in service
task.service()
File “/home/senaite/buildout-cache/eggs/cp27mu/waitress-1.4.4-py2.7.egg/waitress/task.py”, line 171, in service
self.execute()
File “/home/senaite/buildout-cache/eggs/cp27mu/waitress-1.4.4-py2.7.egg/waitress/task.py”, line 441, in execute
app_iter = self.channel.server.application(environ, start_response)
File “/home/senaite/buildout-cache/eggs/cp27mu/Paste-3.5.2-py2.7.egg/paste/translogger.py”, line 69, in call
return self.application(environ, replacement_start_response)
File “/home/senaite/buildout-cache/eggs/cp27mu/Zope-4.8.10-py2.7.egg/ZPublisher/httpexceptions.py”, line 30, in call
return self.application(environ, start_response)
File “/home/senaite/buildout-cache/eggs/cp27mu/Zope-4.8.10-py2.7.egg/ZPublisher/WSGIPublisher.py”, line 404, in publish_module
start_response(status, headers)
File “/home/senaite/buildout-cache/eggs/cp27mu/Paste-3.5.2-py2.7.egg/paste/translogger.py”, line 67, in replacement_start_response
self.write_log(environ, method, req_uri, start, status, bytes)
File “/home/senaite/buildout-cache/eggs/cp27mu/Paste-3.5.2-py2.7.egg/paste/translogger.py”, line 99, in write_log
message = self.format % d
UnicodeDecodeError: ‘ascii’ codec can’t decode byte 0xe6 in position 4: ordinal not in range(128)

Hi @fengyun.deng,
does the same error appear for you for the Docker based image?
Thanks for reporting and best regards,
Ramon

Hi @ramonski,
Thanks very much for your help.
I haven’t tried 2.5.0 in Docker.
Because i’m planning it for a production system.

The 2.4.1 with Plone 5.2.11 run in Kubuntu 18.04 very well.
when i upgrade to 2.5.0, by run “./senaitelims/bin/buildout -n”. it said Plone 5.2.14 is needed.
so i
“rm -rf buildout-cache”
“rm -rf senaitelims”
to remove all old files, then install Plone 5.2.14 and Senaite 2.5.0 totally new by following,

Setp 1 install Plone 5.2.14

wget --no-check-certificate https://launchpad.net/plone/5.2/5.2.14/+download/Plone-5.2.14-UnifiedInstaller-1.0.tgz
tar -xf Plone-5.2.14-UnifiedInstaller-1.0.tgz
cd Plone-5.2.14-UnifiedInstaller-1.0
./install.sh standalone --target=/home/senaite --instance=senaitelims --password=mypassword --with-python=/home/senaite/miniconda2/bin/python

Setup 2
edit eggs and versions in “senaitelims/buildout.cfg”
edit “senaitelims/requirements.txt”

in buildout.cfg

eggs =
Plone
senaite.lims
simplejson

[versions]
zc.buildout =
setuptools =
Pillow = 5.1.0
cssselect2 = 0.2.2
soupsieve = 1.9.5
plone.recipe.unifiedinstaller = 5.2b1
buildout.sanitycheck = 1.0.2
collective.recipe.backup = 4.1.0

in requirements.txt

setuptools == 44.1.1
zc.buildout == 2.13.3
wheel

Step 3 install requirements and Senaite 2.5.0 by run

pip install -r requirements.txt
PYTHONHTTPSVERIFY=0 buildout

the problem is very werid.
i even tried different browsers (firefox and konqueror in localhost, Microsoft Edge from remote)
the problem is still there.

1 Like

Hi @ramonski ,
I confirmed the problem come from sign in “username” dialog.
as i temporarily commented the relative code in …//Paste-3.5.2-py2.7.egg/paste/translogger.py
I could successfully create a new SENAITE site.
then i recover all in Paste, I could login in and everything is works fine.

I circumvent this problem. it works for me. But sure it is not the proper way.

Hi @fengyun.deng,
Thanks for sharing your findings on this bug!

It seems like you encountered the same problem like we had about one year ago:

Probably the current month in your language contains as well unicode characters?

Anyhow, I guess this error occurs mainly because we are still on Python 2.7 and these strings are changed to unicodes instead of byte strings.

Thanks and best regards
Ramon

Hi @ramonski ,
thanks for the information. Exactly the same error.
hope other guys are lucky and not encounter.

Deng Fengyun

1 Like