Re: [Sugar-devel] [PATCH v3 sugar] Pulsing icon delayed by 5 seconds or so SL#2080

2010-10-08 Thread Sascha Silbe
Excerpts from Anurag Chowdhury's message of Thu Oct 07 22:14:23 +0200 2010:

 Sorry , in that case , as I misunderstood the meaning of the tag
 Reviewed-by and will keep this fact in my mind while making future
 patches and will certainly remove your name from the reviewed by tag
 of this patch in its next version.
 Once again my apologies for the matter.

Don't worry. Creating high quality patches for software like Sugar is a
steep learning curve so mistakes are expected.

I would however recommend taking some time to learn Python basics first.
Pippy is supposed to be very nice for that and has an improved set of
examples now IIRC.

Sascha

--
http://sascha.silbe.org/
http://www.infra-silbe.de/


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


Re: [Sugar-devel] Memory leak in Sugar -- how to dump Py data structures?

2010-10-08 Thread Tomeu Vizoso
On Thu, Oct 7, 2010 at 22:01, Tim McNamara paperl...@timmcnamara.co.nz wrote:
 On 8 October 2010 03:34, Martin Langhoff martin.langh...@gmail.com wrote:

 See http://dev.laptop.org/ticket/10386 for details. The sugar-session
 process in 10.1.2 grows slowly...

 There's some form of leak somewhere. Maybe we are triggerin a real
 python leak, maybe we have reference loops. How do we trace this?

 This post seems pretty good [1]. It cites a tool that creates an object
 graph that visually represents what is happening in memory.[2]

 [1] http://www.lshift.net/blog/2008/11/14/tracing-python-memory-leaks
 [2] http://mg.pov.lt/blog/python-object-graphs.html

Those are good links, in this case I suspect those icons, or any other
object referenced inside a cycle that also contains an AP icon, are
listening for a signal in a longer-lived object, which prevents the
whole cycle to be freed. We need to either disconnect from that signal
when the icon is no longer needed, or use a weak reference.

I will be looking at a similar issue in the next few days but in 0.90,
I will know by then.

Regards,

Tomeu

 ___
 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] changes in trac and others

2010-10-08 Thread Tomeu Vizoso
On Mon, Oct 4, 2010 at 19:49, Sascha Silbe
sascha-ml-reply-to-201...@silbe.org wrote:
 Excerpts from Frederick Grose's message of Mon Oct 04 18:09:18 +0200 2010:

 The SEETA Developer: field might better be adjusted to Developer:, and we
 could use a convention to tag the developer's name, such as, [SEETA] Ishan

 What would be the difference between Owner and Developer then?

My guess is that Seeta wants to track which of their developers may
work in a particular issue in the future, without actually taking
ownership of the issue. I interpret being the owner as I'm working on
this right now, so if you start working on it we may end up doing
duplicated work.

In any case, I think Seeta needs to explain what their intention was
with this change, and the other organizations that are as well putting
people to work on Sugar tickets are also welcome to do the same.

Regards,

Tomeu

 Sascha

 --
 http://sascha.silbe.org/
 http://www.infra-silbe.de/

 ___
 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] Trac: added 1.0 milestone

2010-10-08 Thread Tomeu Vizoso
On Mon, Oct 4, 2010 at 14:10, Sascha Silbe
sascha-ml-reply-to-201...@silbe.org wrote:
 Hi!

 I just added a 1.0 milestone to Trac and used it for a ticket. The
 intended meaning is we should change (or at least look at) this before
 we declare the API 'stable' (whatever that means ;) ). If anyone has
 a better name for that milestone we can rename it.

Why a milestone and not a tag? The meaning we have been giving to
milestones doesn't seem to be exactly that.

Regards,

Tomeu

 Similarly, if we
 decided to call the next release (that would be 0.92) 1.0 because of
 the API break Gnome forced on us, we can rename it to 2.0.
 It's only meant to be used for things that affect API, especially
 activity API.

 Sascha

 --
 http://sascha.silbe.org/
 http://www.infra-silbe.de/

 ___
 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


[Sugar-devel] [PATCH] Updated translated word when language to translate is changed. (Ticket #2210)

2010-10-08 Thread Ishan Bansal
From: Ishan Bansal is...@seeta.in,Anubhav Aggarwal anub...@seeta.in

New global variable 'newtotranslate' added to update the translated text when
the language to translate is being changed.
---
 pippy_app.py |4 
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/pippy_app.py b/pippy_app.py
index b9a5a25..771e810 100644
--- a/pippy_app.py
+++ b/pippy_app.py
@@ -151,6 +151,8 @@ class WordsActivity(ViewSourceActivity):
 
 def lang2combo_cb(self, combo):
 self.languagemodel.SetLanguages(English, 
self.langs[combo.get_active()])
+self.translated.set_text()
+self.totranslate_cb(newtotranslate)
 
 def lang1sel_cb(self, column):
 # FIXME: Complete the text entry box
@@ -176,7 +178,9 @@ class WordsActivity(ViewSourceActivity):
 self.say(text, lang)
 
 def totranslate_cb(self, totranslate):
+global newtotranslate
 entry = totranslate.get_text()
+newtotranslate = totranslate
 # Ask for completion suggestions
 if not entry:
 return
-- 
1.7.0.4

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


Re: [Sugar-devel] Ticket no #2210 words don't changed when language is changed

2010-10-08 Thread Simon Schampijer

Hi David,

thanks for those words.

On 10/07/2010 08:08 PM, David Farning wrote:

On Thu, Oct 7, 2010 at 1:54 AM, Ishan Bansalis...@seeta.in  wrote:

Hi

I am working on the ticket http://bugs.sugarlabs.org/ticket/2210.

To solve the above bug i am thinking of clearing the text in the text to be
translate box when ever the language to be translated is being changed.
Please provide suggestion on any better approach to deal with this bug.


Over the last month this list has seen a significant increase in
requests for pointers.

Asking questions is an healthy part of learning, but asking for
'pointers' is _not_ going to be particularly helpful.  It shifts the
effort to the person answering the question rather then the person
asking the question.  Effectively asking questions is an art.  Asking
question is so important that Eric Raymond, author of the Cathedral
and the Bazaar, has written and maintained an article about how to ask
questions the smart way at
http://www.catb.org/esr/faqs/smart-questions.html .


+1 This article is more than worth a read. It helps you to understand at 
least the complexity of the issue. Then, the rest is applying.



I strongly suggest reading the article.  The time spent learning how
to ask questions the smart way... and asking questions the smart way
will pay for itself very quickly.  Questions asked the smart way will
generally get quicker responses and better answers.

Two additional points
  -- If you are new to the list please clearly describe 1) What you
