plonegovbr/brasil.gov.portal

Conflito entre dependências - The requirement ('six>=1.12.0') is not allowed by your [versions] constraint (1.10.0)

seniocaires opened this issue · 3 comments

Qual versão do produto você está usando e em qual sistema operacional?

No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 18.04.4 LTS
Release: 18.04
Codename: bionic

Possui plugins adicionados além dos definidos numa instalação padrão do Portal Padrão?

Não.
Estou tentando fazer a instalação seguindo a documentação do portal.buildout

Está utilizando o buildout padrão como o usado em https://github.com/plonegovbr/portal.buildout?

Sim.
Tentei com a tag 2.1.1 e 2.1

Quais são os passos para reproduzir o problema?

git checkout tags/2.1.1
virtualenv py27
source py27/bin/activate

Foi necessário alterar o arquivo buildout.d/base.cfg porque a url informada não existe.

De:

extends =
    http://downloads.plone.org.br/release/2.1.1/versions.cfg

Para:

  extends =
    https://raw.githubusercontent.com/plonegovbr/portalpadrao.release/master/2.1.1/versions.cfg
pip install -U setuptools==36.6.1
python bootstrap.py
bin/buildout

Qual é o retorno esperado? O que você vê ao contrário do esperado?
Concluir a instalação

A aplicação forneceu algum erro no console ou na interface?

Version and requirements information containing six:
  [versions] constraint on six: 1.10.0
  Requirement of brasil.gov.portal==2.1.1: six
  Requirement of z3c.form: six
  Requirement of plone.contentrules: six
  Requirement of plone.api: six
  Requirement of collective.fingerpointing: six
  Requirement of collective.cover: six
  Requirement of brasil.gov.tiles: six
  Requirement of brasil.gov.agenda: six
  Requirement of Products.CMFQuickInstallerTool: six
  Requirement of plone.app.textfield: six
  Requirement of Products.CMFDynamicViewFTI: six
  Requirement of plone.transformchain: six
  Requirement of plone.folder: six
  Requirement of plone.subrequest: six
  Requirement of diazo>=1.0.3: six
  Requirement of z3c.pt>=2.2: six
  Requirement of ftw.upgrade: six>=1.12.0
  Requirement of archetypes.schemaextender>=1.6: six
While:
  Installing instance.
Error: The requirement ('six>=1.12.0') is not allowed by your [versions] constraint (1.10.0)

Por favor forneça informações adicionais que possam complementar o seu relato:

Busquei os locais onde fazia referência à "six"

