plone / plone.recipe.zope2instance

zc.buildout recipe to setup and configure a Zope 2 instance.
https://pypi.org/project/plone.recipe.zope2instance
7 stars 23 forks source link

Error: 'http-header-max-length' is not a known key name with bin/instance, plone.recipe.zope2instance 6.0.0 #65

Closed zopyx closed 5 years ago

zopyx commented 5 years ago

Plone 5.2a2, plone.recipe.zope2instance 6.0.0 (under Python 3):

bin/instance fg
Error: 'http-header-max-length' is not a known key name
(line 9 in file:///home/ajung/sandboxes/onkopedia_buildout-plone5/parts/instance/etc/zope.conf)
For help, use bin/instance -h

bin/wsgi.py is working as expected

cekk commented 5 years ago

This seems fixed in 6.1.0. I had the same problem on 6.0.0 but not on 6.1.0.

icemac commented 5 years ago

@zopyx Can you try out 6.1.0 to confirm that it solves your issue?

hvelarde commented 5 years ago

no, 6.1.0 doesn't solve the issue, neither 6.1.1:

$ bin/instance fg
Traceback (most recent call last):
  File "bin/instance", line 260, in <module>
    + sys.argv[1:]))
  File "/home/hvelarde/.buildout/eggs/plone.recipe.zope2instance-6.1.0-py3.7.egg/plone/recipe/zope2instance/ctl.py", line 869, in main
    options = ZServerCtlOptions()
NameError: name 'ZServerCtlOptions' is not defined

I'm testing with Plone 5.2b1 with Python 3.7.0a4.

pbauer commented 5 years ago

@hvelarde please show the config of your part [instance].

zopyx commented 5 years ago

Having the same issue with ZServerCtlOptions while trying to port collective.es.index...checking later during the sprint.

zopyx commented 5 years ago

The ZServerCtlOptions error occurs also with

https://github.com/collective/collective.es.index/blob/plone-52-python3/buildout.cfg

but with wsgi=on disabled.

zopyx commented 5 years ago

The internal check for HAS_ZSERVER appears flaky with WSGI disabled... [6] > /home/ajung/.buildout/eggs/plone.recipe.zope2instance-6.1.1-py3.7.egg/plone/recipe/zope2instance/ctl.py(176)() -> from ZServer.Zope2.Startup.options import ZopeOptions

(Pdb++) import ZServer *** ModuleNotFoundError: No module named 'ZServer' (Pdb++)

Not sure why ZServer module is not available.

zopyx commented 5 years ago

In contrast: WSGI mode enabled leads to a different failure:

https://github.com/plone/Products.CMFPlone/issues/2774

pbauer commented 5 years ago

Can you please try to reproduce it with the current master of plone.recipe.zope2instance since it has a important change (wsgi is always on unless explicitly disabled with wsgi=off and running python 2)

pbauer commented 5 years ago

ZServer cannot be avaibale when running on py3.

hvelarde commented 5 years ago

@pbauer this is what I have:

[instance]
deprecation-warnings= on
    buildout.cfg
eggs= Plone
plone.app.upgrade
${buildout:package-name}
${buildout:eggs}
    https://raw.github.com/collective/buildout.plonetest/master/plone-5.2.x.cfg
environment-vars= zope_i18n_compile_mo_files true
PROFILE_PUBLISHER 1
    https://raw.github.com/collective/buildout.plonetest/master/plone-5.2.x.cfg
+=  buildout.cfg
http-address= 8080
    https://raw.github.com/collective/buildout.plonetest/master/plone-5.2.x.cfg
recipe= plone.recipe.zope2instance
    https://raw.github.com/collective/buildout.plonetest/master/plone-5.2.x.cfg
user= admin:admin
    https://raw.github.com/collective/buildout.plonetest/master/plone-5.2.x.cfg
wsgi= on
    buildout.cfg
zcml= ${buildout:package-name}
    https://raw.github.com/collective/buildout.plonetest/master/plone-5.2.x.cfg
hvelarde commented 5 years ago

plone.recipe.zope2instance = 6.1.3 seems to fix the issue.

dataflake commented 5 years ago

This is already fixed. wsgi = on is the default, and the keyword http-header-max-length does not throw an error.