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.

ModuleNotFoundError: No module named 'numba.decorators'

See original GitHub issue

Describe the bug import librosa breaks on latest librosa and numba. Upstream dependency break

librosa==0.7.2 numba==0.50.0

To Reproduce

import librosa
.tox/s-py38/lib/python3.8/site-packages/librosa/util/utils.py:15: in <module>
    from .decorators import deprecated
.tox/s-py38/lib/python3.8/site-packages/librosa/util/decorators.py:9: in <module>
    from numba.decorators import jit as optional_jit
E   ModuleNotFoundError: No module named 'numba.decorators'

Workaround Pin numba in production

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:37
  • Comments:22 (5 by maintainers)

github_iconTop GitHub Comments

112reactions
yematacommented, Jun 12, 2020

pip install numba==0.48 seems like numba removed the decorators module with version 0.50. real fix would be pinning numba version in librosa requirements

31reactions
waffletowercommented, May 4, 2022

I am sorry, but we don’t have to waste time as often on careless breakage exactly like this in other ecosystems such Java, Erlang or Swift in my direct and broad experience. My do so many tolerate Python amateur hour? Why don’t Python developers understand the concept of pinning and downstream consequences? The amount of time wasted for countless developers for inconsiderate breakage like this is staggering.

https://docs.divio.com/en/latest/how-to/resources-pin-dependencies/

Read more comments on GitHub >

github_iconTop Results From Across the Web

Import librosa gives "no module named numba.decorators ...
You have to install numbra version 0.48 because of a bug, run pip install numba==0.48. Librosa Issue on Github.
Read more >
No module named 'numba.decorators' - Google Groups
As you can see, I do: pip install librosa -- python -- import librosa, but it's not happy. There's an error: ModuleNotFoundError: No...
Read more >
No module named 'numba.decorators' #1160 - YouTube
https://computerscienceassists.blogspot.com/2020/10/best-solution-for- modulenotfounderror.html.
Read more >
No module named numba.decorators错误解决 - CSDN博客
重新安装了anaconda 重新配置环境时遇到的记录下:librosa-0.7.2 与numba-0.50.0不符合导致的出错在import librosa时会出现No module named 'numba.
Read more >
numba.decorators — numba 0.8.0 documentation
numba.decorators¶ · Using the restype and argtypes arguments, passing Numba types. · By constructing a Numba function type and passing that as the...
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