make backend-docker-start fails with ('en_US:en', 'value') error
avoinea opened this issue · 3 comments
avoinea commented
Describe the bug
Traceback (most recent call last):
File "/app/bin/zconsole", line 8, in <module>
sys.exit(main())
^^^^^^
File "/app/lib/python3.11/site-packages/Zope2/utilities/zconsole.py", line 50, in main
runscript(namespace.zopeconf, *namespace.scriptargs)
File "/app/lib/python3.11/site-packages/Zope2/utilities/zconsole.py", line 22, in runscript
exec(compile(scriptcode, script_name, 'exec'), scriptglobals)
File "/app/scripts/create_site.py", line 84, in <module>
site = addPloneSite(app, SITE_ID, **payload)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/lib/python3.11/site-packages/Products/CMFPlone/factory.py", line 170, in addPloneSite
reg["plone.default_language"] = default_language
~~~^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/lib/python3.11/site-packages/plone/registry/registry.py", line 45, in __setitem__
self.records[name].value = value
^^^^^^^^^^^^^^^^^^^^^^^^
File "/app/lib/python3.11/site-packages/plone/registry/record.py", line 79, in _set_value
field.validate(value)
File "/app/lib/python3.11/site-packages/zope/schema/_bootstrapfields.py", line 295, in validate
self._validate(value)
File "/app/lib/python3.11/site-packages/zope/schema/_field.py", line 475, in _validate
raise ConstraintNotSatisfied(
zope.schema._bootstrapinterfaces.ConstraintNotSatisfied: ('en_US:en', 'value')
make[1]: *** [Makefile:110: backend-docker-start] Error 1
make[1]: Leaving directory '/opt/sandbox/volto/packages/volto'
To Reproduce
git clone git@github.com:plone/volto.git
cd volto
pnpm install
make backend-docker-start
Software (please complete the following information):
- OS: Ubuntu 22.04
- Browser [e.g. chrome, safari]
- Volto Version latest
- Plone Version latest
- Plone REST API Version latest
aadityaforwork commented
I did try to reproduce but the command make backend-docker-start gets successfully executed is there anything more specific to reproduce @avoinea ?
davisagli commented
@avoinea Do you have the LANGUAGE environment variable set? It should default to using en
, not en_US:en
: https://github.com/plone/plone-backend/blob/6.0.x/skeleton/scripts/create_site.py#L38
avoinea commented
@davisagli Yap. That's it! Not sure how it ended up there 😄
$ env | grep LANGUAGE
LANGUAGE=en_US:en