max() arg is an empty sequence error in building book
See original GitHub issueWhen I try to build the demo book with:
jupyter-book create newbook/
And then build the book by:
jupyter-book build newbook
I receive the following output and error in the anaconda cmd window:
(wintest) C:\Users\laaltenburg>jupyter-book build newbook
Running Jupyter-Book v0.8.3
Traceback (most recent call last):
File "c:\users\laaltenburg\.conda\envs\wintest\lib\runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "c:\users\laaltenburg\.conda\envs\wintest\lib\runpy.py", line 85, in _run_code
exec(code, run_globals)
File "C:\Users\laaltenburg\.conda\envs\wintest\Scripts\jupyter-book.exe\__main__.py", line 7, in <module>
File "c:\users\laaltenburg\.conda\envs\wintest\lib\site-packages\click\core.py", line 829, in __call__
return self.main(*args, **kwargs)
File "c:\users\laaltenburg\.conda\envs\wintest\lib\site-packages\click\core.py", line 782, in main
rv = self.invoke(ctx)
File "c:\users\laaltenburg\.conda\envs\wintest\lib\site-packages\click\core.py", line 1259, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "c:\users\laaltenburg\.conda\envs\wintest\lib\site-packages\click\core.py", line 1066, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "c:\users\laaltenburg\.conda\envs\wintest\lib\site-packages\click\core.py", line 610, in invoke
return callback(*args, **kwargs)
File "c:\users\laaltenburg\.conda\envs\wintest\lib\site-packages\jupyter_book\commands\__init__.py", line 199, in build
build_modified = max([os.stat(ii).st_mtime for ii in build_files])
ValueError: max() arg is an empty sequence_
Something apparently is going wrong during the build, what could be the issue?
Thanks, Luuk
Issue Analytics
- State:
- Created 3 years ago
- Comments:20 (3 by maintainers)
Top Results From Across the Web
Python ValueError: max() arg is an empty sequence Solution
The “ValueError: max() arg is an empty sequence” error is raised when you try to find the largest item in an empty list...
Read more >ValueError: max() arg is an empty sequence - Stack Overflow
I've created a GUI using wxFormBuilder that should allow a user to enter the names of "visitors to a business" into a list...
Read more >ValueError: max( ) arg is an empty sequence - STechies
In this article, we will learn about the error ValueError: max( ) arg is an empty sequence. In python, the max( ) method...
Read more >Python's min() and max(): Find Smallest and Largest Values
Removing the Smallest and Largest Numbers in a List; Building Lists of ... ValueError: min() arg is an empty sequence >>> max([3, 5,...
Read more >How to Find the Longest String in a Python List? - Finxter
Solution: max() function with key function argument len(). Use Python's built-in max() function with a key argument to find the longest string in...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
wohoo! I am glad that https://github.com/executablebooks/jupyter-book/pull/1153 seems to have worked haha
lol I’m happy to have helped you @luukalt … now I have to understand why it works on my ubuntu virtual box, but on windows 10 it doesn’t 🤣 … I think that is python 3.9.0 or 3.8 that doesn’t work on my machine… i will try with python 3.7.9!
EDIT: OK IT WORKED FLAWLESSY THIS TIME!! I was right! Python 3.9.0 and Python 3.8.5 don’t work on windows 10 with jupyter book (at least on my machine…)
Step that I did to make Jupyter Book working on my pc:
Now from the terminal follow these steps:
pip install -U jupyter-book
pip uninstall sphinxcontrib-bibtex
pip install sphinxcontrib-bibtex==1.0.0
# build_modified = max([os.stat(ii).st_mtime for ii in build_files])
(comment this out with #)freshenv = True
(set this to True)cd (Go to a folder of your choiche)
jb create (Name of your choiche)
jb build (same name as before)
I wanted to thank all of you who helped me understand and solve the problem !!! @choldgraf @fcharih and @lewtun !!!