know, 2) What you don't know, 3) and what you think you have to learn
to solve your problem.  This provides the person answering the
question a sense of scope. The answer someone provides is based on the
knowledge and needs for the person asking the question.

-- Answer as many questions as you ask.


This is a very good point. Those that have progressed already can help 
the others by applying the things they have learned. Especially when it 
comes to reviewing newcomer patches I hope the senior developers can 
skip the first rounds as they are already handled by other knowledgeable 
developers.


Regards,
   Simon



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


Re: [Sugar-devel] changes in trac and others

2010-10-08 Thread Simon Schampijer

On 10/04/2010 07:31 PM, Daniel Drake wrote:

On 4 October 2010 17:09, Frederick Grosefgr...@gmail.com  wrote:

The SEETA Developer: field might better be adjusted to Developer:, and we
could use a convention to tag the developer's name, such as, [SEETA] Ishan


On a community level, I don't think its right to assign a specific
developer to the task. Anyone is welcome to come along and post a
patch.

If SEETA want to add their internal metadata to the tickets they
should use the keywords field. e.g. add keyword seetadev:Ishan

Daniel


+1, I think using key words works quite ok. I have been handling it the 
same way with OLPC-tickets. And people can put themselves in cc when 
they are interested in a bug.


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


Re: [Sugar-devel] Alt-tab key does not work in F14 and sugar-emulator #2300

2010-10-08 Thread Bernie Innocenti
On Thu, 2010-10-07 at 09:52 +0200, Simon Schampijer wrote:
 Hi Sascha,
 
 thanks for your comments.
 
 On 10/06/2010 03:38 PM, Sascha Silbe wrote:
  Excerpts from Simon Schampijer's message of Wed Oct 06 15:21:29 +0200 2010:
 
  I have been bumping into [1] [...]
 
  Just to avoid confusion: This has nothing to do with how you run Sugar
  (i.e. it will occur both with sugar-emulator and running Sugar as a
  regular desktop session). It is (according to Bernie - I didn't quite
  grok the code) a bug in some versions of Xorg and will appear on some
  distro versions, independent of how you installed Sugar (native distro
  packages or sugar-jhbuild).
 
  It's supposed to be fixed (haven't checked myself yet) in recent Xorg
  versions. Bernie has also written a patch that lets metacity work around
  the bug. With that patch applied, metacity-message disable-keybindings
  works fine again.
 
 Bernie can you give some light on the issue in Xorg and where it has 
 been fixed, if?

For those tuning in just now, the testcase we're trying to fix is
getting Metacity to effectively release keys such as Alt-TAB when
someone executes metacity-message disable-keybindings from the
command-line.

This Metacity patch fixed the problem for me on Fedora 11:

  
http://people.sugarlabs.org/bernie/patches/gnome/metacity/pending/ungrab-x-keybindings-when-they-are-disabled.patch

It works by making Metacity ungrab each key individually rather than
trying to ungrab them all at once with XUngrabKey(AnyKey, AnyModifier),
which does not seem to work as advertised in the manpage.


 Right, best would be of course to get the Xorg fix in distros. Bernie 
 might have made the metacity workaround with a good reason, though. 
 Let's see, I hope Bernie can point us to the Xorg issue.

I thought the problem had been fixed in the X server by recent commits
to dix/grabs.c:DeletePassiveGrabFromList(), but apparently it's still
there. Now I'm a little confused, because ungrabbing seems to work on at
least some systems. I'm not sure which particular combinations of X
server and Metacity can trigger it.

These are the suspected functions, we still have no incriminating
evidence to declare one them them definitely guilty:

  http://cgit.freedesktop.org/xorg/xserver/tree/dix/grabs.c#n417
  http://git.gnome.org/browse/metacity/tree/src/core/keybindings.c#n737

Perhaps Peter or Owen can shred some light?

-- 
   // Bernie Innocenti - http://codewiz.org/
 \X/  Sugar Labs   - http://sugarlabs.org/


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


Re: [Sugar-devel] how to ask a question

2010-10-08 Thread Bernie Innocenti
On Thu, 2010-10-07 at 14:32 -0500, David Farning wrote:
 On Thu, Oct 7, 2010 at 2:21 PM, Tomeu Vizoso to...@sugarlabs.org wrote:
  On Thu, Oct 7, 2010 at 20:08, David Farning dfarn...@gmail.com wrote:
  On Thu, Oct 7, 2010 at 1:54 AM, Ishan Bansal is...@seeta.in wrote:
  Hi
 
  I am working on the ticket http://bugs.sugarlabs.org/ticket/2210.
 
  To solve the above bug i am thinking of clearing the text in the text to 
  be
  translate box when ever the language to be translated is being changed.
  Please provide suggestion on any better approach to deal with this bug.
 
  Over the last month this list has seen a significant increase in
  requests for pointers.
 
  Asking questions is an healthy part of learning, but asking for
  'pointers' is _not_ going to be particularly helpful.  It shifts the
  effort to the person answering the question rather then the person
  asking the question.  Effectively asking questions is an art.  Asking
  question is so important that Eric Raymond, author of the Cathedral
  and the Bazaar, has written and maintained an article about how to ask
  questions the smart way at
  http://www.catb.org/esr/faqs/smart-questions.html .
 
  I strongly suggest reading the article.  The time spent learning how
  to ask questions the smart way... and asking questions the smart way
  will pay for itself very quickly.  Questions asked the smart way will
  generally get quicker responses and better answers.
 
  Two additional points
   -- If you are new to the list please clearly describe 1) What you
  know, 2) What you don't know, 3) and what you think you have to learn
  to solve your problem.  This provides the person answering the
  question a sense of scope.
 
  This is very well put, lately I have felt like I would need to explain
  most I know about software engineering in order to give an useful
  reply.
 
 And if anyone feels dumb expressing what they don't know. Please
 note that I just committed one of the biggest mistakes in mailing list
 manners:(  I hijacked this thread without reseting the subject.We
 all make mistakes and we all get peer reviewed.

Besides all the above, to which I  agree, we seem to have also the
opposite problem: a lot of people in our community are afraid to ask
questions on public mailing lists -- no matter how dumb or smart.

It's not a language problem or a technical problem, it's really a
cultural problem. I think there are a number of different factors:

1) Introversion: a lot of good engineers are naturally shy

2) Public image: employees and contractors may be afraid their posts
could compromise the image of their organization

3) NDA: some engineers may be explicitly forbidden by their organization
to talk publicly about their job

4) Social fear: sometimes people respond aggressively or sarcastically
to newcomers who aren't familiar with the netiquette.

5) Force of habit: when they know who can answer a question, people
often forget to cc the mailing list.

6) Unawareness: grasping why public communication is so crucial in a
FLOSS community may time some time to developers who have been working
in proprietary shops.


As a result, this list has over 500 subscribers and only a tiny fraction
of them have ever posted to it. Every day, I get plenty of questions by
email and irc that could have been posted publicly. I bet the same is
true for other Sugar/OLPC veterans.

When this happens, we should gently encourage them to prefer public
communication. I reserve the stronger signals -- such as refusing to
answer the question until it's posted publicly -- for those who are
repeatedly ignoring this advice. I'm not running a free technical
support line.

-- 
   // Bernie Innocenti - http://codewiz.org/
 \X/  Sugar Labs   - http://sugarlabs.org/

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


Re: [Sugar-devel] changes in trac and others

2010-10-08 Thread Sascha Silbe
Excerpts from Tomeu Vizoso's message of Fri Oct 08 10:01:37 +0200 2010:

  The SEETA Developer: field might better be adjusted to Developer:, and we
  could use a convention to tag the developer's name, such as, [SEETA] Ishan
 
  What would be the difference between Owner and Developer then?
 
 My guess is that Seeta wants to track which of their developers may
 work in a particular issue in the future, without actually taking
 ownership of the issue. I interpret being the owner as I'm working on
 this right now, so if you start working on it we may end up doing
 duplicated work.

That's how I interpret it as well. But then a single Developer field
(which would supposedly only take a single value) wouldn't work as
other organisations might want to assign one of their developers.

 In any case, I think Seeta needs to explain what their intention was
 with this change, and the other organizations that are as well putting
 people to work on Sugar tickets are also welcome to do the same.

+1 on both counts

Sascha

--
http://sascha.silbe.org/
http://www.infra-silbe.de/


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


[Sugar-devel] Call for test requests

2010-10-08 Thread Tim McNamara
Does anyone have anything specific that they would like looked over this
weekend? If so, please add it to NZ's test request page [1].

Ta, Tim.

