Last modified: 2014-06-20 15:29:55 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T68881, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 66881 - Import by filename is not supported
Import by filename is not supported
Status: RESOLVED FIXED
Product: Pywikibot
Classification: Unclassified
i18n (Other open bugs)
core-(2.0)
All All
: Immediate critical
: ---
Assigned To: Pywikipedia bugs
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-06-20 15:10 UTC by xqt
Modified: 2014-06-20 15:29 UTC (History)
1 user (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description xqt 2014-06-20 15:10:31 UTC
Scripts which are using i18n on Windows are broken:

Retrieving 1000 moved pages via API...
...........

>>> DOOM 4 <<<
   Links to: [[Doom (upcoming video game)]].
   Links to: [[Doom 4]].
Traceback (most recent call last):
  File "C:\pwb\core\pwb.py", line 143, in <module>
    run_python_file(fn, argv, argvu)
  File "C:\pwb\core\pwb.py", line 67, in run_python_file
    exec(compile(source, filename, "exec"), main_mod.__dict__)
  File "C:\pwb\core\scripts\redirect.py", line 823, in <module>
    main()
  File "C:\pwb\core\scripts\redirect.py", line 820, in main
    bot.run()
  File "C:\pwb\core\scripts\redirect.py", line 730, in run
    self.fix_double_redirects()
  File "C:\pwb\core\scripts\redirect.py", line 537, in fix_double_redirects
    self.fix_1_double_redirect(redir_name)
  File "C:\pwb\core\scripts\redirect.py", line 683, in fix_1_double_redirect
    {'to': targetPage.title(asLink=True)}
  File "C:\pwb\core\pywikibot\i18n.py", line 354, in twtranslate
    transdict = getattr(__import__(import_dir, fromlist=[package]), package).msg

ImportError: Import by filename is not supported.
<type 'exceptions.ImportError'>
CRITICAL: Waiting for 1 network thread(s) to finish. Press ctrl-c to abort

Microsoft Windows [Version 6.1.7601]
Copyright (c) 2009 Microsoft Corporation. Alle Rechte vorbehalten.

C:\Users\Administrator.KTC>cd ..

C:\Users>cd ..

C:\>cd pwb

C:\pwb>cd core

C:\pwb\core>pwb.py version
Pywikibot: pywikibot-core (f86097a, s4415, 2014/06/19, 22:34:52, ok)
Release version: 2.0b1
Python: 2.7.3 (default, Apr 10 2012, 23:24:47) [MSC v.1500 64 bit (AMD64)]
unicode test: ok

C:\pwb\core>
Comment 1 xqt 2014-06-20 15:29:55 UTC
fixed with revert https://gerrit.wikimedia.org/r/#/c/140923/

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links