-
Notifications
You must be signed in to change notification settings - Fork 391
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
cmake --build build/docs --target GenerateDocs
not working
#126
Comments
Do you have the dependencies Doxygen, jinja2 and Pygments installed on your system? |
I do have those installed, yes. |
I am having the same problem. When running Traceback (most recent call last):
File "/home/host/user/MyProject/build/doc/_deps/m.css-src/documentation/doxygen.py", line 47, in <module>
from jinja2 import Environment, FileSystemLoader
ModuleNotFoundError: No module named 'jinja2'
CMakeFiles/GenerateDocs.dir/build.make:70: recipe for target 'CMakeFiles/GenerateDocs' failed
make[3]: *** [CMakeFiles/GenerateDocs] Error 1
CMakeFiles/Makefile2:149: recipe for target 'CMakeFiles/GenerateDocs.dir/all' failed
make[2]: *** [CMakeFiles/GenerateDocs.dir/all] Error 2
CMakeFiles/Makefile2:156: recipe for target 'CMakeFiles/GenerateDocs.dir/rule' failed
make[1]: *** [CMakeFiles/GenerateDocs.dir/rule] Error 2
Makefile:170: recipe for target 'GenerateDocs' failed
make: *** [GenerateDocs] Error 2 However, if I manually launch from jinja2 import Environment, FileSystemLoader I don't get any error. |
Anyone else has the same error? I tried on multiple machines (and OS) with no luck. |
@giacomo-b could you run |
Hey @TheLartians thank you for replying. I tried, still no luck though: $ pip install jinja2 pygments
...
Successfully installed MarkupSafe-1.1.1 jinja2-2.11.3 pygments-2.5.2 $ cmake -S documentation -B build/doc
...
-- Build files have been written to: /PATH/build/doc $ cmake --build build/doc --target GenerateDocs
Traceback (most recent call last):
File "/PATH/build/doc/_deps/m.css-src/documentation/doxygen.py", line 3859, in <module>
run(state, templates=os.path.abspath(args.templates), wildcard=args.wildcard, index_pages=args.index_pages, search_merge_subtrees=not args.search_no_subtree_merging, search_add_lookahead_barriers=not args.search_no_lookahead_barriers, search_merge_prefixes=not args.search_no_prefix_merging)
File "/PATH/build/doc/_deps/m.css-src/documentation/doxygen.py", line 3688, in run
extract_metadata(state, file)
File "/PATH/build/doc/_deps/m.css-src/documentation/doxygen.py", line 2195, in extract_metadata
if compounddef.attrib['kind'] not in ['namespace', 'group', 'class', 'struct', 'union', 'dir', 'file', 'page']:
AttributeError: 'NoneType' object has no attribute 'attrib'
CMakeFiles/GenerateDocs.dir/build.make:70: recipe for target 'CMakeFiles/GenerateDocs' failed
make[3]: *** [CMakeFiles/GenerateDocs] Error 1
CMakeFiles/Makefile2:113: recipe for target 'CMakeFiles/GenerateDocs.dir/all' failed
make[2]: *** [CMakeFiles/GenerateDocs.dir/all] Error 2
CMakeFiles/Makefile2:120: recipe for target 'CMakeFiles/GenerateDocs.dir/rule' failed
make[1]: *** [CMakeFiles/GenerateDocs.dir/rule] Error 2
Makefile:170: recipe for target 'GenerateDocs' failed
make: *** [GenerateDocs] Error 2 |
Could you please check which python version is used: bash-3.2$ pip --version
pip 21.2.4 from /usr/local/lib/python3.9/site-packages/pip (python 3.9)
bash-3.2$ python2
WARNING: Python 2.7 is not recommended.
This version is included in macOS for compatibility with legacy software.
Future versions of macOS will not include Python 2.7.
Instead, it is recommended that you transition to using 'python3' from within Terminal.
Python 2.7.16 (default, Aug 30 2021, 14:43:11)
[GCC Apple LLVM 12.0.5 (clang-1205.0.19.59.6) [+internal-os, ptrauth-isa=deploy on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from jinja2 import Environment, FileSystemLoader
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: No module named jinja2
>>> |
oops! I got the same error, but note the bash-3.2$ pwd
/Users/clausklein/Workspace/cpp/ModernCppStarter
bash-3.2$ cmake --build build/doc --target GenerateDocs
Warning: libgs not found
warning: ignoring unsupported tag 'M_SHOW_UNDOCUMENTED' at line 31, file /Users/clausklein/Workspace/cpp/ModernCppStarter/build/doc/Doxyfile
Doxygen version used: 1.9.2
Searching for include files...
# ... And it is not possible for me to install Collecting libgs
Using cached libgs-1.1.tar.gz (270 kB)
Using cached libgs-0.11.tar.gz (272 kB)
ERROR: Cannot install libgs==0.11, libgs==1.1 and libgs==1.2.1 because these package versions have conflicting dependencies.
The conflict is caused by:
libgs 1.2.1 depends on pandas==0.21.0
libgs 1.1 depends on pandas==0.21.0
libgs 0.11 depends on pandas==0.21.0
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/user_guide/#fixing-conflicting-dependencies
bash-3.2$ |
I'm also having issues with generating documentation. When I run the I'm using Python 3.8 and also have
UpdateAfter further investigation, it seems I'm running into the same issue as @ClausKlein. I upgraded to python python.exe D:\Repositories\thread-pool\out\build\x64-Release\_deps\m.css-src\documentation\doxygen.py .\conf.py I then get the following output: Warning: libgs not found
warning: ignoring unsupported tag 'M_SHOW_UNDOCUMENTED' at line 31, file D:\Repositories\thread-pool\out\build\x64-Release\documentation\Doxyfile
Doxygen version used: 1.9.2 (caa4e3de211fbbef2c3adf58a6bd4c86d0eb7cb8)
// omitted for brevity
D:/Repositories/thread-pool/README.md:83: warning: unable to resolve reference to 'D:/Repositories/thread-pool/CONTRIBUTING.md' for \ref command
D:/Repositories/thread-pool/README.md:91: warning: Illegal command @DeveloperPaul123 as part of a <a>..</a> block
Running plantuml with JAVA...
lookup cache used 62/65536 hits=142 misses=62
finished...
Traceback (most recent call last):
File "D:\Repositories\thread-pool\out\build\x64-Release\_deps\m.css-src\documentation\doxygen.py", line 3859, in <module>
run(state, templates=os.path.abspath(args.templates), wildcard=args.wildcard, index_pages=args.index_pages, search_merge_subtrees=not args.search_no_subtree_merging, search_add_lookahead_barriers=not args.search_no_lookahead_barriers, search_merge_prefixes=not args.search_no_prefix_merging)
File "D:\Repositories\thread-pool\out\build\x64-Release\_deps\m.css-src\documentation\doxygen.py", line 3688, in run
extract_metadata(state, file)
File "D:\Repositories\thread-pool\out\build\x64-Release\_deps\m.css-src\documentation\doxygen.py", line 2195, in extract_metadata
if compounddef.attrib['kind'] not in ['namespace', 'group', 'class', 'struct', 'union', 'dir', 'file', 'page']:
AttributeError: 'NoneType' object has no attribute 'attrib' I too run into issues when trying to install Collecting libgs
Using cached libgs-1.1.tar.gz (270 kB)
Preparing metadata (setup.py) ... done
Using cached libgs-0.11.tar.gz (272 kB)
Preparing metadata (setup.py) ... done
ERROR: Cannot install libgs==0.11, libgs==1.1 and libgs==1.2.1 because these package versions have conflicting dependencies.
The conflict is caused by:
libgs 1.2.1 depends on pandas==0.21.0
libgs 1.1 depends on pandas==0.21.0
libgs 0.11 depends on pandas==0.21.0
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
ERROR: ResolutionImpossible: for help visit https://pip.pypa.io/en/latest/user_guide/#fixing-conflicting-dependencies |
Hm that's strange, it could be that there is some conflict with different versions of python packages installed. Maybe you could try installing the dependencies in a virtual environment? |
Possibly, but I stopped pursuing this and instead used an alternative doxygen theme. |
I get exactly the same error. Has anyone been able to solve it? Python 3.10.2 jinja2 and pygments are installed |
I found a fix: It looks like
to:
|
currently m.css commit hash will cause errors found in issue #126. Updating to the latest has fixes these problems correct hash
Has this issue now been resolved? |
Mine is already the same, fresh install
Getting the same error as everyone else. Latest pip, python 3.9 etc. |
I would prefer to only use stable tags for used packages. |
Doxygen should pinned down their dependencies, a freely-executing doxygen.py not within a stipulated Python environment is a recipe for trouble. |
Happens on both Ubuntu WSL and Windows:
The text was updated successfully, but these errors were encountered: