You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/05/09 17:20:49 UTC
[GitHub] [arrow-cookbook] toddfarmer opened a new pull request, #193: Toddfarmer/contributing java dependencies
toddfarmer opened a new pull request, #193:
URL: https://github.com/apache/arrow-cookbook/pull/193
Addresses issue #190 .
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#issuecomment-1136305145
@davisusanibar it looks like
```java
try {
flightServer.start();
System.out.println("S1: Server (Location): Listening on port " + flightServer.getPort());
} catch (IOException e) {
System.exit(1);
}
```
in one of the examples actually hit the `catch` and that `System.exit` causes jshell to print the `State engine terminated`
```
Expected:
S1: Server (Location): Listening on port 33333
C1: Client (Location): Connected to grpc+tcp://0.0.0.0:33333
C2: Client (Populate Data): Wrote 2 batches with 3 rows each
C3: Client (Get Metadata): FlightInfo{schema=Schema<name: Utf8>, descriptor=profiles, endpoints=[FlightEndpoint{locations=[Location{uri=grpc+tcp://0.0.0.0:33333}], ticket=org.apache.arrow.flight.Ticket@58871b0a}], bytes=-1, records=6}
C4: Client (Get Stream):
Client Received batch #1, Data:
name
Ronald
David
Francisco
Client Received batch #2, Data:
name
Manuel
Felipe
JJ
C5: Client (List Flights Info): FlightInfo{schema=Schema<name: Utf8>, descriptor=profiles, endpoints=[FlightEndpoint{locations=[Location{uri=grpc+tcp://0.0.0.0:33333}], ticket=org.apache.arrow.flight.Ticket@58871b0a}], bytes=-1, records=6}
C6: Client (Do Delete Action): Delete completed
C7: Client (List Flights Info): After delete - No records
C8: Server shut down successfully
Got:
State engine terminated.
**********************************************************************
```
IMO we should have `e.printStackTrace()` there for debugging
but in the meantime I'll kick the CI
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] toddfarmer commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
toddfarmer commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r872881541
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
I'm not entirely sure I understand, but my (new) laptop has only python3 installed:
```
todd@pop-os:~/arrow/java$ pip --version
pip 22.0.2 from /usr/lib/python3/dist-packages/pip (python 3.10)
todd@pop-os:~/arrow/java$ pip3 --version
pip 22.0.2 from /usr/lib/python3/dist-packages/pip (python 3.10)
todd@pop-os:~/arrow/java$ python --version
Command 'python' not found, did you mean:
command 'python3' from deb python3
command 'python' from deb python-is-python3
todd@pop-os:~/arrow/java$ python3 --version
Python 3.10.4
```
I don't have the output handy from the initial run after installing pip, but I can revert to that state (removing all pip modules, removing sphinx-build via apt) and try to recreate, if useful. I just know that installing pip allowed the build script to proceed, but it still failed with the error cited above, with missing sphinx-build.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on pull request #193: [Java] Clarify build dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#issuecomment-1136322685
Or actually I guess I can just edit the commit message before merge here so no worries. Thanks for updating this!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] toddfarmer commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
toddfarmer commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r868536158
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
It was not for me. I had to separately perform `sudo apt install sphinx-build` on my new laptop.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r870332568
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Ah, the main reason is because you should be doing `make java` from the repository root, which will install dependencies for you.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm merged pull request #193: [Java] Clarify build dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm merged PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] amol- commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
amol- commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r870489645
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Yeah, that `cd java && pip install -r requirements.txt` should be installing the dependencies.
A common reason for that is if you have multiple versions of Python installed (usually Python2 and Python3) and pip is available for one of them, but the default interpreter is a different one.
We could probably improve that by switching the `pip install` to `python -m pip install` which should guarantee you use the pip from your default interpreter.
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Yeah, that `cd java && pip install -r requirements.txt` should be installing the dependencies.
A common reason for that is if you have multiple versions of Python installed (usually Python2 and Python3) and pip is available for one of them, but the default interpreter is a different one.
We could probably improve that by switching the `pip install` to `python -m pip install` which should guarantee you use the pip from your default interpreter.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r880818125
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Thanks. As long as we just make it clear that sphinx is installed via pip then this is good to me.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] toddfarmer commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
toddfarmer commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r880575964
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
I've attempted to reproduce the error I documented earlier caused by missing `sphinx-build`, but have only had limited success. Generally speaking, the installation of the requirements.txt modules satisfies everything, and I am able to build successfully. The only time I was able to trigger the error again was after a successful build, deleting the contents of `/home/todd/.local/bin` directory, which included `sphinx-build`:
```
todd@pop-os:~/arrow-cookbook$ which sphinx-build
/home/todd/.local/bin/sphinx-build
todd@pop-os:~/arrow-cookbook$ ls /home/todd/./local/bin
ls: cannot access '/home/todd/./local/bin': No such file or directory
todd@pop-os:~/arrow-cookbook$ ls /home/todd/.local/bin
black pycodestyle rst2man.py rstpep2html.py
blackd pyflakes rst2odt_prepstyles.py sphinx-apidoc
black-primer pygmentize rst2odt.py sphinx-autogen
flake8 rst2html4.py rst2pseudoxml.py sphinx-build
isort rst2html5.py rst2s5.py sphinx-quickstart
pybabel rst2html.py rst2xetex.py
__pycache__ rst2latex.py rst2xml.py
todd@pop-os:~/arrow-cookbook$ rm -rf /home/todd/.local/bin/*
todd@pop-os:~/arrow-cookbook$ which sphinx-build
todd@pop-os:~/arrow-cookbook$ make java
>>> Installing Java Dependencies <<<
cd java && pip install -r requirements.txt
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: Sphinx>=4.0.2 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 1)) (4.5.0)
Requirement already satisfied: black==21.7b0 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 2)) (21.7b0)
Requirement already satisfied: flake8==3.8.3 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 3)) (3.8.3)
Requirement already satisfied: isort==4.3.21 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 4)) (4.3.21)
Requirement already satisfied: regex>=2020.1.8 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (2022.4.24)
Requirement already satisfied: pathspec<1,>=0.8.1 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.9.0)
Requirement already satisfied: appdirs in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.4.4)
Requirement already satisfied: mypy-extensions>=0.4.3 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.4.3)
Requirement already satisfied: tomli<2.0.0,>=0.2.6 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.2.3)
Requirement already satisfied: click>=7.1.2 in /usr/lib/python3/dist-packages (from black==21.7b0->-r requirements.txt (line 2)) (8.0.3)
Requirement already satisfied: mccabe<0.7.0,>=0.6.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (0.6.1)
Requirement already satisfied: pyflakes<2.3.0,>=2.2.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.2.0)
Requirement already satisfied: pycodestyle<2.7.0,>=2.6.0a1 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.6.0)
Requirement already satisfied: requests>=2.5.0 in /usr/lib/python3/dist-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.25.1)
Requirement already satisfied: Pygments>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.12.0)
Requirement already satisfied: packaging in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (21.3)
Requirement already satisfied: sphinxcontrib-devhelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: sphinxcontrib-jsmath in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.1)
Requirement already satisfied: sphinxcontrib-qthelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.3)
Requirement already satisfied: sphinxcontrib-htmlhelp>=2.0.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.0.0)
Requirement already satisfied: docutils<0.18,>=0.14 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.17.1)
Requirement already satisfied: alabaster<0.8,>=0.7 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.7.12)
Requirement already satisfied: babel>=1.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.10.1)
Requirement already satisfied: sphinxcontrib-applehelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: imagesize in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.3.0)
Requirement already satisfied: sphinxcontrib-serializinghtml>=1.1.5 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.1.5)
Requirement already satisfied: snowballstemmer>=1.1 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.2.0)
Requirement already satisfied: Jinja2>=2.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (3.1.2)
Requirement already satisfied: pytz>=2015.7 in /usr/lib/python3/dist-packages (from babel>=1.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2022.1)
Requirement already satisfied: MarkupSafe>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Jinja2>=2.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.1.1)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /usr/lib/python3/dist-packages (from packaging->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.4.7)
>>> Building Java Cookbook <<<
cd java && make html
make[1]: Entering directory '/home/todd/arrow-cookbook/java'
/bin/sh: 1: sphinx-build: not found
make[1]: *** [Makefile:20: html] Error 127
make[1]: Leaving directory '/home/todd/arrow-cookbook/java'
make: *** [Makefile:81: java] Error 2
```
However, after explicitly removing the modules, re-running `make java` resulted in success:
```
todd@pop-os:~/arrow-cookbook/java$ pip uninstall -r requirements.txt
Found existing installation: Sphinx 4.5.0
Uninstalling Sphinx-4.5.0:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/Sphinx-4.5.0.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/sphinx/*
Proceed (Y/n)?
Successfully uninstalled Sphinx-4.5.0
Found existing installation: black 21.7b0
Uninstalling black-21.7b0:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/_black_version.py
/home/todd/.local/lib/python3.10/site-packages/black-21.7b0.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/black/*
/home/todd/.local/lib/python3.10/site-packages/black_primer/*
/home/todd/.local/lib/python3.10/site-packages/blackd/*
/home/todd/.local/lib/python3.10/site-packages/blib2to3/*
Proceed (Y/n)?
Successfully uninstalled black-21.7b0
Found existing installation: flake8 3.8.3
Uninstalling flake8-3.8.3:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/flake8-3.8.3.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/flake8/*
Proceed (Y/n)?
Successfully uninstalled flake8-3.8.3
Found existing installation: isort 4.3.21
Uninstalling isort-4.3.21:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/isort-4.3.21.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/isort/*
Proceed (Y/n)?
Successfully uninstalled isort-4.3.21
todd@pop-os:~/arrow-cookbook/java$ cd ..
todd@pop-os:~/arrow-cookbook$ make java
>>> Installing Java Dependencies <<<
cd java && pip install -r requirements.txt
Defaulting to user installation because normal site-packages is not writeable
Collecting Sphinx>=4.0.2
Using cached Sphinx-4.5.0-py3-none-any.whl (3.1 MB)
Collecting black==21.7b0
Using cached black-21.7b0-py3-none-any.whl (141 kB)
Collecting flake8==3.8.3
Using cached flake8-3.8.3-py2.py3-none-any.whl (72 kB)
Collecting isort==4.3.21
Using cached isort-4.3.21-py2.py3-none-any.whl (42 kB)
Requirement already satisfied: pathspec<1,>=0.8.1 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.9.0)
Requirement already satisfied: regex>=2020.1.8 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (2022.4.24)
Requirement already satisfied: mypy-extensions>=0.4.3 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.4.3)
Requirement already satisfied: appdirs in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.4.4)
Requirement already satisfied: click>=7.1.2 in /usr/lib/python3/dist-packages (from black==21.7b0->-r requirements.txt (line 2)) (8.0.3)
Requirement already satisfied: tomli<2.0.0,>=0.2.6 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.2.3)
Requirement already satisfied: pyflakes<2.3.0,>=2.2.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.2.0)
Requirement already satisfied: mccabe<0.7.0,>=0.6.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (0.6.1)
Requirement already satisfied: pycodestyle<2.7.0,>=2.6.0a1 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.6.0)
Requirement already satisfied: sphinxcontrib-applehelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: alabaster<0.8,>=0.7 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.7.12)
Requirement already satisfied: imagesize in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.3.0)
Requirement already satisfied: sphinxcontrib-htmlhelp>=2.0.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.0.0)
Requirement already satisfied: babel>=1.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.10.1)
Requirement already satisfied: requests>=2.5.0 in /usr/lib/python3/dist-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.25.1)
Requirement already satisfied: packaging in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (21.3)
Requirement already satisfied: sphinxcontrib-qthelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.3)
Requirement already satisfied: sphinxcontrib-serializinghtml>=1.1.5 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.1.5)
Requirement already satisfied: sphinxcontrib-devhelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: Pygments>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.12.0)
Requirement already satisfied: Jinja2>=2.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (3.1.2)
Requirement already satisfied: snowballstemmer>=1.1 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.2.0)
Requirement already satisfied: docutils<0.18,>=0.14 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.17.1)
Requirement already satisfied: sphinxcontrib-jsmath in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.1)
Requirement already satisfied: pytz>=2015.7 in /usr/lib/python3/dist-packages (from babel>=1.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2022.1)
Requirement already satisfied: MarkupSafe>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Jinja2>=2.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.1.1)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /usr/lib/python3/dist-packages (from packaging->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.4.7)
Installing collected packages: isort, flake8, black, Sphinx
Successfully installed Sphinx-4.5.0 black-21.7b0 flake8-3.8.3 isort-4.3.21
>>> Building Java Cookbook <<<
cd java && make html
make[1]: Entering directory '/home/todd/arrow-cookbook/java'
Running Sphinx v4.5.0
WARNING: html_static_path entry '_static' does not exist
loading pickled environment... done
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 7 source files that are out of date
updating environment: 0 added, 0 changed, 0 removed
looking for now-outdated files... none found
preparing documents... done
writing output... [100%] schema
generating indices... genindex done
writing additional pages... search done
copying static files... done
copying extra files... done
dumping search index in English (code: en)... done
dumping object inventory... done
build succeeded, 1 warning.
The HTML pages are in build/html.
make[1]: Leaving directory '/home/todd/arrow-cookbook/java'
mkdir -p build/java
cp -r java/build/html/* build/java
```
I will update the PR to eliminate the reference to needing `sphinx-build` explicitly installed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#issuecomment-1136305495
@toddfarmer mind updating the PR title to be a little more descriptive too?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r868256277
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
This is installed as part of requirements.txt right? So "all" you need is Python and JShell?
##########
java/CONTRIBUTING.rst:
##########
@@ -21,6 +35,13 @@ For java cookbook we are running these with Java Shell tool -
> jshell --version
jshell 11.0.14
+
+Build Process
+-------------------------
+Run ``make java`` from the cookbook root directory (the one where
+the ``README.rst`` exists) to install all necessary dependencies
+and will compile the cookbook to HTML.
Review Comment:
```suggestion
and compile the cookbook to HTML.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] amol- commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
amol- commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r870489645
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Yeah, that `cd java && pip install -r requirements.txt` should be installing the dependencies.
A common reason for that is if you have multiple versions of Python installed (usually Python2 and Python3) and pip is available for one of them, but the default interpreter is a different one (IE: you have `pip` on Python2, but your default python command is `Python3`)
We could probably improve that by switching the `pip install` to `python -m pip install` which should guarantee you use the pip from your default interpreter.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] toddfarmer commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
toddfarmer commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r872881541
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
I'm not entirely sure I understand, but my (new) laptop has only python3 installed:
```
todd@pop-os:~/arrow/java$ pip --version
pip 22.0.2 from /usr/lib/python3/dist-packages/pip (python 3.10)
todd@pop-os:~/arrow/java$ pip3 --version
pip 22.0.2 from /usr/lib/python3/dist-packages/pip (python 3.10)
todd@pop-os:~/arrow/java$ python --version
Command 'python' not found, did you mean:
command 'python3' from deb python3
command 'python' from deb python-is-python3
todd@pop-os:~/arrow/java$ python3 --version
Python 3.10.4
```
I don't have the output handy from the initial run after installing pip, but I can revert to that state (removing all pip modules, removing sphinx-build via apt) and try to recreate, if useful. I just know that installing pip allowed the build script to proceed, but it still failed with the error cited above, with missing sphinx-build. Executing the apt command referenced in the error message resolved it for me.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] toddfarmer commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
toddfarmer commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r870386364
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Right, I did `make java` from the repo root, but it still failed on missing sphinx-build:
```
todd@pop-os:~/arrow-cookbook$ make java
>>> Installing Java Dependencies <<<
cd java && pip install -r requirements.txt
...
>>> Building Java Cookbook <<<
cd java && make html
make[1]: Entering directory '/home/todd/arrow-cookbook/java'
/bin/sh: 1: sphinx-build: not found
make[1]: *** [Makefile:20: html] Error 127
make[1]: Leaving directory '/home/todd/arrow-cookbook/java'
make: *** [Makefile:81: java] Error 2
todd@pop-os:~/arrow-cookbook$ sphinx-build
Command 'sphinx-build' not found, but can be installed with:
sudo apt install python3-sphinx
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] amol- commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
amol- commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r870489645
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Yeah, that `cd java && pip install -r requirements.txt` should be installing the dependencies.
A common reason for that is if you have multiple versions of Python installed (usually Python2 and Python3) and pip is available for one of them, but the default interpreter is a different one (IE: you have `pip` on Python2, but your default `python` command is Python3)
We could probably improve that by switching the `pip install` to `python -m pip install` which should guarantee you use the pip from your default interpreter.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r873575581
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
I think that would be useful.
I would also give it a try with virtualenv as suggested above, just to isolate it from your environment entirely.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r870393358
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Hmm, that should work, and I just gave it a try. What is the output from `pip install`? It seems it's getting installed somewhere that isn't on $PATH…
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] lidavidm commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
lidavidm commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r869157907
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
Ah, that's because the instructions are wrong. The Makefile doesn't install dependencies.
Can you try removing the system sphinx-build and manually following
```
$ virtualenv venv
$ source venv/bin/activate
# You can use a Conda environment instead of virtualenv above
$ pip install -r requirements.txt
$ make html
```
? (We shouldn't be mixing system and non-system packages.)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow-cookbook] toddfarmer commented on a diff in pull request #193: Toddfarmer/contributing java dependencies
Posted by GitBox <gi...@apache.org>.
toddfarmer commented on code in PR #193:
URL: https://github.com/apache/arrow-cookbook/pull/193#discussion_r880575964
##########
java/CONTRIBUTING.rst:
##########
@@ -1,13 +1,27 @@
Building the Java Cookbook
=========================
-
The Java cookbook uses the Sphinx documentation system.
-Running ``make java`` from the cookbook root directory (the one where
-the ``README.rst`` exists) will install all necessary dependencies
-and will compile the cookbook to HTML.
+Dependencies
+-------------------------
+The following are required to successfully build the Java cookbook:
+
+Python
+^^^^^^^^^^^^^^^^^^^^^^^^^
+The cookbook build tooling depends upon Python, and the ability to
+install needed packages via pip, to build the Java cookbook. The
+dependency packages managed via pip by build scripts are found at
+`requirements.txt <requirements.txt>`_.
+
+sphinx-build
+^^^^^^^^^^^^^^^^^^^^^^^^^
+Building the Java cookbook requires Sphinx build tools:
-For java cookbook we are running these with Java Shell tool -
+`sphinx-build <https://www.sphinx-doc.org/en/master/man/sphinx-build.html>`_
Review Comment:
I've attempted to reproduce the error I documented earlier caused by missing `sphinx-build`, but have only had limited success. Generally speaking, the installation of the requirements.txt modules satisfies everything, and I am able to build successfully. The only time I was able to trigger the error again was after a successful build, deleting the contents of `/home/todd/.local/bin` directory, which included `sphinx-build`:
```
todd@pop-os:~/arrow-cookbook$ which sphinx-build
/home/todd/.local/bin/sphinx-build
todd@pop-os:~/arrow-cookbook$ ls /home/todd/.local/bin
black pycodestyle rst2man.py rstpep2html.py
blackd pyflakes rst2odt_prepstyles.py sphinx-apidoc
black-primer pygmentize rst2odt.py sphinx-autogen
flake8 rst2html4.py rst2pseudoxml.py sphinx-build
isort rst2html5.py rst2s5.py sphinx-quickstart
pybabel rst2html.py rst2xetex.py
__pycache__ rst2latex.py rst2xml.py
todd@pop-os:~/arrow-cookbook$ rm -rf /home/todd/.local/bin/*
todd@pop-os:~/arrow-cookbook$ which sphinx-build
todd@pop-os:~/arrow-cookbook$ make java
>>> Installing Java Dependencies <<<
cd java && pip install -r requirements.txt
Defaulting to user installation because normal site-packages is not writeable
Requirement already satisfied: Sphinx>=4.0.2 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 1)) (4.5.0)
Requirement already satisfied: black==21.7b0 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 2)) (21.7b0)
Requirement already satisfied: flake8==3.8.3 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 3)) (3.8.3)
Requirement already satisfied: isort==4.3.21 in /home/todd/.local/lib/python3.10/site-packages (from -r requirements.txt (line 4)) (4.3.21)
Requirement already satisfied: regex>=2020.1.8 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (2022.4.24)
Requirement already satisfied: pathspec<1,>=0.8.1 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.9.0)
Requirement already satisfied: appdirs in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.4.4)
Requirement already satisfied: mypy-extensions>=0.4.3 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.4.3)
Requirement already satisfied: tomli<2.0.0,>=0.2.6 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.2.3)
Requirement already satisfied: click>=7.1.2 in /usr/lib/python3/dist-packages (from black==21.7b0->-r requirements.txt (line 2)) (8.0.3)
Requirement already satisfied: mccabe<0.7.0,>=0.6.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (0.6.1)
Requirement already satisfied: pyflakes<2.3.0,>=2.2.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.2.0)
Requirement already satisfied: pycodestyle<2.7.0,>=2.6.0a1 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.6.0)
Requirement already satisfied: requests>=2.5.0 in /usr/lib/python3/dist-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.25.1)
Requirement already satisfied: Pygments>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.12.0)
Requirement already satisfied: packaging in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (21.3)
Requirement already satisfied: sphinxcontrib-devhelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: sphinxcontrib-jsmath in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.1)
Requirement already satisfied: sphinxcontrib-qthelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.3)
Requirement already satisfied: sphinxcontrib-htmlhelp>=2.0.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.0.0)
Requirement already satisfied: docutils<0.18,>=0.14 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.17.1)
Requirement already satisfied: alabaster<0.8,>=0.7 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.7.12)
Requirement already satisfied: babel>=1.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.10.1)
Requirement already satisfied: sphinxcontrib-applehelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: imagesize in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.3.0)
Requirement already satisfied: sphinxcontrib-serializinghtml>=1.1.5 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.1.5)
Requirement already satisfied: snowballstemmer>=1.1 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.2.0)
Requirement already satisfied: Jinja2>=2.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (3.1.2)
Requirement already satisfied: pytz>=2015.7 in /usr/lib/python3/dist-packages (from babel>=1.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2022.1)
Requirement already satisfied: MarkupSafe>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Jinja2>=2.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.1.1)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /usr/lib/python3/dist-packages (from packaging->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.4.7)
>>> Building Java Cookbook <<<
cd java && make html
make[1]: Entering directory '/home/todd/arrow-cookbook/java'
/bin/sh: 1: sphinx-build: not found
make[1]: *** [Makefile:20: html] Error 127
make[1]: Leaving directory '/home/todd/arrow-cookbook/java'
make: *** [Makefile:81: java] Error 2
```
However, after explicitly removing the modules, re-running `make java` resulted in success:
```
todd@pop-os:~/arrow-cookbook/java$ pip uninstall -r requirements.txt
Found existing installation: Sphinx 4.5.0
Uninstalling Sphinx-4.5.0:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/Sphinx-4.5.0.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/sphinx/*
Proceed (Y/n)?
Successfully uninstalled Sphinx-4.5.0
Found existing installation: black 21.7b0
Uninstalling black-21.7b0:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/_black_version.py
/home/todd/.local/lib/python3.10/site-packages/black-21.7b0.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/black/*
/home/todd/.local/lib/python3.10/site-packages/black_primer/*
/home/todd/.local/lib/python3.10/site-packages/blackd/*
/home/todd/.local/lib/python3.10/site-packages/blib2to3/*
Proceed (Y/n)?
Successfully uninstalled black-21.7b0
Found existing installation: flake8 3.8.3
Uninstalling flake8-3.8.3:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/flake8-3.8.3.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/flake8/*
Proceed (Y/n)?
Successfully uninstalled flake8-3.8.3
Found existing installation: isort 4.3.21
Uninstalling isort-4.3.21:
Would remove:
/home/todd/.local/lib/python3.10/site-packages/isort-4.3.21.dist-info/*
/home/todd/.local/lib/python3.10/site-packages/isort/*
Proceed (Y/n)?
Successfully uninstalled isort-4.3.21
todd@pop-os:~/arrow-cookbook/java$ cd ..
todd@pop-os:~/arrow-cookbook$ make java
>>> Installing Java Dependencies <<<
cd java && pip install -r requirements.txt
Defaulting to user installation because normal site-packages is not writeable
Collecting Sphinx>=4.0.2
Using cached Sphinx-4.5.0-py3-none-any.whl (3.1 MB)
Collecting black==21.7b0
Using cached black-21.7b0-py3-none-any.whl (141 kB)
Collecting flake8==3.8.3
Using cached flake8-3.8.3-py2.py3-none-any.whl (72 kB)
Collecting isort==4.3.21
Using cached isort-4.3.21-py2.py3-none-any.whl (42 kB)
Requirement already satisfied: pathspec<1,>=0.8.1 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.9.0)
Requirement already satisfied: regex>=2020.1.8 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (2022.4.24)
Requirement already satisfied: mypy-extensions>=0.4.3 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (0.4.3)
Requirement already satisfied: appdirs in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.4.4)
Requirement already satisfied: click>=7.1.2 in /usr/lib/python3/dist-packages (from black==21.7b0->-r requirements.txt (line 2)) (8.0.3)
Requirement already satisfied: tomli<2.0.0,>=0.2.6 in /home/todd/.local/lib/python3.10/site-packages (from black==21.7b0->-r requirements.txt (line 2)) (1.2.3)
Requirement already satisfied: pyflakes<2.3.0,>=2.2.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.2.0)
Requirement already satisfied: mccabe<0.7.0,>=0.6.0 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (0.6.1)
Requirement already satisfied: pycodestyle<2.7.0,>=2.6.0a1 in /home/todd/.local/lib/python3.10/site-packages (from flake8==3.8.3->-r requirements.txt (line 3)) (2.6.0)
Requirement already satisfied: sphinxcontrib-applehelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: alabaster<0.8,>=0.7 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.7.12)
Requirement already satisfied: imagesize in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.3.0)
Requirement already satisfied: sphinxcontrib-htmlhelp>=2.0.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.0.0)
Requirement already satisfied: babel>=1.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.10.1)
Requirement already satisfied: requests>=2.5.0 in /usr/lib/python3/dist-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.25.1)
Requirement already satisfied: packaging in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (21.3)
Requirement already satisfied: sphinxcontrib-qthelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.3)
Requirement already satisfied: sphinxcontrib-serializinghtml>=1.1.5 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.1.5)
Requirement already satisfied: sphinxcontrib-devhelp in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.2)
Requirement already satisfied: Pygments>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.12.0)
Requirement already satisfied: Jinja2>=2.3 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (3.1.2)
Requirement already satisfied: snowballstemmer>=1.1 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.2.0)
Requirement already satisfied: docutils<0.18,>=0.14 in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (0.17.1)
Requirement already satisfied: sphinxcontrib-jsmath in /home/todd/.local/lib/python3.10/site-packages (from Sphinx>=4.0.2->-r requirements.txt (line 1)) (1.0.1)
Requirement already satisfied: pytz>=2015.7 in /usr/lib/python3/dist-packages (from babel>=1.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2022.1)
Requirement already satisfied: MarkupSafe>=2.0 in /home/todd/.local/lib/python3.10/site-packages (from Jinja2>=2.3->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.1.1)
Requirement already satisfied: pyparsing!=3.0.5,>=2.0.2 in /usr/lib/python3/dist-packages (from packaging->Sphinx>=4.0.2->-r requirements.txt (line 1)) (2.4.7)
Installing collected packages: isort, flake8, black, Sphinx
Successfully installed Sphinx-4.5.0 black-21.7b0 flake8-3.8.3 isort-4.3.21
>>> Building Java Cookbook <<<
cd java && make html
make[1]: Entering directory '/home/todd/arrow-cookbook/java'
Running Sphinx v4.5.0
WARNING: html_static_path entry '_static' does not exist
loading pickled environment... done
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 7 source files that are out of date
updating environment: 0 added, 0 changed, 0 removed
looking for now-outdated files... none found
preparing documents... done
writing output... [100%] schema
generating indices... genindex done
writing additional pages... search done
copying static files... done
copying extra files... done
dumping search index in English (code: en)... done
dumping object inventory... done
build succeeded, 1 warning.
The HTML pages are in build/html.
make[1]: Leaving directory '/home/todd/arrow-cookbook/java'
mkdir -p build/java
cp -r java/build/html/* build/java
```
I will update the PR to eliminate the reference to needing `sphinx-build` explicitly installed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org