Install buildout and other dependencies

Hello,
@jensens I didn't get a quick feedback because for several days I walked around in circles without being able to run with
. \ py \ bin \ pip.exe install -r as you want.
Indeed after the creation of the « minimal buildout.cfg», in
Plone522 then from the virtual environment with
python -m venv in Plone 522, I have the following:

  • folder «Include» which is empty
  • folder «lib» which contains «site-packages»
  • folder «scripts»
  • file «buildout.cfg»
  • file «pyvenv.cfg»

However, I have no trace of a «bin» folder, so I can run:
. \ Py \ bin \ pip.exe install -r
I tried this:

C: \> cd / D D:
D: \> cd Plone522
D: \ Plone522>. \ Py \ bin \ pip.exe install -r

The specified path was not found. Which means:
«The specified path was not found. »
I then tried this:

C: \>. \ Py \ bin \ pip.exe install -r.

The result was no better :-)!
I suspect that at this level, I'm doing a bit of anything!
Can you please give me additional keys?
Thanks in advance.

python -m venv py should install the virtual python in the py subfolder. If py is omitted the prefix py\ must be omitted from the commands.

Hello,
@jensens I present to the community my latest adventures with the installations of the dependencies of plone 522 (reduced) under Windows 10.
Disregard the remarks about updating pip. It's done.
My problem is still installing buidout with the command "with. \ Py \ bin \ pip.exe install -r".
Following @jensens' suggestions, and as I don't have "pip" under "bin" but in the "scripts" folder and after rejecting the command with "bin", I directly executed "pip.exe install -r ".
I specify that python3 is well registered in the head in the environment variable ..
Here is the result:

« Microsoft Windows [version 10.0.19041.450]

(c) 2020 Microsoft Corporation. Tous droits réservés.

C:\WINDOWS\system32>cd \

C:\>cd /D D:

D:\>cd Plone522

D:\Plone522>python -m venv zinstance

D:\Plone522>

D:\Plone522>cd zinstance

D:\Plone522\zinstance>bin/pip install zc.buildout

'bin' n’est pas reconnu en tant que commande interne

ou externe, un programme exécutable ou un fichier de commandes.

D:\Plone522\zinstance>pip install zc.buildout

Collecting zc.buildout

Downloading zc.buildout-2.13.3-py2.py3-none-any.whl (153 kB)

|████████████████████████████████| 153 kB 595 kB/s

Requirement already satisfied: setuptools>=8.0 in d:\python38\lib\site-packages (from zc.buildout) (47.1.0)

Installing collected packages: zc.buildout

Successfully installed zc.buildout-2.13.3

WARNING: You are using pip version 20.1.1; however, version 20.2.2 is available.

You should consider upgrading via the 'd:\python38\python.exe -m pip install --upgrade pip' command.

D:\Plone522\zinstance>pip install zc.buildout

Requirement already satisfied: zc.buildout in d:\python38\lib\site-packages (2.13.3)

Requirement already satisfied: setuptools>=8.0 in d:\python38\lib\site-packages (from zc.buildout) (47.1.0)

D:\Plone522\zinstance>bin\pip.exe install -r

Le chemin d’accès spécifié est introuvable.

D:\Plone522\zinstance>pip.exe install -r

Usage:

pip install [options] <requirement specifier> [package-index-options] ...

pip install [options] -r <requirements file> [package-index-options] ...

pip install [options] [-e] <vcs project url> ...

pip install [options] [-e] <local project path> ...

pip install [options] <archive url/path> ...

-r option requires 1 argument

D:\Plone522\zinstance> »

I cannot understand the argument requested.
Can you please enlighten me on this to move forward? ?
Thanks in advance.

Hello,
@jensens After various tests, I adjusted the data according to my installation and finally, by executing the command \ Scripts \ pip.exe install -r https://dist.plone.org/release/5.2.2/requirements.txt, I got not a permission error but an internal error with the following result:

"Microsoft Windows [version 10.0.19041.450]
(c) 2020 Microsoft Corporation. All rights reserved.

C: \ WINDOWS \ system32> cd \

C: \> cd / D D:

D: \> cd Plone522

