You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@arrow.apache.org by we...@apache.org on 2016/12/09 16:39:56 UTC

arrow git commit: ARROW-346: Use conda environment to build API docs

Repository: arrow
Updated Branches:
  refs/heads/master e139b8b7c -> a5362c2cb


ARROW-346: Use conda environment to build API docs

As we cannot currently build pyarrow on readthedocs, we have to resort
to building the API docs for the latest version of pyarrow on
conda-forge. All other documentation will though be pulled directly from
the source code.

Author: Uwe L. Korn <uw...@xhochy.com>

Closes #228 from xhochy/ARROW-346 and squashes the following commits:

6a4bdc1 [Uwe L. Korn] Add license header
b741141 [Uwe L. Korn] ARROW-346: Use conda environment to build API docs


Project: http://git-wip-us.apache.org/repos/asf/arrow/repo
Commit: http://git-wip-us.apache.org/repos/asf/arrow/commit/a5362c2c
Tree: http://git-wip-us.apache.org/repos/asf/arrow/tree/a5362c2c
Diff: http://git-wip-us.apache.org/repos/asf/arrow/diff/a5362c2c

Branch: refs/heads/master
Commit: a5362c2cbed5f32a468d93d23c8365c9c5528b03
Parents: e139b8b
Author: Uwe L. Korn <uw...@xhochy.com>
Authored: Fri Dec 9 11:39:49 2016 -0500
Committer: Wes McKinney <we...@twosigma.com>
Committed: Fri Dec 9 11:39:49 2016 -0500

----------------------------------------------------------------------
 .readthedocs.yml           |  2 ++
 python/doc/conf.py         |  7 ++++++-
 python/doc/environment.yml | 25 +++++++++++++++++++++++++
 3 files changed, 33 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/arrow/blob/a5362c2c/.readthedocs.yml
----------------------------------------------------------------------
diff --git a/.readthedocs.yml b/.readthedocs.yml
new file mode 100644
index 0000000..2e1fe3f
--- /dev/null
+++ b/.readthedocs.yml
@@ -0,0 +1,2 @@
+conda:
+    file: python/doc/environment.yml

http://git-wip-us.apache.org/repos/asf/arrow/blob/a5362c2c/python/doc/conf.py
----------------------------------------------------------------------
diff --git a/python/doc/conf.py b/python/doc/conf.py
index 4c324a8..e817bbd 100644
--- a/python/doc/conf.py
+++ b/python/doc/conf.py
@@ -42,7 +42,12 @@ cmd_line_template = "sphinx-apidoc -f -e -o {outputdir} {moduledir}"
 cmd_line = cmd_line_template.format(outputdir=output_dir, moduledir=module_dir)
 apidoc.main(cmd_line.split(" "))
 
-sys.path.insert(0, os.path.abspath('..'))
+on_rtd = os.environ.get('READTHEDOCS') == 'True'
+
+if not on_rtd:
+    # Hack: On RTD we use the pyarrow package from conda-forge as we cannot
+    # build pyarrow there.
+    sys.path.insert(0, os.path.abspath('..'))
 
 # -- General configuration ------------------------------------------------
 

http://git-wip-us.apache.org/repos/asf/arrow/blob/a5362c2c/python/doc/environment.yml
----------------------------------------------------------------------
diff --git a/python/doc/environment.yml b/python/doc/environment.yml
new file mode 100644
index 0000000..8d1fe9b
--- /dev/null
+++ b/python/doc/environment.yml
@@ -0,0 +1,25 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements.  See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership.  The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License.  You may obtain a copy of the License at
+#
+#   http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied.  See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+channels:
+- defaults
+- conda-forge
+dependencies:
+- arrow-cpp
+- parquet-cpp
+- pyarrow
+- numpydoc