Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Simmons <james@olpc.simmons>2013-02-15 00:22:29 (GMT)
committer James Simmons <james@olpc.simmons>2013-02-15 00:22:29 (GMT)
commitc04331ffbebbbccd601a0ecb3ba07cb19eda9eff (patch)
treea365b83e7bfb587d6783fff560e581cd815bcbbc
parent80ed781c8824748b31ddbc329bf854b8603b9d57 (diff)
modified: ReadEtextsActivity.py
modified: ausextract.py modified: gutextract.py modified: help.txt Fix problem with user agent string that prevented us from downloading PG books.
-rw-r--r--ReadEtextsActivity.py7
-rwxr-xr-x[-rw-r--r--]ausextract.py0
-rwxr-xr-x[-rw-r--r--]gutextract.py0
-rw-r--r--help.txt2
4 files changed, 7 insertions, 2 deletions
diff --git a/ReadEtextsActivity.py b/ReadEtextsActivity.py
index 73ae863..38b5f43 100644
--- a/ReadEtextsActivity.py
+++ b/ReadEtextsActivity.py
@@ -26,7 +26,7 @@ from gi.repository import Gdk
from sugar3.graphics import style
from sugar3 import profile
from sugar3.activity import activity
-from sugar3 import network
+# from sugar3 import network
from sugar3.datastore import datastore
from sugar3.graphics.alert import NotifyAlert
from sugar3.graphics.toolbarbox import ToolbarBox
@@ -49,6 +49,7 @@ import speech
import xopower
import rtfconvert
import pgconvert
+import network
PAGE_SIZE = 38
TOOLBAR_READ = 2
@@ -58,6 +59,7 @@ COLUMN_AUTHOR = 1
COLUMN_PATH = 2
logger = logging.getLogger('read-etexts-activity')
+logger.setLevel(logging.DEBUG)
class Annotations():
@@ -1173,12 +1175,15 @@ class ReadEtextsActivity(activity.Activity):
self.books_toolbar.enable_button(False)
self.list_scroller.props.sensitive = False
if self.selected_path.startswith('PGA'):
+ logger.debug(self.selected_path.replace('PGA', 'http://gutenberg.net.au'))
GObject.idle_add(self.download_book, self.selected_path.replace('PGA', 'http://gutenberg.net.au'), \
self.get_book_result_cb)
elif self.selected_path.startswith('/etext'):
+ logger.debug("http://www.knowledgerush.com/gutenberg/" + self.selected_path + "108.zip")
GObject.idle_add(self.download_book, "http://www.gutenberg.org/dirs" + self.selected_path + "108.zip", \
self.get_old_book_result_cb)
else:
+ logger.debug("http://www.knowledgerush.com/gutenberg/" + self.selected_path + "-8.zip")
GObject.idle_add(self.download_book, "http://www.gutenberg.org/dirs" + self.selected_path + "-8.zip", \
self.get_iso_book_result_cb)
diff --git a/ausextract.py b/ausextract.py
index 24adfad..24adfad 100644..100755
--- a/ausextract.py
+++ b/ausextract.py
diff --git a/gutextract.py b/gutextract.py
index adcc452..adcc452 100644..100755
--- a/gutextract.py
+++ b/gutextract.py
diff --git a/help.txt b/help.txt
index 9ed1a4f..1094df0 100644
--- a/help.txt
+++ b/help.txt
@@ -2,7 +2,7 @@
"Outside of a dog, a book is man's best friend. Inside of a dog it's too dark to read." -- Groucho Marx
-The Books button or tab above will let you search through the offline catalog of Project Gutenberg, an Internet repository of free etexts featuring books in many languages. The catalog used contains 28,595 titles from Project Gutenberg and Project Gutenberg Australia. The catalog is current as of January 29, 2009. For titles added after that date you should visit http://www.gutenberg.org.
+The Books button above will let you search through the offline catalog of Project Gutenberg, an Internet repository of free etexts featuring books in many languages. The catalog used contains 28,595 titles from Project Gutenberg and Project Gutenberg Australia. The catalog is current as of February 10, 2013. For titles added after that date you should visit http://www.gutenberg.org.
To find a book, type one or more words that would be in the author's name or the title, then press Enter. The list will only include books that match all the words, so use fewer words to make the list longer and more words to shorten the list. If an author goes by his initials (like H.G. Wells, P.G. Wodehouse, or E.E. Smith) you may need to try both the initials and the complete first name to get every title available. If you use a well known author's name like "Shakespeare" you will get titles both by and about him.