-
Notifications
You must be signed in to change notification settings - Fork 69
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
mnamer crashed #289
Comments
I have same issue with python version 3.12.1. |
Hi,
Interestingly, this happens only with few episode files, not with all. I don't see a pattern yet. And it doesn't matter if language is set to null or to "de". |
Additional input: I don't know why, but it seems to relate to the filename, because I just had the same problem and was able to circumvent it by renaming the file in question:
Fix it by removing the episode description from the filename: Result:
|
The problemThe exception occurs because the guessit module used by mnamer identifies some words in the title as language indicators and tries to convert them. This produces a crash with an exception. Workaround approachYou can replace the target.py file in mnamer with the fixed version of mine. This change will be overwritten with the next update, but hopefully it will be fixed then. Steps for workaround approach
|
=======================
--------------------------------- environment ----------------------------------
--------------------------------- stack trace ----------------------------------
Traceback (most recent call last):
File "/usr/local/lib/python3.11/dist-packages/mnamer/main.py", line 22, in main
frontend = Cli(settings)
^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/mnamer/frontends.py", line 68, in init
super().init(settings)
File "/usr/local/lib/python3.11/dist-packages/mnamer/frontends.py", line 24, in init
self.targets = Target.populate_paths(self.settings)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/mnamer/target.py", line 66, in populate_paths
targets = [cls(file_path, settings) for file_path in
file_paths]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/mnamer/target.py", line 66, in
targets = [cls(file_path, settings) for file_path in
file_paths]
^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/mnamer/target.py", line 49, in init
self._parse(file_path)
File "/usr/local/lib/python3.11/dist-packages/mnamer/target.py", line 167, in _parse
self.metadata.language = path_data.get("language")
^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/mnamer/metadata.py", line 177, in setattr
super().setattr(key, value)
File "/usr/local/lib/python3.11/dist-packages/mnamer/metadata.py", line 69, in setattr
value = converter(value)
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/mnamer/language.py", line 63, in parse
raise MnamerException("Could not determine language")mnamer.exceptions.MnamerException: Could not determine language
=============================== CRASH REPORT END ===============================
The text was updated successfully, but these errors were encountered: