Re: [Sugar-devel] GetBooks Offline Support

2016-08-01 Thread Ütkarsh Tiwari
Hi,
I have finally added the 'Gutenberg Collection' support to GetBooks
activity. Refer the gif links below for UI demonstrations.

Gif 1-  The offline downloaded 'Gutenberg' collection is in the form of
.html files which would be read in 'Browse' activity after download. For
that you need to add 'text/html' mime_type to your 'Browse' activity.info file.
-> http://imgur.com/a/833K9

Gif 2- The offline downloaded 'Rachel' book collection is in .pdf format
which would be read in 'Read' activity after download. The mime_type is
pre-set. -> http://imgur.com/a/b7vtc

Regards,
Utkarsh Tiwari



On Mon, Jul 18, 2016 at 9:24 PM, Tony Anderson 
wrote:

> Hi, Utkarsh
>
> I don't have the activity in front of me. How is this done for the
> Gutenberg on-line collection?
>
> Tony
>
> On 07/18/2016 04:43 PM, Ütkarsh Tiwari wrote:
>
> Hi,
> Both the collections have their own 'index.html' files which are
> hyperlinked to the book collections inside them. The main problem here is
> figuring out how to make those 'index.html' files show up in the GetBooks
> and parse them to generate a list of the collection in the list view of
> 'GetBooks'.
>
> Regards,
> Ütkarsh Tiwari
>
> On Mon, Jul 18, 2016 at 10:47 AM, Tony Anderson 
> wrote:
>
>> Hi, Utkarsh
>>
>> I am not sure what you have downloaded. The two urls I gave you for
>> Rachel should have downloaded pdfs (CK-12) and txt (Adventures). The
>> gutenberg collection on xsce is in the form of a set of zim files which
>> even compressed are too large for a reasonable download. The previous IIAB
>> version was even larger. The zim version has two copies of each book: one
>> is html and the other epub (a compressed form of html).
>>
>> You should do what the activity does now with downloads. You are only
>> changing the source. So your problem may be to access the urls from your
>> hard drive.
>> One option is to use a localhost. This is very simple in python. See, for
>> example,
>> http://www.linuxjournal.com/content/tech-tip-really-simple-http-server-python
>> .
>>
>> Tony
>>
>>
>> On 07/17/2016 10:07 PM, Ütkarsh Tiwari wrote:
>>
>>> Hi,
>>> I have downloaded the 'Gutenberg' and 'Rachel' book collections onto
>>> my hard disk.
>>>
>>> For 'Gutenberg' collection - The books seem to be in the form of
>>> webpages.
>>> For 'Rachel' collection - The books are in the pdf form.
>>>
>>> Could you please provide me a hint on how to render both the collections
>>> in 'GetBooks Activity' since it currently fetches the books from the online
>>> urls added to it's config .cfg file. ?
>>>
>>> --
>>> Regards,
>>> Ütkarsh Tiwari
>>>
>>>
>>>
>>>
>>
>
>
> --
> Regards,
> Ütkarsh Tiwari
>
>
>
>
>


-- 
Regards,
Ütkarsh Tiwari
___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Tony Anderson

Hi, Gonzalo

It may require a separate interface for direct html urls.

Tony

On 07/19/2016 03:16 PM, Gonzalo Odiard wrote:

Yes. GetBooks feedparser understand OPDS.
Will not understand html.

Gonzalo

On Tue, Jul 19, 2016 at 10:08 AM, Tony Anderson > wrote:


Hi, Gonzalo

From the code, GetBooks uses feedparser. Pathagar is a server
while GetBooks is a client. In this case, Utkarsh is delivering
the content by html. I think more testing is needed to see where
the problem might be.

Thanks for your help,

Tony


On 07/19/2016 01:13 PM, Gonzalo Odiard wrote:

GetBooks get the list and the books using the OPDS protocol.
Pathagar [1] is a book server who serves that protocol, and is
(or was) included in the school server.
Pathagar has tools to import a directory of books in his own
database,
looks like you need work in the schoolserver to include Rachel
and gutemberg books
in Pathagar.
Then you only need add a new server in get-books.cfg

Gonzalo

[1] https://github.com/PathagarBooks/pathagar

On Tue, Jul 19, 2016 at 6:50 AM, Ütkarsh Tiwari
>
wrote:

Hi,
   I created a folder in my home directory by the name
*'server'* , put all the extracted book collections inside it
and start a localhost server with *'python -m
SimpleHTTPServer'* .
I then added that bookcollection url ( in my case it was -
*http://127.0.0.1:8000/server/en-ck12/index.htmlf*) to one of
the already available book genres in *get-books.cfg* .

On clicking that genre I get this error message - '*There was
an error downloading the list*.'

Regards,
Utkarsh Tiwari

On Tue, Jul 19, 2016 at 2:50 PM, Tony Anderson
> wrote:

Hi, Utkarsh

I am not sure what question you are asking.

Looking at the code: the repositories seem to be defined
in get-books.cfg.

The actual mechanics of accessing the network appears to
be handled by 'feedparse', which is a python module
described at
https://pythonhosted.org/feedparser/introduction.html.

What are you trying to do and what is your problem with
it? Did you add a repository to get-books.cfg? DId it
show up as you expected in the
toolbar widget? What happens if you select it? Does it
show the catalogs you entered? What happens if you select
a catalog? Does it show a list of books?
What happens when you click on a book - does it get
downloaded to the Journal?

My suggestion is to add Rachel as an online repository
getting the books from its site as a first step. Once
that is working, changing the urls to local should be
easier to test since you would already know what to
expect.

http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html
is the site for Gutenberg. Each of the links on that page
could be a catalog. Then clicking on one to show the list
of books in the right panel.

Tony


On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:

Hi,
I am working on this feature of adding offline
support to GetBooks activity to allow users to connect
to schoolservers for offline books(stored on these
servers) support. I am not able to figure out what
modifications I need to make in the parsing technique of
the activity in order to fetch(probably via localhost
server) the books from Gutenberg, Rachel collections
which I have already downloaded onto my harddisk.

Could anyone here please point me in the right direction?

-- 
Regards,

Ütkarsh Tiwari





___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel



___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel




-- 
Regards,

Ütkarsh Tiwari




___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel




-- 
photo 	


Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Gonzalo Odiard
Yes. GetBooks feedparser understand OPDS.
Will not understand html.

Gonzalo

On Tue, Jul 19, 2016 at 10:08 AM, Tony Anderson 
wrote:

> Hi, Gonzalo
>
> From the code, GetBooks uses feedparser. Pathagar is a server while
> GetBooks is a client. In this case, Utkarsh is delivering the content by
> html. I think more testing is needed to see where the problem might be.
>
> Thanks for your help,
>
> Tony
>
>
> On 07/19/2016 01:13 PM, Gonzalo Odiard wrote:
>
> GetBooks get the list and the books using the OPDS protocol.
> Pathagar [1] is a book server who serves that protocol, and is (or was)
> included in the school server.
> Pathagar has tools to import a directory of books in his own database,
> looks like you need work in the schoolserver to include Rachel and
> gutemberg books
> in Pathagar.
> Then you only need add a new server in get-books.cfg
>
> Gonzalo
>
> [1] https://github.com/PathagarBooks/pathagar
>
> On Tue, Jul 19, 2016 at 6:50 AM, Ütkarsh Tiwari <
> iamutkarshtiw...@gmail.com> wrote:
>
>> Hi,
>>I created a folder in my home directory by the name *'server'* , put
>> all the extracted book collections inside it and start a localhost server
>> with *'python -m SimpleHTTPServer'* .
>> I then added that bookcollection url ( in my case it was - 
>> *http://127.0.0.1:8000/server/en-ck12/index.htmlf
>> *) to one of the
>> already available book genres in *get-books.cfg* .
>>
>> On clicking that genre I get this error message - '*There was an error
>> downloading the list*.'
>>
>> Regards,
>> Utkarsh Tiwari
>>
>> On Tue, Jul 19, 2016 at 2:50 PM, Tony Anderson < 
>> tony_ander...@usa.net> wrote:
>>
>>> Hi, Utkarsh
>>>
>>> I am not sure what question you are asking.
>>>
>>> Looking at the code: the repositories seem to be defined in
>>> get-books.cfg.
>>>
>>> The actual mechanics of accessing the network appears to be handled by
>>> 'feedparse', which is a python module described at
>>> https://pythonhosted.org/feedparser/introduction.html.
>>>
>>> What are you trying to do and what is your problem with it? Did you add
>>> a repository to get-books.cfg? DId it show up as you expected in the
>>> toolbar widget? What happens if you select it? Does it show the catalogs
>>> you entered? What happens if you select a catalog? Does it show a list of
>>> books?
>>> What happens when you click on a book - does it get downloaded to the
>>> Journal?
>>>
>>> My suggestion is to add Rachel as an online repository getting the books
>>> from its site as a first step. Once that is working, changing the urls to
>>> local should be easier to test since you would already know what to expect.
>>> 
>>> http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html
>>> is the site for Gutenberg. Each of the links on that page could be a
>>> catalog. Then clicking on one to show the list of books in the right panel.
>>>
>>> Tony
>>>
>>>
>>> On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:
>>>
>>> Hi,
>>> I am working on this feature of adding offline support to GetBooks
>>> activity to allow users to connect to schoolservers for offline
>>> books(stored on these servers) support. I am not able to figure out what
>>> modifications I need to make in the parsing technique of the activity in
>>> order to fetch(probably via localhost server) the books from Gutenberg,
>>> Rachel collections which I have already downloaded onto my harddisk.
>>>
>>> Could anyone here please point me in the right direction?
>>>
>>> --
>>> Regards,
>>> Ütkarsh Tiwari
>>>
>>>
>>>
>>>
>>>
>>> ___
>>> Sugar-devel mailing 
>>> listSugar-devel@lists.sugarlabs.orghttp://lists.sugarlabs.org/listinfo/sugar-devel
>>>
>>>
>>>
>>> ___
>>> Sugar-devel mailing list
>>> Sugar-devel@lists.sugarlabs.org
>>> http://lists.sugarlabs.org/listinfo/sugar-devel
>>>
>>>
>>
>>
>> --
>> Regards,
>> Ütkarsh Tiwari
>>
>>
>>
>>
>> ___
>> Sugar-devel mailing list
>> Sugar-devel@lists.sugarlabs.org
>> http://lists.sugarlabs.org/listinfo/sugar-devel
>>
>>
>
>
> --
> [image: photo]
> *Gonzalo Odiard*
> Lider de proyecto
> tel.:  2081-6424 y 2082-0312 |  
> www.trinom.ioAv Calchaqui 4936· 2do Piso. Quilmes
> 
> 
>
>
>
> ___
> Sugar-devel mailing 
> listSugar-devel@lists.sugarlabs.orghttp://lists.sugarlabs.org/listinfo/sugar-devel
>
>
>
> ___
> Sugar-devel mailing list
> Sugar-devel@lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/sugar-devel
>
>


-- 
[image: photo]
*Gonzalo Odiard*
Lider de proyecto
tel.:  2081-6424 y 2082-0312 | 

Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Tony Anderson

Hi, Gonzalo

From the code, GetBooks uses feedparser. Pathagar is a server while 
GetBooks is a client. In this case, Utkarsh is delivering the content by 
html. I think more testing is needed to see where the problem might be.


Thanks for your help,

Tony

On 07/19/2016 01:13 PM, Gonzalo Odiard wrote:

GetBooks get the list and the books using the OPDS protocol.
Pathagar [1] is a book server who serves that protocol, and is (or 
was) included in the school server.

Pathagar has tools to import a directory of books in his own database,
looks like you need work in the schoolserver to include Rachel and 
gutemberg books

in Pathagar.
Then you only need add a new server in get-books.cfg

Gonzalo

[1] https://github.com/PathagarBooks/pathagar

On Tue, Jul 19, 2016 at 6:50 AM, Ütkarsh Tiwari 
> wrote:


Hi,
   I created a folder in my home directory by the name *'server'*
, put all the extracted book collections inside it and start a
localhost server with *'python -m SimpleHTTPServer'* .
I then added that bookcollection url ( in my case it was -
*http://127.0.0.1:8000/server/en-ck12/index.htmlf*) to one of the
already available book genres in *get-books.cfg* .

On clicking that genre I get this error message - '*There was an
error downloading the list*.'

Regards,
Utkarsh Tiwari

On Tue, Jul 19, 2016 at 2:50 PM, Tony Anderson
> wrote:

Hi, Utkarsh

I am not sure what question you are asking.

Looking at the code: the repositories seem to be defined in
get-books.cfg.

The actual mechanics of accessing the network appears to be
handled by 'feedparse', which is a python module described at
https://pythonhosted.org/feedparser/introduction.html.

What are you trying to do and what is your problem with it?
Did you add a repository to get-books.cfg? DId it show up as
you expected in the
toolbar widget? What happens if you select it? Does it show
the catalogs you entered? What happens if you select a
catalog? Does it show a list of books?
What happens when you click on a book - does it get downloaded
to the Journal?

My suggestion is to add Rachel as an online repository getting
the books from its site as a first step. Once that is working,
changing the urls to local should be easier to test since you
would already know what to expect.

http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html
is the site for Gutenberg. Each of the links on that page
could be a catalog. Then clicking on one to show the list of
books in the right panel.

Tony


On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:

Hi,
I am working on this feature of adding offline support to
GetBooks activity to allow users to connect to schoolservers
for offline books(stored on these servers) support. I am not
able to figure out what modifications I need to make in the
parsing technique of the activity in order to fetch(probably
via localhost server) the books from Gutenberg, Rachel
collections which I have already downloaded onto my harddisk.

Could anyone here please point me in the right direction?

-- 
Regards,

Ütkarsh Tiwari





___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel



___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel




-- 
Regards,

Ütkarsh Tiwari




___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel




--
photo   

*Gonzalo Odiard*
Lider de proyecto
tel.: 2081-6424 y 2082-0312 | www.trinom.io 
Av Calchaqui 4936· 2do Piso. Quilmes
 





___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Tony Anderson

Hi, Utkarsh

First, I would test the server. Put a simple index.html file in the 
server/ directory:





test


TEST



See that this displays in your browser at

http://127.0.0.1:8000/server/index.html

This will ensure the directory permissions are ok that the html server 
is working.


If that is ok, then the error message. Usually, I grep for something 
like 'error downloading' to see where the error message originates.


I assume that the get-books.cfg shows the collection in the combobox on 
the toolbar and that clicking on that shows the categories you have 
defined.


By the way: I assume htmlf is a typo. Also you are probably running 
SimpleHTTPServer in a command line window. This window should show any 
error messages. Since the base code is python, you can also add print 
statements which will appear in the window (stdout).


Tony

On 07/19/2016 11:50 AM, Ütkarsh Tiwari wrote:

Hi,
   I created a folder in my home directory by the name *'server'* , 
put all the extracted book collections inside it and start a localhost 
server with *'python -m SimpleHTTPServer'* .
I then added that bookcollection url ( in my case it was - 
*http://127.0.0.1:8000/server/en-ck12/index.htmlf*) to one of the 
already available book genres in *get-books.cfg* .


On clicking that genre I get this error message - '*There was an error 
downloading the list*.'


Regards,
Utkarsh Tiwari

On Tue, Jul 19, 2016 at 2:50 PM, Tony Anderson > wrote:


Hi, Utkarsh

I am not sure what question you are asking.

Looking at the code: the repositories seem to be defined in
get-books.cfg.

The actual mechanics of accessing the network appears to be
handled by 'feedparse', which is a python module described at
https://pythonhosted.org/feedparser/introduction.html.

What are you trying to do and what is your problem with it? Did
you add a repository to get-books.cfg? DId it show up as you
expected in the
toolbar widget? What happens if you select it? Does it show the
catalogs you entered? What happens if you select a catalog? Does
it show a list of books?
What happens when you click on a book - does it get downloaded to
the Journal?

My suggestion is to add Rachel as an online repository getting the
books from its site as a first step. Once that is working,
changing the urls to local should be easier to test since you
would already know what to expect.
http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html
is the site for Gutenberg. Each of the links on that page could be
a catalog. Then clicking on one to show the list of books in the
right panel.

Tony


On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:

Hi,
I am working on this feature of adding offline support to
GetBooks activity to allow users to connect to schoolservers for
offline books(stored on these servers) support. I am not able to
figure out what modifications I need to make in the parsing
technique of the activity in order to fetch(probably via
localhost server) the books from Gutenberg, Rachel collections
which I have already downloaded onto my harddisk.

Could anyone here please point me in the right direction?

-- 
Regards,

Ütkarsh Tiwari





___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel



___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org

http://lists.sugarlabs.org/listinfo/sugar-devel




--
Regards,
Ütkarsh Tiwari





___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Gonzalo Odiard
GetBooks get the list and the books using the OPDS protocol.
Pathagar [1] is a book server who serves that protocol, and is (or was)
included in the school server.
Pathagar has tools to import a directory of books in his own database,
looks like you need work in the schoolserver to include Rachel and
gutemberg books
in Pathagar.
Then you only need add a new server in get-books.cfg

Gonzalo

[1] https://github.com/PathagarBooks/pathagar

On Tue, Jul 19, 2016 at 6:50 AM, Ütkarsh Tiwari 
wrote:

> Hi,
>I created a folder in my home directory by the name *'server'* , put
> all the extracted book collections inside it and start a localhost server
> with *'python -m SimpleHTTPServer'* .
> I then added that bookcollection url ( in my case it was - 
> *http://127.0.0.1:8000/server/en-ck12/index.htmlf
> *) to one of the
> already available book genres in *get-books.cfg* .
>
> On clicking that genre I get this error message - '*There was an error
> downloading the list*.'
>
> Regards,
> Utkarsh Tiwari
>
> On Tue, Jul 19, 2016 at 2:50 PM, Tony Anderson 
> wrote:
>
>> Hi, Utkarsh
>>
>> I am not sure what question you are asking.
>>
>> Looking at the code: the repositories seem to be defined in get-books.cfg.
>>
>> The actual mechanics of accessing the network appears to be handled by
>> 'feedparse', which is a python module described at
>> https://pythonhosted.org/feedparser/introduction.html.
>>
>> What are you trying to do and what is your problem with it? Did you add a
>> repository to get-books.cfg? DId it show up as you expected in the
>> toolbar widget? What happens if you select it? Does it show the catalogs
>> you entered? What happens if you select a catalog? Does it show a list of
>> books?
>> What happens when you click on a book - does it get downloaded to the
>> Journal?
>>
>> My suggestion is to add Rachel as an online repository getting the books
>> from its site as a first step. Once that is working, changing the urls to
>> local should be easier to test since you would already know what to expect.
>> http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html
>> is the site for Gutenberg. Each of the links on that page could be a
>> catalog. Then clicking on one to show the list of books in the right panel.
>>
>> Tony
>>
>>
>> On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:
>>
>> Hi,
>> I am working on this feature of adding offline support to GetBooks
>> activity to allow users to connect to schoolservers for offline
>> books(stored on these servers) support. I am not able to figure out what
>> modifications I need to make in the parsing technique of the activity in
>> order to fetch(probably via localhost server) the books from Gutenberg,
>> Rachel collections which I have already downloaded onto my harddisk.
>>
>> Could anyone here please point me in the right direction?
>>
>> --
>> Regards,
>> Ütkarsh Tiwari
>>
>>
>>
>>
>>
>> ___
>> Sugar-devel mailing 
>> listSugar-devel@lists.sugarlabs.orghttp://lists.sugarlabs.org/listinfo/sugar-devel
>>
>>
>>
>> ___
>> Sugar-devel mailing list
>> Sugar-devel@lists.sugarlabs.org
>> http://lists.sugarlabs.org/listinfo/sugar-devel
>>
>>
>
>
> --
> Regards,
> Ütkarsh Tiwari
>
>
>
>
> ___
> Sugar-devel mailing list
> Sugar-devel@lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/sugar-devel
>
>


-- 
[image: photo]
*Gonzalo Odiard*
Lider de proyecto
tel.:  2081-6424 y 2082-0312 | www.trinom.ioAv
Calchaqui 4936· 2do Piso. Quilmes


___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Ütkarsh Tiwari
Hi,
   I created a folder in my home directory by the name *'server'* , put all
the extracted book collections inside it and start a localhost server
with *'python
-m SimpleHTTPServer'* .
I then added that bookcollection url ( in my case it was -
*http://127.0.0.1:8000/server/en-ck12/index.htmlf
*) to one of the already
available book genres in *get-books.cfg* .

On clicking that genre I get this error message - '*There was an error
downloading the list*.'

Regards,
Utkarsh Tiwari

On Tue, Jul 19, 2016 at 2:50 PM, Tony Anderson 
wrote:

> Hi, Utkarsh
>
> I am not sure what question you are asking.
>
> Looking at the code: the repositories seem to be defined in get-books.cfg.
>
> The actual mechanics of accessing the network appears to be handled by
> 'feedparse', which is a python module described at
> https://pythonhosted.org/feedparser/introduction.html.
>
> What are you trying to do and what is your problem with it? Did you add a
> repository to get-books.cfg? DId it show up as you expected in the
> toolbar widget? What happens if you select it? Does it show the catalogs
> you entered? What happens if you select a catalog? Does it show a list of
> books?
> What happens when you click on a book - does it get downloaded to the
> Journal?
>
> My suggestion is to add Rachel as an online repository getting the books
> from its site as a first step. Once that is working, changing the urls to
> local should be easier to test since you would already know what to expect.
> http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html
> is the site for Gutenberg. Each of the links on that page could be a
> catalog. Then clicking on one to show the list of books in the right panel.
>
> Tony
>
>
> On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:
>
> Hi,
> I am working on this feature of adding offline support to GetBooks
> activity to allow users to connect to schoolservers for offline
> books(stored on these servers) support. I am not able to figure out what
> modifications I need to make in the parsing technique of the activity in
> order to fetch(probably via localhost server) the books from Gutenberg,
> Rachel collections which I have already downloaded onto my harddisk.
>
> Could anyone here please point me in the right direction?
>
> --
> Regards,
> Ütkarsh Tiwari
>
>
>
>
>
> ___
> Sugar-devel mailing 
> listSugar-devel@lists.sugarlabs.orghttp://lists.sugarlabs.org/listinfo/sugar-devel
>
>
>
> ___
> Sugar-devel mailing list
> Sugar-devel@lists.sugarlabs.org
> http://lists.sugarlabs.org/listinfo/sugar-devel
>
>


-- 
Regards,
Ütkarsh Tiwari
___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] GetBooks Offline Support

2016-07-19 Thread Tony Anderson

Hi, Utkarsh

I am not sure what question you are asking.

Looking at the code: the repositories seem to be defined in get-books.cfg.

The actual mechanics of accessing the network appears to be handled by 
'feedparse', which is a python module described at

https://pythonhosted.org/feedparser/introduction.html.

What are you trying to do and what is your problem with it? Did you add 
a repository to get-books.cfg? DId it show up as you expected in the
toolbar widget? What happens if you select it? Does it show the catalogs 
you entered? What happens if you select a catalog? Does it show a list 
of books?
What happens when you click on a book - does it get downloaded to the 
Journal?


My suggestion is to add Rachel as an online repository getting the books 
from its site as a first step. Once that is working, changing the urls 
to local should be easier to test since you would already know what to 
expect. 
http://rachelfriends.org/previews/rachelplus/modules/en-ebooks/index.html is 
the site for Gutenberg. Each of the links on that page could be a 
catalog. Then clicking on one to show the list of books in the right panel.


Tony

On 07/19/2016 08:23 AM, Ütkarsh Tiwari wrote:

Hi,
I am working on this feature of adding offline support to GetBooks 
activity to allow users to connect to schoolservers for offline 
books(stored on these servers) support. I am not able to figure out 
what modifications I need to make in the parsing technique of the 
activity in order to fetch(probably via localhost server) the books 
from Gutenberg, Rachel collections which I have already downloaded 
onto my harddisk.


Could anyone here please point me in the right direction?

--
Regards,
Ütkarsh Tiwari





___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel