Xqt added subscribers: jayvdb, valhallasw.
Xqt added a comment.

After d3cd1f4e9 the circular import has been solved and behavior is a bit different. Previously you had to pass allways through the pwb.py wrapper (if pwb is not installed as a side package) including the shell or idle:

>>> import pywkibot
Traceback (most recent call last):
  File "<pyshell#0>", line 1, in <module>
    import pywkibot
ImportError: No module named pywkibot
>>>

and it was the reason why that shell.py script was shipped with the framework.

Now it doesn't seem necessary anymore:

>>> import pywikibot as py
>>>

and i don't see any difference to the direct shell command like py -2 -i:

>>> import pywikibot as py
>>>

It could be a good idea to pre-import pywikibot with shell.py but on the other hand @jayvdb said in 09ed829

However the more common case is the user wants to be able to
use pywikibot command line arguments, and pre-load the pywikibot library.

I guess we could also implement the opposite side: load the pywikibot library as default except an additional option (-noimport for example) is given.


TASK DETAIL
https://phabricator.wikimedia.org/T194456

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Xqt
Cc: valhallasw, jayvdb, Xqt, Aklapper, pywikibot-bugs-list, Dvorapa, Magul, Tbscho, MayS, Mdupont, JJMC89, Avicennasis, Dalba, Masti, Alchimista, Rxy
_______________________________________________
pywikibot-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/pywikibot-bugs

Reply via email to