Skip to content
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

Using isort in CudaText plugin, got error #2375

Open
Alexey-T opened this issue Feb 27, 2025 · 0 comments
Open

Using isort in CudaText plugin, got error #2375

Alexey-T opened this issue Feb 27, 2025 · 0 comments

Comments

@Alexey-T
Copy link

Alexey-T commented Feb 27, 2025

I used 'isort' in this CudaText plugin: https://github.com/cudatext-addons/cuda_lint_pylint

I had to make a change to _version.py

# from importlib import metadata

# __version__ = metadata.version("isort")
__version__ = '6.0.1'

It is very simple fix. If I dont do it, I get error while using CudaText plugin under Windows x64 Python 3.12.9 (on linting some py file);

...
Traceback (most recent call last):
  File "importlib\metadata\__init__.py", line 397, in from_name
StopIteration

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "C:\CudaText\py\cuda_lint_pylint\pylint\utils\utils.py", line 8, in <module>
    import isort.api
  File "C:\CudaText\py\cuda_lint_pylint\isort\__init__.py", line 23, in <module>
    from ._version import __version__
  File "C:\CudaText\py\cuda_lint_pylint\isort\_version.py", line 3, in <module>
    __version__ = metadata.version("isort")
                  ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "importlib\metadata\__init__.py", line 889, in version
  File "importlib\metadata\__init__.py", line 862, in distribution
  File "importlib\metadata\__init__.py", line 399, in from_name
importlib.metadata.PackageNotFoundError: No package metadata was found for isort



Is isort OK here?
I use last version from PyPI.org. other python libs are also last from today.
I use embedded Windows Python (in python312.dll).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant