e-learning icon indicating copy to clipboard operation
e-learning copied to clipboard

Error building documentation

Open doublebyte1 opened this issue 2 years ago • 7 comments

I am getting this error on a new build of the repo with make ogc

Theme error:
An error happened in rendering the page cat/slides/exercise-metadata-object.
Reason: UndefinedError("'style' is undefined")
make: *** [ogc] Error 2
(e-learning)

I'm on python 3.82, mac 14.0; sphinx was built with pip install sphinx on a virtual python enviroment

@ghobona any ideas?

doublebyte1 avatar Oct 24 '23 13:10 doublebyte1

I’m able to build it on a MacOS Catalina v10.15 with: Python 2.7.16 and Sphinx 3.4.3. The environment also has Python 3.9.12 as well.

ghobona avatar Oct 24 '23 14:10 ghobona

Let me try it on an Ubuntu and get back to you shortly.

ghobona avatar Oct 24 '23 14:10 ghobona

thank you, @ghobona, But I was not on ubuntu : I was using Mac 14.0 (latest version)

I am on python3 and I suspect that could be the problem. I will try with python2. Thanks for the advice ! +1

doublebyte1 avatar Oct 24 '23 14:10 doublebyte1

@tomkralidis are you experiencing the same error?

doublebyte1 avatar Oct 24 '23 14:10 doublebyte1

@doublebyte It builds on Ubuntu but it does report an Error 2 (though different).

/e-learning/source/wms/slides/coordinates.rst:1: WARNING: Problems with "include" directive path:
InputError: [Errno 2] No such file or directory: 'source/wms/cover.rst'.

The environment is Sphynx 1.8.5; Ubuntu 20.04.1; Python 2.7.18; Python 3.8.10

Looking at the error message, the error is to do with the slides folder. The slides were actually never developed and are not linked to from the rest of the website. The long term plan was to remove the slides folders.

ghobona avatar Oct 24 '23 15:10 ghobona

@doublebyte It builds on Ubuntu but it does report an Error 2 (though different).

/e-learning/source/wms/slides/coordinates.rst:1: WARNING: Problems with "include" directive path:
InputError: [Errno 2] No such file or directory: 'source/wms/cover.rst'.

The environment is Sphynx 1.8.5; Ubuntu 20.04.1; Python 2.7.18; Python 3.8.10

Looking at the error message, the error is to do with the slides folder. The slides were actually never developed and are not linked to from the rest of the website. The long term plan was to remove the slides folders.

@ghobona thank you, but I am actually not using ubuntu

doublebyte1 avatar Oct 24 '23 15:10 doublebyte1

I'm getting the following:

(opengeospatial) tomkralidis@aruba:~/Dev/opengeospatial/e-learning$ make clean
rm -rf build/*
rm -rf ./docs
(opengeospatial) tomkralidis@aruba:~/Dev/opengeospatial/e-learning$ python3 --version
Python 3.7.12
(opengeospatial) tomkralidis@aruba:~/Dev/opengeospatial/e-learning$ sphinx-build  --version
sphinx-build 5.3.0
(opengeospatial) tomkralidis@aruba:~/Dev/opengeospatial/e-learning$ make ogc
rm -rf build/*
rm -rf ./docs	
sphinx-build -b html source build
Running Sphinx v5.3.0
loading pickled environment... done
building [mo]: targets for 0 po files that are out of date
building [html]: targets for 145 source files that are out of date
updating environment: 0 added, 2 changed, 0 removed
reading sources... [100%] ogcapi-processes/text/basic-index                                                                                                                                                
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/index.rst:33: WARNING: toctree contains reference to nonexisting document 'ogcapi-standards/index'
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/ogcapi-processes/text/basic-index.rst:15: WARNING: toctree contains reference to nonexisting document 'ogcapi-processes/text/operations'
looking for now-outdated files... none found
pickling environment... done
checking consistency... /Users/tomkralidis/Dev/opengeospatial/e-learning/source/cat/slides/exercise-metadata-object.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/cat/slides/exercise-opensearch.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/cat/slides/presentation.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/cat/slides/readme.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/fe/text/index.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/fundamental-concepts/slides/basic.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/fundamental-concepts/slides/exercise-interface-restaurant.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/fundamental-concepts/slides/lo.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/apps/gdal-ogr.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/apps/geopackage-java.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/apps/qgis.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/apps/sqlite.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/metadata.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/nonlinear_geometry_types.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/related_tables.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/rtree_spatial_indexes.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/schema.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/tiled_gridded_coverage_data.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/tiles_encoding_webp.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/wkt_for_crs.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/zoom_other_intervals.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/new/index.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/ogc-standards/slides/services-ogc.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/sld/slides/main.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/sld/text/presentation.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/sta/slides/presentation.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wfs/text/nsg-wfs.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/slides/coordinates.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/slides/exercise-abudhabi-wms.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/slides/exercise-explorelayer-nationalatlas.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/slides/exercise-metaspatial-uk.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/slides/presentation.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/text/index.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/text/wms_draft_not_included.rst: WARNING: document isn't included in any toctree
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wmts/text/api.rst: WARNING: document isn't included in any toctree
done
preparing documents... done
writing output... [100%] wps/text/towards-ogc-api-processes                                                                                                                                                
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/cat/slides/presentation.rst:386: WARNING: Could not lex literal_block as "xml". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/cat/slides/presentation.rst:452: WARNING: Could not lex literal_block as "xml". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/geopackage/text/extensions/tiled_gridded_coverage_data.rst:133: WARNING: Could not lex literal_block as "c". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/text/wms_draft_not_included.rst:55: WARNING: undefined label: 'wms_vendor_parameters'
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/text/wms_draft_not_included.rst:55: WARNING: undefined label: 'wms_global_variables'
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/text/wms_draft_not_included.rst:60: WARNING: Could not lex literal_block as "xml". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wms/text/wms_draft_not_included.rst:79: WARNING: Could not lex literal_block as "xml". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wmts/text/operations.rst:320: WARNING: Could not lex literal_block as "xml". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wmts/text/operations.rst:388: WARNING: Could not lex literal_block as "xml". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wmts/text/operations.rst:472: WARNING: Could not lex literal_block as "javascript". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wmts/text/operations.rst:487: WARNING: Could not lex literal_block as "json". Highlighting skipped.
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wps/text/towards-ogc-api-processes.rst:189: WARNING: Pygments lexer name 'txt' is not known
/Users/tomkralidis/Dev/opengeospatial/e-learning/source/wps/text/towards-ogc-api-processes.rst:326: WARNING: Could not lex literal_block as "json". Highlighting skipped.
generating indices... genindex done
writing additional pages... search done
copying images... [100%] wps/img/cfcheckerapi_3.png                                                                                                                                                        
copying static files... done
copying extra files... done
dumping search index in English (code: en)... done
dumping object inventory... done
build succeeded, 50 warnings.

The HTML pages are in build.
cp ./source/wmts/text/*.yaml ./build/wmts/text
cp -r ./source/wmts/text/target-api ./build/wmts/text
cp -r ./source/wmts/text/target-api-kvp ./build/wmts/text
mv ./build/_static ./build/static
mv ./build/_images ./build/images
python replacestatic.py
  File "replacestatic.py", line 10
    print filename
                 ^
SyntaxError: Missing parentheses in call to 'print'. Did you mean print(filename)?
make: *** [ogc] Error 1

Note that the above also results in 582 files deleted from version control.

tomkralidis avatar Oct 24 '23 15:10 tomkralidis