question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unexpected key argument 'priority'

See original GitHub issue

I recently updated my jupyter book version and tried building a book and got the following error:

Exception occurred:
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/sphinx_external_toc/__init__.py", line 29, in setup
    app.connect("config-inited", parse_toc_to_env, priority=900)
TypeError: connect() got an unexpected keyword argument 'priority'
The full traceback has been saved in /tmp/sphinx-err-ttnt2_i9.log, if you want to report the issue to the developers.
Please also report this if it was a user error, so that a better error message can be provided next time.
A bug report can be filed in the tracker at <https://github.com/sphinx-doc/sphinx/issues>. Thanks!
Traceback (most recent call last):
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/jupyter_book/sphinx.py", line 128, in build_sphinx
    keep_going=keep_going,
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/sphinx/application.py", line 235, in __init__
    self.setup_extension(extension)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/sphinx/application.py", line 394, in setup_extension
    self.registry.load_extension(self, extname)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/sphinx/registry.py", line 484, in load_extension
    metadata = mod.setup(app)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/sphinx_external_toc/__init__.py", line 29, in setup
    app.connect("config-inited", parse_toc_to_env, priority=900)
TypeError: connect() got an unexpected keyword argument 'priority'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/tomas/anaconda3/envs/pisco/bin/jupyter-book", line 8, in <module>
    sys.exit(main())
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/click/core.py", line 1137, in __call__
    return self.main(*args, **kwargs)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/click/core.py", line 1062, in main
    rv = self.invoke(ctx)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/click/core.py", line 1668, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/click/core.py", line 763, in invoke
    return __callback(*args, **kwargs)
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/jupyter_book/cli/main.py", line 317, in build
    result, builder, OUTPUT_PATH, build_type, PAGE_NAME, click.echo
  File "/home/tomas/anaconda3/envs/pisco/lib/python3.6/site-packages/jupyter_book/cli/main.py", line 516, in builder_specific_actions
    raise RuntimeError(_message_box(msg, color="red", doprint=False)) from result
RuntimeError: 
===============================================================================

There was an error in building your book. Look above for the cause.

===============================================================================

Any idea what could be causing this?

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (3 by maintainers)

github_iconTop GitHub Comments

1reaction
temullercommented, Jul 20, 2021

yeah, the issue was the version of packages. I had to update them for the build to work (see chrisjsewell’s comment above).

0reactions
choldgrafcommented, Jul 20, 2021

Sounds good - I’m gonna close this one since I think it was resolved by updating the environment. Let me know if there’s still something to tackle

Read more comments on GitHub >

github_iconTop Results From Across the Web

Build Fails With TypeError: connect() got an unexpected ...
got an unexpected keyword argument 'priority' Exception occurred: File "/home/docs/checkouts/readthedocs.org/user_builds/stk/conda/debug/lib/ ...
Read more >
TypeError: max() got an unexpected keyword argument 'key'
Try: import builtins lis=[(101, 153), (255, 827), (361, 961)] from operator import itemgetter builtins.max(lis,key=itemgetter(1))[0].
Read more >
PyCharm: "Unexpected argument" error message is shown ...
PyCharm: "Unexpected argument" error message is shown when constructing a named tuple with json object_hook ; Priority, Normal N ; Type, Bug ;...
Read more >
unexpected-keyword-arg / E1123 - Pylint 2.16.0-dev ...
Description: Used when a function call passes a keyword argument that doesn't correspond to one of the function's parameter names. Problematic code:.
Read more >
TypeError: Got an unexpected keyword argument for ...
I'm using the admin directory_v1 API, via the python client wrapper. The code worked well for 18 months, and suddenly stopped working at ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found