[Sugar-devel] Some thoughts on GetBooks activity

Chihurumnaya Ibiam ibiam at sugarlabs.org
Tue Mar 5 11:06:58 EST 2024


Agreed, activities depending on external APIs are difficult to maintain and
if anyone is willing to do it
then it can work.

-- 

Ibiam Chihurumnaya
ibiam at sugarlabs.org



On Tue, Mar 5, 2024 at 6:04 AM James Cameron <quozl at laptop.org> wrote:

> Yes, I remember some of this from when I last maintained those activities.
>
> I felt that activities that depended on external APIs become difficult to
> maintain.  ;-)
>
> On Mon, Mar 04, 2024 at 01:46:44PM -0600, James Simmons wrote:
> > Back in 2009 I wrote the Get IA Books activity which uses the Advanced
> Search
> > service of the Internet Archive to search their catalog and makes it
> possible
> > to download these books to the Journal and put some metadata in there as
> well.
> >
> > Shortly after I finished this Sayamindu Dasgupta made a similar Activity
> that
> > used OPDS to search book catalogs. Specifically he was interested in
> using OPDS
> > to search [1]https://www.feedbooks.com, which had an OPDS server that
> included
> > public domain books. He also made it possible for the Activity user to
> add an
> > entry for his own OPDS server, but you had to edit a text file using the
> > Terminal activity to do it.
> >
> > I have just fixed my own Activity to work with Python 3 and wanted to try
> > fixing this one too. I've run into a few problems which makes me think
> this
> > Activity might not be fixable.
> >
> > 1. Feedbooks.com is going out of business very soon. It is possible that
> their
> > OPDS server is already not working: [2]
> https://www.feedbooks.com/catalog/
> > public_domain
> > 2. There are other ODPS servers, but not for public domain titles:
> [3]http://
> > opdshome.uo1.net/
> > 3. The Internet Archive has an OPDS server but this Activity doesn't use
> it.
> > Instead it adapted code from my GetIABooks activity. Apparently the IA
> OPDS
> > server had issues when this was written.
> > 3. The Activity makes use of code from [4]http://feedparser.org/.
> > Unfortunately, the latest version of this cannot be contained in just
> one file.
> > The old version depends on sgmllib.py, which was included with Python 2
> but not
> > with 3. Somebody found the code for this and ran it through a Python 2
> to 3
> > converter. I added this to the project.
> > 4. I managed to convert enough code in feedparser.py and sgmllib.py to
> get the
> > Activity to run without generating diagnostic messages. I have no idea
> if it is
> > actually working.
> >
> > Thoughts?
> >
> > James Simmons
> >
> > References:
> >
> > [1] https://www.feedbooks.com/
> > [2] https://www.feedbooks.com/catalog/public_domain
> > [3] http://opdshome.uo1.net/
> > [4] http://feedparser.org/
>
> > _______________________________________________
> > Sugar-devel mailing list
> > Sugar-devel at lists.sugarlabs.org
> > http://lists.sugarlabs.org/listinfo/sugar-devel
>
> _______________________________________________
> Sugar-devel mailing list
> Sugar-devel at lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/sugar-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sugarlabs.org/archive/sugar-devel/attachments/20240305/0f0b44cf/attachment-0001.htm>


More information about the Sugar-devel mailing list