Scratch fails to write to Scratch.activity/Projects

Greg Smith gregsmitholpc at gmail.com
Wed Aug 27 07:25:53 EDT 2008


Hi Erik, John et al,

Scratch is hot in the field right now!

Kids are posting Scratch projects out of Uruguay and its been included 
in the teacher trainings in other countries too. One of the many great 
things about this application is that it posts directly to the Scratch 
web site. So its easy to share your work from the XO. Something that is 
not as easy as it should be outside Scratch.

The only downside I have found with Scratch accessing the file system 
directly is that people have not been able to move their Scratch 
projects to a USB stick. I think they are working around that by posting 
them to the Scratch site and pulling down from there but its still a 
problem for offline XOs or those with little BW.

In any case, I want to make sure Scratch it works in 8.2, at least as 
well as it did in 70x builds.

Does this fix below allow that? If it does, can we make sure to get that 
on the activities page and available to all?

On the bug system question, the main page is at:
http://dev.laptop.org/

Use the view tickets or new ticket links to get started.

Conventions for using the various fields are documented here:
http://wiki.laptop.org/go/Trac_conventions

Scratch is a phenomenon. It has traction with kids from Newton (e.g. my 
kids :-) to Montevideo and Port Au Prince. Thanks a lot for creating 
this super fun tool!

Thanks,

Greg S

*****************
Date: Tue, 26 Aug 2008 22:01:21 -0500 From: Erik Garrison 
<erik at laptop.org> Subject: Re: Scratch fails to write to 
Scratch.activity/Projects To: John Maloney <jmaloney at media.mit.edu> Cc: 
devel at lists.laptop.org Message-ID: <20080827030121.GA3153 at eggs> 
Content-Type: text/plain; charset=us-ascii On Tue, Aug 26, 2008 at 
08:40:34PM -0400, John Maloney wrote:
 > > Hi, Scott.
 > >
 > > What's wrong with just making the directory Scratch.activity/Projects
 > > writable by the world? Seems to me that it could not hurt other
 > > applications. Scratch does not run any binary files from that folder,
 > > so it should be pretty safe. At worse, some malicious software could
 > > write a bogus project file that Scratch would refuse to open.

I personally find this an acceptable solution.  However, in the present
moment we have our hands tied, as the olpc-configure script which runs
on first boot now chmod 755's all directories in /home/olpc.  This is
problematic when activity bundles are installed prior to the first boot,
as they are when we use a 'customization' usb key, as all directories
will lose the permissions set by the bundle creators.

Customization key description:
[http://wiki.laptop.org/go/Customization_key] Peru has moved to using
this method to install activities.  This is good for local system
customization, but it has caused this issue to rear its head.

 > > The Scratch activity used to install that way but I suppose something
 > > about the installation process has changed.

Specifically:
http://dev.laptop.org/git?p=projects/olpc-utils;a=blob;f=olpc-configure;h=0d6ef55ed49635672d63ae79831bff2a2eea4143;hb=db05cda6b8f36fe833bfa8a201d2b5467afbbd94#l138

This code is run once on first-boot.

 > > Is there a Wiki page that explains how to use the bug database?

Somewhat.  http://wiki.laptop.org/go/Trac

 > > Feel free to re-package the current Scratch activity installer to
 > > include your patch, if you think that makes sense.

I have taken the Scratch-6.xo which C. Scott initially provided and got
it to work on the XO as-is.  This involved dropping the wrapper code
mentioned in the ticket [http://dev.laptop.org/ticket/8166] and placing
it into Scratch.activity/bin/scratch-activity and symlinking the
Projects directory to /tmp/scratch.  A patch to the scratch-activity
script is attached to the ticket.  An activity bundle (with a lang=es
line in its Scratch.ini) is available at
[http://dev.laptop.org/~erik/activities/Scratch-6.es.xo].

Erik


 > > On Aug 26, 2008, at 6:36 PM, C. Scott Ananian wrote:
 >> > > In http://dev.laptop.org/ticket/8166 there's a problem reported: 
Peru
 >> > > can't save their work in Scratch, because Scratch tries to write to
 >> > > Scratch.activity/Projects, and this is not writable.  Luckily, there
 >> > > is an easy workaround: the directory $SUGAR_ACTIVITY_ROOT/data is
 >> > > persistent storage which is writable by the activity, and properly
 >> > > protected.  On the trac page I've also provided a patch which wraps
 >> > > Scratch so that it writes to the proper place.
 >> > >
 >> > > Tomeu also volunteered on IRC earlier today to help you implement
 >> > > proper Journal support for Scratch.
 >> > >
 >> > > Finally: there are a number of bugs filed against scratch in our bug
 >> > > tracker, but it doesn't appear to have a proper component and owner
 >> > > created for it in the tracker.  We'd like to fix that: do you have a
 >> > > username on the dev.laptop.org trac instance that we could make the
 >> > > default owner of bugs filed against 'scratch-activity' so that 
you are
 >> > > promptly notified if/when people have problems?
 >> > >
 >> > > Thanks for porting scratch, the kids in Peru seem to really like
 >> > > it.  ;-)
 >> > > --scott
 >> > >
 >> > > --
 >> > > ( http://cscott.net/ )
 > >
 > > _______________________________________________
 > > Devel mailing list
 > > Devel at lists.laptop.org
 > > http://lists.laptop.org/listinfo/devel




More information about the Devel mailing list