grep -r --include=*.cfg six
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:condition = python:modules['posixpath'].basename(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:row-value = python:modules['posixpath'].dirname(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    ] + modules['posixpath'].sep
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    '_parent_path', modules['posixpath'].dirname(item['_parent'].get(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:value = python:modules['posixpath'].dirname(item['_old_paths'].rstrip('/'))
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:dirname = item.get('_parent_path', modules['posixpath'].dirname(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:     or modules['posixpath'].basename(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:value = python:modules['posixpath'].join(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    item.get('excludeFromNav', True) and modules['posixpath'].join(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:        ${path:dirname}, modules['posixpath'].dirname(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:value = python:modules['posixpath'].join(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    modules['posixpath'].dirname(item['_path']),
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:        item['_context'].aq_parent).chooseName(modules['posixpath'].basename(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:element-_old_paths = python:[modules['posixpath'].abspath(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:            modules['posixpath'].dirname(href.strip()) or
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:            item.get('_type') == 'Folder' and modules['posixpath'].join(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:                item['_old_paths'][0], modules['posixpath'].basename(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:value = python:[modules['posixpath'].abspath(modules['urlparse'].urljoin(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    modules['posixpath'].join('/', item['_parent_path']), href.strip())
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:         transmogrifier.context, modules['posixpath'].dirname(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:         transmogrifier.context, modules['posixpath'].dirname(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:value = python:modules['posixpath'].join(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    modules['posixpath'].dirname(modules['posixpath'].dirname(
eggs/plone.app.transmogrifier-1.4.1-py2.7.egg/plone/app/transmogrifier/xmlwalker.cfg:    modules['posixpath'].basename(item[options['key-name']]))
py27/lib/python2.7/site-packages/pip/_vendor/distlib/_backport/sysconfig.cfg:[posix_prefix]
py27/lib/python2.7/site-packages/pip/_vendor/distlib/_backport/sysconfig.cfg:[posix_home]
py27/lib/python2.7/site-packages/pip/_vendor/distlib/_backport/sysconfig.cfg:[posix_user]
etc/versions.cfg:six = 1.10.0

Dado o resultado acima:
Tentei executar a instalação alterando o arquivo etc/versions.cfg removendo a dependência "six = 1.10.0" e/ou alterando-a para "six = 1.12.0" mas o erro persiste.

@seniocaires favor tentar pinar:

ftw.upgrade = 3.0.0

no buildout. PR no https://github.com/plonegovbr/portal.buildout são bem vindos!

Criei uma cópia do arquivo https://raw.githubusercontent.com/plonegovbr/portalpadrao.release/master/2.1.1/versions.cfg em buildout.d/versions-local.cfg.

Alterei o arquivo buildout.d/base.cfg
De:

extends =
    http://downloads.plone.org.br/release/2.1.1/versions.cfg

Para:

extends =
    versions-local.cfg

Alterei o arquivo buildout.d/versions-local.cfg, adicionando:

ftw.upgrade = 3.0.0
inflection = 0.4.0
importlib-metadata = 1.5.2

Conforme sugerido, tenho feito downgrade (pinando versões mais antigas) das que dão erro.
Fiz downgrade da importlib-metadata tentando resolver o erro abaixo (tentei com 1.7.0, 1.6.1, 1.6.0, 1.5.2, 1.5.1, 1.5.0, mas sem sucesso):

bin/buildout

Updating zeo.
Installing instance.
Getting distribution for 'importlib-metadata==1.5.2'.
warning: no previously-included files found matching '.gitignore'
no previously-included directories found matching 'build'
no previously-included directories found matching '.tox'
zip_safe flag not set; analyzing archive contents...
Got importlib-metadata 1.5.2.
Getting distribution for 'zipp>=0.5'.
  File "build/bdist.linux-x86_64/egg/zipp.py", line 217
    def open(self, mode='r', *args, pwd=None, **kwargs):
                                      ^
SyntaxError: invalid syntax

zip_safe flag not set; analyzing archive contents...
  File "/opt/plone/portal.buildout/eggs/tmp4XLrzE/zipp-0.0.0-py2.7.egg/zipp.py", line 217
    def open(self, mode='r', *args, pwd=None, **kwargs):
                                      ^
SyntaxError: invalid syntax

While:
  Installing instance.
  Getting distribution for 'zipp>=0.5'.

An internal error occurred due to a bug in either zc.buildout or in a
recipe being used:
Traceback (most recent call last):
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/buildout.py", line 2123, in main
    getattr(buildout, command)(args)
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/buildout.py", line 796, in install
    installed_files = self[part]._call(recipe.install)
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/buildout.py", line 1553, in _call
    return f()
  File "/opt/plone/portal.buildout/eggs/plone.recipe.zope2instance-4.4.0-py2.7.egg/plone/recipe/zope2instance/__init__.py", line 139, in install
    installed.extend(self.install_scripts())
  File "/opt/plone/portal.buildout/eggs/plone.recipe.zope2instance-4.4.0-py2.7.egg/plone/recipe/zope2instance/__init__.py", line 638, in install_scripts
    requirements, ws = self.egg.working_set(['plone.recipe.zope2instance'])
  File "/opt/plone/portal.buildout/eggs/zc.recipe.egg-2.0.3-py2.7.egg/zc/recipe/egg/egg.py", line 84, in working_set
    allow_hosts=self.allow_hosts)
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/easy_install.py", line 913, in install
    return installer.install(specs, working_set)
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/easy_install.py", line 714, in install
    for dist in self._get_dist(req, ws):
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/easy_install.py", line 563, in _get_dist
    dists = [_move_to_eggs_dir_and_compile(dist, self._dest)]
  File "/opt/plone/portal.buildout/eggs/zc.buildout-2.9.6-py2.7.egg/zc/buildout/easy_install.py", line 1704, in _move_to_eggs_dir_and_compile
    os.rename(tmp_loc, newloc)
OSError: [Errno 39] Directory not empty

@idgserpro poderia listar as versões corretas para que eu possa pinar todas de uma vez?

ls -l eggs/

poderia listar as versões corretas para que eu possa pinar todas de uma vez?

@seniocaires eu também não sei quais são todas as versões 😄

Mas recomendo você verificar quais foram as versões utilizadas na build, no momento do release. ver:

https://travis-ci.org/github/plonegovbr/portal.buildout/jobs/491781091#L814

Você pode também verificar se versões que estão dando problema, já não fora pinadas no master:

https://github.com/plonegovbr/portal.buildout/blob/master/buildout.d/versions.cfg