[1] http://wiki.laptop.org/go/OLPC_New_Zealand/Test_Requests
___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] [PATCH] Updated translated word when language to translate is changed. (Ticket #2210)

2010-10-08 Thread Sascha Silbe
Excerpts from Ishan Bansal's message of Fri Oct 08 10:08:46 +0200 2010:

 From: Ishan Bansal is...@seeta.in,Anubhav Aggarwal anub...@seeta.in

AFAICT git still doesn't grok multiple authors [1]. The suggested
workaround is to use a tag Co-authored-by:

  Co-authored-by: Some One some@example.foo


 New global variable 'newtotranslate' added to update the translated text when
 the language to translate is being changed.

If you need to store something in a global variable that only ever gets
used by a class that only has a single instance, you're most likely doing
something wrong.

  pippy_app.py |4 

Especially if you are sending a patch for an activity (but also for core
modules), please include the name of the module as a tag in the summary.
E.g.:

[PATCH Words] Update translated word when language to translate is changed 
(SL#2210)

The only hint I had as to what module your patch was targeted at was
the class WordsActivity in the patch chunk headers.

Sascha

[1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=451880
--
http://sascha.silbe.org/
http://www.infra-silbe.de/


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


Re: [Sugar-devel] chooser/datastore documentation

2010-10-08 Thread Walter Bender
On Fri, Oct 8, 2010 at 4:48 AM, Sascha Silbe
sascha-ml-reply-to-201...@silbe.org wrote:
 Excerpts from Walter Bender's message of Fri Oct 08 01:45:21 +0200 2010:

 I am struggling with getting my activities to behave in consistent
 ways when using the chooser and datastore.find() between Sugar 0.84
 and more recent Sugar versions.  (For example, I cannot get find() to
 process mime-type query in 0.84 but it will handle a title query.

 You can see the full list in src/carquinyol/indexstore.py (0.90 [1],
 0.88 [2], 0.86 [3], 0.84 [4]) resp. src/olpc/datastore/model.py for
 0.82 [5].

 0.90 (see _QUERY_TERM_MAP and _QUERY_VALUE_MAP):
 uid, activity, activity_id, mime_type, keep, timestamp, filesize,
 creation_time

 0.86-0.88 (see _QUERY_TERM_MAP and _QUERY_VALUE_MAP):
 uid, activity, activity_id, mime_type, keep, timestamp

 0.84 (see _parse_query):
 uid, activity, activity_id, mime_type (list), keep, timestamp (start/end
 dict)

 0.82 (see defaultModel):
 activity, activity_id, mime_type, keep, timestamp, title and a whole
 bunch more

 So mime_type should work fine in 0.84+ if you pass it as a list.
 sugar-datastore 0.86+ is more flexible regarding the contents of the
 query dictionary, so what works there does not necessarily work in 0.84.
 In particular 0.86+ will do what you expect if you pass a (single) MIME
 type as a regular string, but 0.84 requires you to pass a list (containing
 a single regular string). Because a string is iterable, 0.84 won't
 notice you didn't pass a list and will happily match each individual
 character against the MIME type field.

 The exact opposite seems to be true in 0.90.

 AFAICT searching (!= sorting) title was never supported for 0.84+.


 Similarly, I cannot get what_filter to work with non-GENERIC mime types,

 Yes, I recently filed a ticket about that [6].


 I've searched unsuccessfully for documentation on what works in which
 versions. Does such documentation exist somewhere?

 Maybe Bert has documented some of it in the wiki. It would be great if
 you could either augment his documentation or create a new one based on
 the information above.

Thanks. I'll write a test program to confirm all of the above and put
the results in the wiki.

-walter


 Sascha

 [1] 
 http://git.sugarlabs.org/projects/sugar-datastore/repos/mainline/blobs/master/src/carquinyol/indexstore.py
 [2] 
 http://git.sugarlabs.org/projects/sugar-datastore/repos/mainline/blobs/sucrose-0.88/src/carquinyol/indexstore.py
 [3] 
 http://git.sugarlabs.org/projects/sugar-datastore/repos/mainline/blobs/sucrose-0.86/src/carquinyol/indexstore.py
 [4] 
 http://git.sugarlabs.org/projects/sugar-datastore/repos/mainline/blobs/sucrose-0.84/src/carquinyol/indexstore.py
 [5] 
 http://git.sugarlabs.org/projects/sugar-datastore/repos/mainline/blobs/sucrose-0.82/src/olpc/datastore/model.py
 [6] https://bugs.sugarlabs.org/ticket/2400
 --
 http://sascha.silbe.org/
 http://www.infra-silbe.de/

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





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


Re: [Sugar-devel] chooser/datastore documentation

2010-10-08 Thread Sascha Silbe
Excerpts from Walter Bender's message of Fri Oct 08 11:28:33 +0200 2010:

[skipped full quote detailing what properties are searchable in which data
store version]
 Thanks. I'll write a test program to confirm all of the above and put
 the results in the wiki.

Great, thanks!

Sascha

--
http://sascha.silbe.org/
http://www.infra-silbe.de/


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


Re: [Sugar-devel] [IAEP] Make Your Own Sugar Activites! is on Lulu.com

2010-10-08 Thread James Simmons
Kevin,

I'm seeing the same thing you are.  I get the Forbidden page when I
try to do the free download.

While I wrote the book, someone from FLOSS Manuals actually submitted
it to Lulu.  She might have some insight as to why this isn't working.

One of the things I planned to do from the beginning was to create a
full color PDF for the book and donate it to the Internet Archive as a
Community Text.  I may do that later today.  I'll let you know.  The
PDF submitted to Lulu is grayscale.  The Internet Archive makes
donated books available very quickly.  I'll send a message to the list
when I have it posted.

James Simmons


On Thu, Oct 7, 2010 at 5:13 PM, Kevin Cole kjc...@dc.sugarlabs.org wrote:
 Hi,

 FYI: It claims the download is free but then when one clicks through
 to the Download button (two clicks to get there) it claims

 You do not have access to the page you requested.

 (The first link is: Also available as [File Download] Free which
 takes one to a page with a big blue [Download] button.  Clicking that
 whether logged in or not yields the above message.)

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


[Sugar-devel] [PATCH Words] Updated translated word when language to translate is changed. (Ticket #2210)

2010-10-08 Thread Ishan Bansal
New global variable 'newtotranslate' added to update the translated text when
the language to translate is being changed.
---
 pippy_app.py |4 
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/pippy_app.py b/pippy_app.py
index b9a5a25..f9b0be7 100644
--- a/pippy_app.py
+++ b/pippy_app.py
@@ -49,6 +49,7 @@ class WordsActivity(ViewSourceActivity):
 self.fromlang = English
 self.tolang   = Spanish
 self.languagemodel = LanguageModel.LanguageModel()
+self.newtotranslate = 'none'
 
 # Main layout.
 hbox = gtk.HBox(homogeneous=True)
@@ -151,6 +152,8 @@ class WordsActivity(ViewSourceActivity):
 
 def lang2combo_cb(self, combo):
 self.languagemodel.SetLanguages(English, 
self.langs[combo.get_active()])
+self.translated.set_text()
+self.totranslate_cb(self.newtotranslate)
 
 def lang1sel_cb(self, column):
 # FIXME: Complete the text entry box
@@ -177,6 +180,7 @@ class WordsActivity(ViewSourceActivity):
 
 def totranslate_cb(self, totranslate):
 entry = totranslate.get_text()
+self.newtotranslate = totranslate
 # Ask for completion suggestions
 if not entry:
 return
-- 
1.7.0.4

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


[Sugar-devel] [PATCH v2 Words] Updated translated word when language to translate is changed. (Ticket #2210)

2010-10-08 Thread Ishan Bansal
From: Ishan Bansal is...@seeta.in, Anubhav Aggarwal anub...@seeta.in

New global variable 'newtotranslate' added to update the translated text when
the language to translate is being changed.
---
 pippy_app.py |4 
 1 files changed, 4 insertions(+), 0 deletions(-)
 v1-v2 : global variable removed and subject updated

diff --git a/pippy_app.py b/pippy_app.py
index b9a5a25..f9b0be7 100644
--- a/pippy_app.py
+++ b/pippy_app.py
@@ -49,6 +49,7 @@ class WordsActivity(ViewSourceActivity):
 self.fromlang = English
 self.tolang   = Spanish
 self.languagemodel = LanguageModel.LanguageModel()
+self.newtotranslate = 'none'
 
 # Main layout.
 hbox = gtk.HBox(homogeneous=True)
@@ -151,6 +152,8 @@ class WordsActivity(ViewSourceActivity):
 
 def lang2combo_cb(self, combo):
 self.languagemodel.SetLanguages(English, 
self.langs[combo.get_active()])
+self.translated.set_text()
+self.totranslate_cb(self.newtotranslate)
 
 def lang1sel_cb(self, column):
 # FIXME: Complete the text entry box
@@ -177,6 +180,7 @@ class WordsActivity(ViewSourceActivity):
 
 def totranslate_cb(self, totranslate):
 entry = totranslate.get_text()
+self.newtotranslate = totranslate
 # Ask for completion suggestions
 if not entry:
 return
-- 
1.7.0.4

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


[Sugar-devel] Make Your Own Sugar Activites! is on the Internet Archive

2010-10-08 Thread James Simmons
A few people (everyone who tried) had trouble downloading the free PDF
of Make Your Own Sugar Activities! from Lulu.  I have tried to
contact the tech support team on Lulu to get this straightened out.

In the interim I have also posted a full color PDF using the same
style sheet and page size the book uses on the Internet Archive.  It
isn't showing up in searches yet but you should be able to download it
here:

http://www.archive.org/details/MakeYourOwnSugarActivities

The OBJAVI software used by FLOSS Manuals should be able to create an
EPUB, although I've never tried it.  When I have a chance I'll try
that too and if it looks good I'll make that format part of this entry
as well.

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


[Sugar-devel] [PATCH] Disable Start menu item for entries that can't be opened(Bug#328)

2010-10-08 Thread Mukul Gupta
The patch disables the Start and Start With menu items for files
which can't be opened by any installed activity and instead
replace it with a hover dropdown with a menu item 'No activity
installed to start entry'
---
 src/jarabe/journal/palettes.py |   99 +--
 1 files changed, 53 insertions(+), 46 deletions(-)

diff --git a/src/jarabe/journal/palettes.py b/src/jarabe/journal/palettes.py
index 7c3e5ff..56df595 100644
--- a/src/jarabe/journal/palettes.py
+++ b/src/jarabe/journal/palettes.py
@@ -62,51 +62,59 @@ class ObjectPalette(Palette):
 Palette.__init__(self, primary_text=title,
  icon=activity_icon)
 
-if metadata.get('activity_id', ''):
-resume_label = _('Resume')
-resume_with_label = _('Resume with')
-else:
-resume_label = _('Start')
-resume_with_label = _('Start with')
-menu_item = MenuItem(resume_label, 'activity-start')
-menu_item.connect('activate', self.__start_activate_cb)
-self.menu.append(menu_item)
-menu_item.show()
-
-menu_item = MenuItem(resume_with_label, 'activity-start')
-self.menu.append(menu_item)
-menu_item.show()
-start_with_menu = StartWithMenu(self._metadata)
-menu_item.set_submenu(start_with_menu)
-
-client = gconf.client_get_default()
-color = XoColor(client.get_string('/desktop/sugar/user/color'))
-menu_item = MenuItem(_('Copy'))
-icon = Icon(icon_name='edit-copy', xo_color=color,
-icon_size=gtk.ICON_SIZE_MENU)
-menu_item.set_image(icon)
-menu_item.connect('activate', self.__copy_activate_cb)
-self.menu.append(menu_item)
-menu_item.show()
-
-menu_item = MenuItem(_('Send to'), 'document-send')
-self.menu.append(menu_item)
-menu_item.show()
-
-friends_menu = FriendsMenu()
-friends_menu.connect('friend-selected', self.__friend_selected_cb)
-menu_item.set_submenu(friends_menu)
-
-if detail == True:
-menu_item = MenuItem(_('View Details'), 'go-right')
-menu_item.connect('activate', self.__detail_activate_cb)
-self.menu.append(menu_item)
-menu_item.show()
-
-menu_item = MenuItem(_('Erase'), 'list-remove')
-menu_item.connect('activate', self.__erase_activate_cb)
-self.menu.append(menu_item)
-menu_item.show()
+   if misc.get_activities(metadata):
+   if metadata.get('activity_id', ''):
+   resume_label = _('Resume')
+   resume_with_label = _('Resume with')
+   else:
+   resume_label = _('Start')
+   resume_with_label = _('Start with')
+   menu_item = MenuItem(resume_label, 'activity-start')
+   menu_item.connect('activate', self.__start_activate_cb)
+   self.menu.append(menu_item)
+   menu_item.show()
+   
+   menu_item = MenuItem(resume_with_label, 'activity-start')
+   self.menu.append(menu_item)
+   menu_item.show()
+   start_with_menu = StartWithMenu(self._metadata)
+   menu_item.set_submenu(start_with_menu)
+
+   else:
+   resume_label = _('No activity installed to start entry')
+   menu_item = MenuItem(resume_label)
+   menu_item.set_sensitive(False)
+   self.menu.append(menu_item)
+   menu_item.show()
+
+   client = gconf.client_get_default()
+   color = XoColor(client.get_string('/desktop/sugar/user/color'))
+   menu_item = MenuItem(_('Copy'))
+   icon = Icon(icon_name='edit-copy', xo_color=color,
+   icon_size=gtk.ICON_SIZE_MENU)
+   menu_item.set_image(icon)
+   menu_item.connect('activate', self.__copy_activate_cb)
+   self.menu.append(menu_item)
+   menu_item.show()
+
+   menu_item = MenuItem(_('Send to'), 'document-send')
+   self.menu.append(menu_item)
+   menu_item.show()
+
+   friends_menu = FriendsMenu()
+   friends_menu.connect('friend-selected', self.__friend_selected_cb)
+   menu_item.set_submenu(friends_menu)
+   
+   if detail == True:
+   menu_item = MenuItem(_('View Details'), 'go-right')
+   menu_item.connect('activate', self.__detail_activate_cb)
+   self.menu.append(menu_item)
+   menu_item.show()
+   
+   menu_item = MenuItem(_('Erase'), 'list-remove')
+   menu_item.connect('activate', self.__erase_activate_cb)
+   self.menu.append(menu_item)
+   menu_item.show()
 
 def __start_activate_cb(self, menu_item):
 misc.resume(self._metadata)
@@ -219,7 +227,6 @@ class StartWithMenu(gtk.Menu):
 mime_registry.set_default_activity(mime_type, service_name)
 misc.resume(self._metadata, service_name)
 
-
 class BuddyPalette(Palette):
 def __init__(self, buddy):
 self._buddy = buddy
-- 

Re: [Sugar-devel] [Testing] Submitting test requests - some provisional instructions

2010-10-08 Thread Simon Schampijer

On 09/30/2010 12:53 AM, Tim McNamara wrote:

I have created a page in the OLPC wiki for submitting test
requests[1]. The reason I used wiki.laptop.org rather than wiki.sl.o
was because that's where the NZ teams' presences are currently. A wiki
page serves as a good place so that people don't need to sign into
several services, etc. This process is subject to something else being
adopted that works better for everyone. Please provide feedback on
other suggestions.*

If you would like something tested and reported on, please submit it
to [1]. If you're short of time or whatever, feel free to send it to
sugar-devel and I'll port the request over.

I've created a small format for receiving test requests. Please
include the following information:

  * Test description
  Either provide a test case and expected behaviour, a ticket (that
includes replication instructions) that you think you've fixed, or
just say [General].
  * Required equipment
  Indicate whether Internet connectivity is required, SoaS, XO-1,
XO-1.5, virtual machine image, etc.
  * Download location
  Where we get the file to test. Direct links are best.

Tim


* I have discounted a few others, such a Google Forms. I would like to
stick to free software.

[1] http://wiki.laptop.org/go/OLPC_New_Zealand/Test_Requests


Hi Tim,

I was about to add a request for testing the 0.90-XO builds. But looks 
like it is already filed at [1] :) Thanks for considering!


Btw, you can use the builds as well to test the latest Etoys version, it 
is included. Known bugs in the builds can be found at [2].


Regards,
   Simon

[1] http://wiki.laptop.org/go/OLPC_New_Zealand/Test_Requests#Current_tests

[2] 
http://bugs.sugarlabs.org/query?col=idcol=summarycol=statuscol=typecol=prioritycol=milestonecol=componentkeywords=~olpc-0.90order=priority



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


Re: [Sugar-devel] chooser/datastore documentation

2010-10-08 Thread Art Hunkins

This information would help me as well.

Art Hunkins

- Original Message - 
From: Walter Bender walter.ben...@gmail.com

To: Sugar-dev Devel sugar-devel@lists.sugarlabs.org
Sent: Thursday, October 07, 2010 7:45 PM
Subject: [Sugar-devel] chooser/datastore documentation



I am struggling with getting my activities to behave in consistent
ways when using the chooser and datastore.find() between Sugar 0.84
and more recent Sugar versions. (For example, I cannot get find() to
process mime-type query in 0.84 but it will handle a title query. The
exact opposite seems to be true in 0.90. Of course, I could be doing
it all wrong.) Similarly, I cannot get what_filter to work with
non-GENERIC mime types, but that again could be user error. (I am
trying to choose only Python objects, for example.)

I've searched unsuccessfully for documentation on what works in which
versions. Does such documentation exist somewhere?

thanks.

-walter

--
Walter Bender
Sugar Labs
http://www.sugarlabs.org
___
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] [IAEP] Ask! Please! (Re: how to ask a question)

2010-10-08 Thread forster

Quoting Edward Cherlin echer...@gmail.com:

I have a partial draft of a textbook on the subject at
http://www.booki.cc/discovering-discovery/ It encourages XO owners to
explore on their own and find out what questions they have before we
give them answers.


I like the idea. It encourages users to jump in and take risks,  
experiment, not worry if they have incomplete understanding.


Who is the target audience? Teachers? Would more graphics be good? I  
have added a little to the TurtleArt chapter


Tony



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


Re: [Sugar-devel] Memory leak in Sugar -- how to dump Py data

2010-10-08 Thread James Cameron
On 08/10/2010, at 3:14 AM, Martin Langhoff wrote:
 On Thu, Oct 7, 2010 at 11:53 AM, Martin Langhoff
 martin.langh...@gmail.com wrote:
 Great. thanks! Setup a test machine and keeping an eye on it.
 
 Even without waiting much, it's clear we're leaking objects referred
 to the UI representation of the access points.

That seems likely.  In the tests for long running Sugar Session leak that I did 
some months ago, there were no other access points scanned except for the one I 
had nearby.  The results I got showed no significant leaks.

--
James Cameron
System Test Coordinator
One Laptop per Child





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


Re: [Sugar-devel] Proposal of dotted activity version number

2010-10-08 Thread Lucian Branescu
On 7 October 2010 21:54, Gonzalo Odiard gonz...@laptop.org wrote:
 Ticket with the start of implementation:

 http://bugs.sugarlabs.org/ticket/2425

 Gonzalo

I'm not sure which way would be best, but I would choose either a very
simple solution (just dotted numbers, no alphanumerics) or a
tried-and-tested solution i.e. carbon copy of debian/fedora/gnome apps
versioning.

In any case, something more expressive than an integer is needed and
I'm all for it.
___
Sugar-devel mailing list
Sugar-devel@lists.sugarlabs.org
http://lists.sugarlabs.org/listinfo/sugar-devel


Re: [Sugar-devel] how to ask a question

2010-10-08 Thread James Cameron
On 08/10/2010, at 7:31 PM, Bernie Innocenti wrote:
 When this happens, we should gently encourage them to prefer public
 communication. I reserve the stronger signals -- such as refusing to
 answer the question until it's posted publicly -- for those who are
 repeatedly ignoring this advice. I'm not running a free technical
 support line.

Indeed.

Here is a page with diagram that I use on other projects for people who persist 
in writing privately to me:

http://pptpclient.sourceforge.net/why.phtml

--
James Cameron
System Test Coordinator
One Laptop per Child





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


Re: [Sugar-devel] [PATCH v3 sugar] Pulsing icon delayed by 5 seconds or so SL#2080

2010-10-08 Thread James Cameron
On 08/10/2010, at 9:06 AM, Anurag Chowdhury wrote:
 +for i in range(0, 5):
 +easing = EASE_IN_EXPO
 +duration = duration * 100
 +i = i + 1

That last line is not required.  See for example this manual test:

 for i in range(0, 5):
... print i
... i = i + 1
... 
0
1
2
3
4
 for i in range(0, 5):
... print i
... 
0
1
2
3
4
 

Further, the variable i is not referenced within the for loop, so the code 
could be reduced to:

 +easing = EASE_IN_EXPO
 +duration = duration * 100

Which does not look reasonable.

--
James Cameron
System Test Coordinator
One Laptop per Child





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


[Sugar-devel] Review: [PATCH] Downgrading activities not allowed. (#2164)

2010-10-08 Thread Manusheel Gupta
Sascha,

Ishan tried to add the tag - Coauthored by in his patch, and that line
gets scrubbed off. We might have mistaken in understanding your review. Can
you elaborate on the format of the patch been worked on by multiple authors?
Unfortunately, git does not provide this feature at this
juncture. Appreciate your pointers as always.

On a separate note, could you please review the patch submitted by Shan
below. It was peer reviewed within the team by Ayush and Anurag.

Regards,

Manu







On Thu, Oct 7, 2010 at 8:52 PM, sugar-devel-requ...@lists.sugarlabs.orgwrote:


   2. [PATCH] Downgrading activities not allowed. (#2164)
  (shan...@seeta.in)

 From: shan...@seeta.in
 To: sugar-devel@lists.sugarlabs.org
 Subject: [Sugar-devel] [PATCH] Downgrading activities not allowed.
(#2164)
 Message-ID: 4cadd298.c83ddf0a.508f.3...@mx.google.com

 From: Shanjit Singh Jajmann shan...@seeta.in, Anubhav Aggarwal 
 anub...@seeta.in

 Downgrading an activity is now made possible. When a .xo file of a version
 older than the currently installed version is clicked, a downgrading option
 is made available, by popping up of a confirmation alert. Depending upton
 the choice selected you can downgrade the activity.
 ---
  src/jarabe/journal/journalactivity.py |   36 +++--
  src/jarabe/journal/listview.py|7 +++-
  src/jarabe/journal/misc.py|   56
 -
  src/jarabe/model/bundleregistry.py|   18 +++---
  4 files changed, 91 insertions(+), 26 deletions(-)
  mode change 100644 = 100755 src/jarabe/journal/misc.py
  mode change 100644 = 100755 src/jarabe/model/bundleregistry.py

 diff --git a/src/jarabe/journal/journalactivity.py
 b/src/jarabe/journal/journalactivity.py
 index 44cc018..2af55d3 100644
 --- a/src/jarabe/journal/journalactivity.py
 +++ b/src/jarabe/journal/journalactivity.py
 @@ -28,6 +28,7 @@ import os

  from sugar.graphics.window import Window
  from sugar.graphics.alert import ErrorAlert
 +from sugar.graphics.alert import ConfirmationAlert

  from sugar.bundle.bundle import ZipExtractException, RegistrationException
  from sugar import env
 @@ -128,7 +129,7 @@ class JournalActivity(Window):
 self.connect('window-state-event', self.__window_state_event_cb)
 self.connect('key-press-event', self._key_press_event_cb)
 self.connect('focus-in-event', self._focus_in_event_cb)
 -
 +
 model.created.connect(self.__model_created_cb)
 model.updated.connect(self.__model_updated_cb)
 model.deleted.connect(self.__model_deleted_cb)
 @@ -136,7 +137,6 @@ class JournalActivity(Window):
 self._dbus_service = JournalActivityDBusService(self)

 self.iconify()
 -
 self._critical_space_alert = None
 self._check_available_space()

 @@ -145,7 +145,29 @@ class JournalActivity(Window):
 alert.connect('response', self.__alert_response_cb)
 self.add_alert(alert)
 alert.show()
 -
 +
 +def __activity_alert1_cb(self):
 +   if misc.check_previous_install() == 1 and
 misc.return_checked()==0:
 + alert1 = ConfirmationAlert()
 + logging.debug('value of misc is %d',
 misc.check_previous_install())
 + alert1.props.title=_('Previous Version Found')
 + alert1.props.msg = _('A previous version of an installed
 activity was found. Are you sure you want to continue with installation ?
If Yes
 click Ok and the activity icon of the older .xo file in the Journal')
 + alert1.connect('response', self.__alert1_response_cb)
 + self.add_alert(alert1)
 + alert1.show()
 +
 +def __alert1_response_cb(self, alert1, response_id):
 +if response_id is gtk.RESPONSE_OK:
 +logging.debug('value of checked initial %d',
 misc.return_checked())
 +logging.debug('Installing previous version')
 +self.remove_alert(alert1)
 +misc.checked = 1
 +logging.debug('value of checked final %d',
 misc.return_checked())
 +
 +elif response_id is gtk.RESPONSE_CANCEL:
 +logging.debug('Cancelled by user')
 +self.remove_alert(alert1)
 +
 def __alert_response_cb(self, alert, response_id):
 self.remove_alert(alert)

 @@ -166,6 +188,8 @@ class JournalActivity(Window):
 self._list_view = ListView()
 self._list_view.connect('detail-clicked', self.__detail_clicked_cb)
 self._list_view.connect('clear-clicked', self.__clear_clicked_cb)
 +self._list_view.connect('icon-clicked', self.__icon_clicked_cb)
 +logging.debug('icon clicked in main')
 self._main_view.pack_start(self._list_view)
 self._list_view.show()

 @@ -195,7 +219,11 @@ class JournalActivity(Window):
 keyname = gtk.gdk.keyval_name(event.keyval)
 if keyname == 'Escape':
 self.show_main_view()
 -
 +
 +  

[Sugar-devel] Possible copyright infringement in activities.sl.o

2010-10-08 Thread Tim McNamara
Hi all,

This morning, I tested juegos_flash-2. It's just a sample of free (no cost)
flash games from the Internet. I don't think Sugar Labs is be allowed to
distribute them.

Apart from these legal concerns, I also have some ethical ones. The package
includes a game that teaches users how to mix cocktails. Another one of the
activities is called Smack your ex.

Here are my raw notes from the session:

## juegos_flash-2
 - coloured icon
 - flash would wouldn't render the chess board at the start
 - seems to be a compilation of non-free flash games from various sites
 - gnash gave me English menus, everything else in Spanish

 - Penales
   - All rights reserved Flashfooty.com FTW
   - games failed to load after 20 secs

 - Penales2
  -  Games1.com Ad ??
  - in English
  - selecting a team didn't seem to do anything

 - EncontrarObjectos
   - failed to load in  20 secs on XO-1.5

 - Bar
   - Welcome to our pre-party cocktail mixing game for cocktail
 connoisseurs... or not as the case may be! - omg, it's actually
 a game about alcohol consumption
   - kinda cute, in it's own way. Provides instructions along the way,
 which is what I had expected from spirolaterals

 - Cocinarpizza
   - seemed unresponsive to the XO's mousepad

 - Ajedrez
   - argh, flashing chess game again

 - Futbal
   - ran very slowly
   - when missing a goal, the text is undefined

 - Tesoro
   - loaded well, a little slow on XO-1.5
   - teacher seemed to be silent

 - Pes2002
   - heavily screen flickering (gave up after 20sec)

 - Bolos
   - failed to load once Play was clicked

 - QueHariasConTuEx
   - from whackyourex.com
   - game does what it says



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


Re: [Sugar-devel] Sugar-devel Digest, Vol 24, Issue 36 9Re: how to ask a question)

2010-10-08 Thread Yioryos Asprobounitis



 Date: Sat, 9 Oct 2010 10:32:42 +1100
 From: James Cameron qu...@laptop.org
 To: Bernie Innocenti ber...@codewiz.org
 Cc: IAEP i...@lists.sugarlabs.org,   
 sugar-devel
     sugar-devel@lists.sugarlabs.org,   
 David Farning dfarn...@gmail.com,
     c...@laptop.org,   
 Ishan Bansal is...@seeta.in
 Subject: Re: [Sugar-devel] how to ask a question
 Message-ID: af18c0dc-916e-4614-9661-6458e094c...@laptop.org
 Content-Type: text/plain; charset=us-ascii
 
 On 08/10/2010, at 7:31 PM, Bernie Innocenti wrote:
  When this happens, we should gently encourage them to
 prefer public
  communication. I reserve the stronger signals -- such
 as refusing to
  answer the question until it's posted publicly -- for
 those who are
  repeatedly ignoring this advice. I'm not running a
 free technical
  support line.
 
 Indeed.
 
 Here is a page with diagram that I use on other projects
 for people who persist in writing privately to me:
 
 http://pptpclient.sourceforge.net/why.phtml
 
 --
 James Cameron
 System Test Coordinator
 One Laptop per Child
 
 

I would not necessarily disagree with the opinions expressed on the matter, but 
there is a very big gap in SL's communication with it's users.
No place to ask the stupid/bad/novice/malformed  questions.
For an organization that caters to 1,5 million kids and few thousand teachers 
and almost be default computer novices, this is unacceptable (to me).
As a developer of an upstream organization, you may as well say this is not my 
problem, however, as a SugarLabs member it should be.
Applying devel-list rules to the _only_ QA Sugar venue, can seriously 
contribute to an unapproachable image and put off the exact people that you 
are trying to constructively teach.   


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


Re: [Sugar-devel] bugs problem

2010-10-08 Thread Anish Mangal
Hi,

This is promising. Can you tell me what bug were you looking at? I can
give you a new bug to work on if you want [1]
Though not very special or complex to fix, this would help you get the
hang of coding guidelines and pylint.

Your flow for working on this should be something like...

a. cd sugar-jhbuild-directory/install/share/sugar/activities/
b. remove the Pippy.activity directory if exists
c. clone the remote repository - git clone
git://git.sugarlabs.org/pippy/mainline.git Pippy.activity
d. Work on fixing the bug (I guess you'll need to run pylint on the
examples) and go through the pep8 coding guidelines[2]
e. After you have worked on the bug and tested your modifications. cd
to the Pippy.activity directory and type in git status. It will show
a detailed status of all files modified and in what manner...
f. Type git add filename with path to stage your files. Any good
git manual such as progit [3] is your friend, if you want to dive
deeper
g. After you have git add(ed) all the files, it is time to commit
your changes locally. Type in git commit. After that, it will open a
code editor, where you can describe your changes. In the first line
will be the header of your commit message, followed by a blank line
and a paragraph for the detailed description (if required). In the
header of the commit message type-in something meaningful such as
Pippy: Modify examples to follow coding guidelines (sl#2150). Save
and close the editor for the changes to be committed
h. To check if the changes were actually committed you may type in
git log or git log -p. It will list all the commits to the Pippy
repository till date. Your commit should be the first one in the list.
i. If you have reached this far, you need to make a patch file so that
everyone can commit and test your changes. Type in git format-patch
-s -1. This will create a .patch file
j. Send the .patch file to the mailing list and to the maintainer of
Pippy (which happens to be me ;-) ). Type in git send-email --to
an...@sugarlabs.org --cc sugar-devel@lists.sugarlabs.org your .patch
file.

Now, wait for review comments from folks on the m-l, and modify the
code if required. Do 'git add' for the files you modified followed by
'git commit --amend'. This will modify your last commit instead of
creating a new one. Make a patch and send to the ml for further
review. I'd strongly suggest using vim/gvim (or emacs) as your code
editor for working on sugar. You will find the .vimrc files I sent you
pretty useful.

Best of Luck  Happy Hacking!

[1] http://bugs.sugarlabs.org/ticket/2150
[2] http://www.python.org/dev/peps/pep-0008/
[3] http://progit.org/book/

On Sat, Oct 9, 2010 at 3:30 AM, Brajesh Upadhyay braj...@nsitonline.in wrote:
 hi

 was checking patches of few fixed bugs. got a basic idea what to do.. but
 not able to fully understand it.
 how should i go about it??  shall i try to explore futher on these bugs and
 gully understand the working of the code (i just got an overview) or u will
 give me a new bug to explore on?

 regards
 Brajesh Upadhyay


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