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

linkchecker can't find localization files #728

Closed
florianjacob opened this issue Aug 7, 2017 · 3 comments
Closed

linkchecker can't find localization files #728

florianjacob opened this issue Aug 7, 2017 · 3 comments

Comments

@florianjacob
Copy link
Contributor

florianjacob commented Aug 7, 2017

When I call linkchecker on the command line, it exits before doing anything with this error message on trying to access its localization files:

$> linkchecker
Traceback (most recent call last):
  File "/usr/bin/linkchecker", line 30, in <module>
    import linkcheck
  File "/usr/lib/python2.7/site-packages/linkcheck/__init__.py", line 137, in <module>
    init_i18n()
  File "/usr/lib/python2.7/site-packages/linkcheck/__init__.py", line 124, in init_i18n
    i18n.init(configdata.name.lower(), locdir, loc=loc)
  File "/usr/lib/python2.7/site-packages/linkcheck/i18n.py", line 94, in init
    install_language(default_language)
  File "/usr/lib/python2.7/site-packages/linkcheck/i18n.py", line 100, in install_language
    languages=[get_lang(language)], fallback=True)
  File "/usr/lib/python2.7/site-packages/linkcheck/i18n.py", line 110, in get_translator
    languages=languages, class_=translatorklass, fallback=fallback)
  File "/usr/lib/python2.7/gettext.py", line 553, in translation
    with open(mofile, 'rb') as fp:
IOError: [Errno 21] Is a directory: u'/usr/share/locale/de/LC_MESSAGES/linkchecker.mo'

The problem seems to be in the directory structure created by setup.py:

/usr/share/locale/
├── fr/
│   └── LC_MESSAGES/
│       └── linkchecker.mo/
│           └── fr.mo
├── es/
│   └── LC_MESSAGES/
│       └── linkchecker.mo/
│           └── es.mo
└── de/
    └── LC_MESSAGES/
        └── linkchecker.mo/
            └── de.mo

I assume the lowest level of the tree is created accidentally, but I did not understand what causes this behaviour. Workaround is to start linkchecker with LC_ALL=C.

version: linkchecker 9.4 from AUR
python 2.7
setuptools 36.2.7-1

@steffsson
Copy link

I have the same Problem, also installed linkchecker and linkchecker-gui from AUR.
Solved it temporarily by moving /usr/share/locale/de/LC_MESSAGES/linkchecker.mo/de.mo to /usr/share/locale/de/LC_MESSAGES/linkchecker.mo.

@dpalic
Copy link

dpalic commented Oct 29, 2017

Thank you for the issue report. Sadly this project is dead, and a new team is around with https://github.com/linkcheck/linkchecker
for more details please see: #708
Also please close this issue and report it freshly on the new repo https://github.com/linkcheck/linkchecker/issues

@florianjacob
Copy link
Contributor Author

@dpalic thanks for the hint! Closing this here now.

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

3 participants