D: \ Plone522> cd zinstance

D: \ Plone522 \ zinstance> Scripts \ pip.exe install -r https://dist.plone.org/release/5.2.2/requirements.txt
Collecting setuptools == 42.0.2
  Downloading setuptools-42.0.2-py2.py3-none-any.whl (583 kB)
     | █████████████████████████████████ | 583 kB 136 kB / s
Collecting zc.buildout == 2.13.3
  Using cached zc.buildout-2.13.3-py2.py3-none-any.whl (153 kB)
Collecting wheel
  Using cached wheel-0.35.1-py2.py3-none-any.whl (33 kB)
Installing collected packages: setuptools, zc.buildout, wheel
  Attempting uninstall: setuptools
    Found existing installation: setuptools 47.1.0
    Uninstalling setuptools-47.1.0:
      Successfully uninstalled setuptools-47.1.0
Successfully installed setuptools-42.0.2 wheel-0.35.1 zc.buildout-2.13.3
WARNING: You are using pip version 20.1.1; however, version 20.2.2 is available.
You should consider upgrading via the 'd: \ plone522 \ zinstance \ scripts \ python.exe -m pip install --upgrade pip' command.

D: \ Plone522 \ zinstance> Scripts \ python.exe -m pip install --upgrade pip
Collecting pip
  Using cached pip-20.2.2-py2.py3-none-any.whl (1.5 MB)
Installing collected packages: pip
  Attempting uninstall: pip
    Found existing installation: pip 20.1.1
    Uninstalling pip-20.1.1:
      Successfully uninstalled pip-20.1.1
Successfully installed pip-20.2.2

D: \ Plone522 \ zinstance> Scripts \ pip.exe install -r https://dist.plone.org/release/5.2.2/requirements.txt
Requirement already satisfied: setuptools == 42.0.2 in d: \ plone522 \ zinstance \ lib \ site-packages (from -r https://dist.plone.org/release/5.2.2/requirements.txt (line 1) ) (42.0.2)
Requirement already satisfied: zc.buildout == 2.13.3 in d: \ plone522 \ zinstance \ lib \ site-packages (from -r https://dist.plone.org/release/5.2.2/requirements.txt (line 2)) (2.13.3)
Requirement already satisfied: wheel in d: \ plone522 \ zinstance \ lib \ site-packages (from -r https://dist.plone.org/release/5.2.2/requirements.txt (line 3)) (0.35.1 )

D: \ Plone522 \ zinstance> Scripts \ buildout.exe
While:
  Initializing.

An internal error occurred due to a bug in either zc.buildout or in a
recipe being used:
Traceback (most recent call last):
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ buildout.py", line 2172, in main
    buildout = Buildout (config_file, options,
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ buildout.py", line 369, in __init__
    _update (data, _open (os.path.dirname (config_file), config_file, [],
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ buildout.py", line 1801, in _open
    result = zc.buildout.configparser.parse (
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ configparser.py", line 207, in parse
    raise MissingSectionHeaderError (fpname, lineno, line)
zc.buildout.configparser.MissingSectionHeaderError: File contains no section headers.
file: D: \ Plone522 \ zinstance \ buildout.cfg, line: 2
'[buildout] \ n'

D: \ Plone522 \ zinstance> Scripts \ buildout.exe
While:
  Initializing.

An internal error occurred due to a bug in either zc.buildout or in a
recipe being used:
Traceback (most recent call last):
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ buildout.py", line 2172, in main
    buildout = Buildout (config_file, options,
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ buildout.py", line 369, in __init__
    _update (data, _open (os.path.dirname (config_file), config_file, [],
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ buildout.py", line 1801, in _open
    result = zc.buildout.configparser.parse (
  File "d: \ plone522 \ zinstance \ lib \ site-packages \ zc \ buildout \ configparser.py", line 207, in parse
    raise MissingSectionHeaderError (fpname, lineno, line)
zc.buildout.configparser.MissingSectionHeaderError: File contains no section headers.
file: D: \ Plone522 \ zinstance \ buildout.cfg, line: 2
'[buildout] \ n'

D: \ Plone522 \ zinstance> "

Do you have any idea what this is about?
Thanks in advance.

Looks like your buildout.cfg is buggy. Please check if it is really exactly like in my post at:

Hello ,
@jensens, no, I hadn't done it exactly as you advised me to.
Indeed, when I follow your procedure in the order given, I fail to create "buildout.cfg" from the command line.
From the "Plone522" folder, I try to create buildout.cfg with:

"Echo" ""
    [buildout]
    extends = https://dist.plone.org/release/5.2.2/versions.cfg
    parts = instance

    [instance]
    recipe = plone.recipe.zope2instance
    user = admin: admin
    eggs = Plone
    
"" "> buildout.cfg".
It does not work.
Each time I get the following message:

"D: \ Plone522> [buildout]
'[buildout]' is not recognized as an internal command
or external, an executable program or a batch file.

D: \ Plone522> extends = https://dist.plone.org/release/5.2.2/versions.cfg
'extends' is not recognized as an internal command
or external, an executable program or a batch file.

D: \ Plone522> parts = instance
'parts' is not recognized as an internal order
or external, an executable program or a batch file.

D: \ Plone522>
D: \ Plone522> [instance]
'[instance]' is not recognized as an internal command
or external, an executable program or a batch file.

D: \ Plone522> recipe = plone.recipe.zope2instance
'recipe' is not recognized as an internal command
or external, an executable program or a batch file.

D: \ Plone522> user = admin: admin
'user' is not recognized as an internal command
or external, an executable program or a batch file.

D: \ Plone522> eggs = Plone
'eggs' is not recognized as an internal command
or external, an executable program or a batch file.

D: \ Plone522>
D: \ Plone522> "" "> buildout.cfg"
``
On the other hand, when I proceed as before, I directly created the “Plone522” folder as follows:

"C: > python -m venv d: \ Plone522".

Then I manually create the buildout.cfg file with minimal content and save it to "Plone522".
Unfortunately by doing this the buildout.cfg file is bugged as you have noticed.
Do we have another way out of the deadlock?
Thanks in advance.

Hello @jensens
Faced with the impossibility for me to install buildout according to the recommended command "install buildout and other dependencies with. \ Py \ bin \ pip.exe install -r, do you have feedback from people who have succeeded?
I am using "Windows 10 Professional V 2004"
I haven't been able to figure out where it's stuck in my attempts.
Thanks in advance.

So I tried this in from scratch a fresh free Windows 10 Virtual Machine in Virtualbox.
I corrected it and added the missing pieces, but the previous instructions were working too, just that I was not able to start Plone afterwards.

I installed Python 3.8 from https://www.python.org/downloads/

I installed C++ build tools (not sure if really needed, but I think so, if anyone knows details please comment) from https://visualstudio.microsoft.com/downloads/ -> scroll down to "All Downloads", search for "c++ build tools" -> "Build Tools for Visual Studio 2019" -> Download -> Install -> Install c++ build extension in installer.

Open Powershell
Screenshot from 2020-09-18 14-03-44

Make folder for Plone, enter it, open Notepad to create buildout.cfg:
Screenshot from 2020-09-18 14-06-58

Allow to create new file
Screenshot from 2020-09-18 14-07-28

Copy-Paste

[buildout]
extends = https://dist.plone.org/release/5.2.2/versions.cfg
parts = instance zopescripts

[instance]
recipe = plone.recipe.zope2instance
user = admin:admin
eggs = Plone

[zopescripts]
recipe = zc.recipe.egg
eggs =
    Plone
    Zope
    Paste

into it:

Don't forget to save!

Then create a Python virtual environment
py.exe -m venv py
Screenshot from 2020-09-21 08-09-50

Install buildout and other dependencies with pip:
.\py\Scripts\pip.exe install -r https://dist.plone.org/release/5.2.2/requirements.cfg

Now, run buildout:
.\py\Scripts\buildout.exe
Screenshot from 2020-09-18 15-06-25

This may take a while.

Then start Plone:
.\bin\runwsgi.exe -v .\parts\instance\etc\wsgi.ini

Go to the web-browser and open http://localhost:8080:

Have fun.

1 Like