Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-09-01 Thread Gonzalo Odiard
Hi Tony, This is a consequence of the issue pointed a few mails before in this thread: this tool is running in a separated process to Sugar. That in part explain the slowness. We are discussing ways to make this process notify to Sugar about the activity installed, making the process itself

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-09-01 Thread Tony Anderson
Hi, Gonzalo I am learning a lot about debugging Sugar that may be useful going forward. I tried enabling logging as below. However, I am not sure which log you are referring to. The only stdout was notice that the bundle was installed. Strangely, I did not get the normal unzip list of files.

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-31 Thread Martin Abente
The problem caused by the race condition is that the activities were not refreshed in Sugar activities list when updated or, not added to the list when installed. By race condition I mean the situation where the BundleRegistry detects changes (e.g. in ~/Activities) too early, when activity.info is

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-31 Thread Gonzalo Odiard
Is a good point. Maybe we should add a dbus method to register a bundle, and a method in the toolkit to do the call, then this script use that method. I didn't realized this before, because is included in the sugar module, but we should not use jarabe here. Gonzalo On Mon, Aug 31, 2015 at 2:03

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-31 Thread James Cameron
I agree, that might be good. An strace of sugar-bundle-install shows the huge amount of work required to start this other instance of the bundle registry, only to dismantle it on exit. Alternatively, if there were a method by which sugar-bundle-install could tell the shell that a new bundle has

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-31 Thread Gonzalo Odiard
I am wondering if this issue ca be related to the race condition detected by Martin when the file monitor detect the activity before the activity.info file is saved to disk. Martin, do you have a patch to test? Gonzalo On Mon, Aug 31, 2015 at 10:00 AM, Gonzalo Odiard wrote:

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-31 Thread Gonzalo Odiard
Tony, If you can enable logging (remove the comment in the line SUGAR_LOGGER_LEVEL in the file /home/olpc/.sugar/default/debug) And install one of the activities without unset the SUGAR_PROFILE env variable, and send the log, maybe we can understand better what is happening. I am afraid the

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-30 Thread James Cameron
G'day Sam, Adding a flag for a workaround seems like you've given up. ;-) Wouldn't it be better to fix the problem? As you can see from #4849 it occurs in Sugar, and only inside Terminal activity. Why is it happening? Why does it take up to 24 minutes to install Browse using Terminal? Why

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Tony Anderson
Hi, Sam P. The logs are not interesting, only the unzip list of files. The second test used time.time() in sugar-install-bundle. It is going through the bundle registry. There is an else option. Perhaps I should try the installs with that branch. Tony On 08/29/2015 12:17 PM, Sam P. wrote:

[Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Tony Anderson
I use sugar-install-bundle to update the configuration of Sugar activities when preparing laptops at deployments. With 13.2.5, this script is taking 3-4 times as long as with previous releases. I can only speculate on the difference in times since I have 13.2.5 on all the available XOs and

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Sam P.
Hi Tony, Do you have the logs of these installs? Is there anything in the logs? Looking back at the commit logs, the change in 0.104 was to use the bundle registry to install bundles if sugar is running [1]. Maybe that has done something or maybe it is a different change down the line!

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Tony Anderson
Hi, I reran the installs with SUGAR_PROFILE set to False. The install timings: Browse: 0.5 seconds Jukebox: 0.5 seconds Quiz: 0.8 seconds I'll just patch sugar-install-bundle not to use the SUGAR_PROFILE path. Thanks for the help. Tony On 08/29/2015 01:41 PM, James Cameron wrote: G'day

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Jerry Vonau
Hi Tony, I brought concerns about that change, with regards to OSbuilder but I guess that change is slowing down the console now. Have you tried TinyCore[1] that would boot without setting having SUGAR_PROFILE. I've used TinyCore to install activities in the past, checkout XO.custom in the

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread James Cameron
G'day Sam, My guess is #4849 again and our user hasn't unset the SUGAR_PROFILE environment variable as was suggested four months ago. I never heard closure on the suggestion, but as it was off-list I'm not surprised. The ticket shows how to reproduce in case you'd like to take a stab at it. --

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Sam P.
Hi Tony, Should we make disabling install via bundle registry (SUGAR_PROFILE) a flag? There are use cases when it makes sense to install via bundle registry (updating the activity list) so it is not good to outright disable it. Thanks, Sam On Sat, 29 Aug 2015 11:51 pm Tony Anderson

Re: [Sugar-devel] Sugar-install-bundle in 13.2.5 is slooow

2015-08-29 Thread Tony Anderson
Hi, Sam The script that installs these activities is run after flashing the laptop to provide the capabilities needed for the laptop to work with the school server. The goal is to have each laptop in the deployment with identical software. In this case, the script finishes by a poweroff