mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-01-04 10:46:05 +01:00
Fix #4581 (WSJ not downloading fully) and fix invocation of embedded python interpreter via call to ipython not working because of command line arguments
This commit is contained in:
parent
b80cc18a30
commit
ebe8d7bce8
2 changed files with 4 additions and 1 deletions
|
|
@ -16,7 +16,7 @@ class WallStreetJournal(BasicNewsRecipe):
|
|||
needs_subscription = True
|
||||
language = 'en'
|
||||
|
||||
max_articles_per_feed = 25
|
||||
max_articles_per_feed = 1000
|
||||
timefmt = ' [%a, %b %d, %Y]'
|
||||
no_stylesheets = True
|
||||
|
||||
|
|
|
|||
|
|
@ -451,6 +451,8 @@ def prepare_string_for_xml(raw, attribute=False):
|
|||
traceback.print_exc()
|
||||
|
||||
def ipython(user_ns=None):
|
||||
old_argv = sys.argv
|
||||
sys.argv = ['ipython']
|
||||
if user_ns is None:
|
||||
user_ns = locals()
|
||||
from calibre.utils.config import config_dir
|
||||
|
|
@ -514,5 +516,6 @@ def main():
|
|||
from IPython.Shell import IPShellEmbed
|
||||
ipshell = IPShellEmbed(user_ns=user_ns)
|
||||
ipshell()
|
||||
sys.argv = old_argv
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue