[Sugar-devel] Journal Implementation Help

Benjamin M. Schwartz bmschwar at fas.harvard.edu
Tue Jun 15 12:41:21 EDT 2010


On 06/15/2010 12:37 PM, Quoc-Bao Vuong wrote:
>     * What is the proper way to write the write_file() and read_file()
> methods for a sugar activity. I've seen two ways (using metadata and
> writing/reading into files), but I'm not sure what works best for this
> type of situation.

Either way is acceptable.  I would say "do what is easiest".  In your
case, since you are just storing a handful of string values, I would use
the metadata system.

As for your other questions, I recommend using the debug logging system to
ensure that read_file() is being called and is setting variables to their
correct stored values.  If that is working, then the problem is elsewhere
in your code (and hence is specific to the IRC activity).

--Ben

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: OpenPGP digital signature
Url : http://lists.sugarlabs.org/archive/sugar-devel/attachments/20100615/99d266a5/attachment.pgp 


More information about the Sugar-devel mailing list