Re: [translate-pootle] Still problems committing with git

2008-07-05 Thread F Wolff
On Vr, 2008-07-04 at 05:52 +0200, Lars Kruse wrote:
> Hi,
> 
> > > If the code to support older git versions is available, we obviously use 
> > > it,
> > > but I'm not too concerned about halting anything just to support all
> > > versions.
> > 
> > I agree. Thus I will add a module for git<1.5.2 within the next days.
> > I hope, that it will work for git 1.4.x, too.
> 
> I just committed the additional git module for versions prior to 1.5.3.
> The version control interface will choose the module that fits to your locally
> installed version of git.
> 
> Since I am not actively using git, I could only test the "getcleanfile"
> function of the interface (for git: "cat-file" (v1.4.4) or "show" (v1.5.3)).
> The other functions like "update" and "commit" are not tested, yet.
> I would be happy, if someone could check these features as well.
> 
> I just closed the bug report. Please reopen it, if necessary.
> http://bugs.locamotion.org/show_bug.cgi?id=347
> 
> Lars

Well done, Lars! Thank you for this work.

Friedel


-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-03 Thread Lars Kruse
Hi,

> > If the code to support older git versions is available, we obviously use it,
> > but I'm not too concerned about halting anything just to support all
> > versions.
> 
> I agree. Thus I will add a module for git<1.5.2 within the next days.
> I hope, that it will work for git 1.4.x, too.

I just committed the additional git module for versions prior to 1.5.3.
The version control interface will choose the module that fits to your locally
installed version of git.

Since I am not actively using git, I could only test the "getcleanfile"
function of the interface (for git: "cat-file" (v1.4.4) or "show" (v1.5.3)).
The other functions like "update" and "commit" are not tested, yet.
I would be happy, if someone could check these features as well.

I just closed the bug report. Please reopen it, if necessary.
http://bugs.locamotion.org/show_bug.cgi?id=347

Lars

-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Christian Perrier
Quoting Lars Kruse ([EMAIL PROTECTED]):

> > I think these are very valid comments. This whole conversation is about
> > a bug anyway, and git is (as you mention) previously unsupported. If the
> > code to support older git versions is available, we obviously use it,
> > but I'm not too concerned about halting anything just to support all
> > versions.
> 
> I agree. Thus I will add a module for git<1.5.2 within the next days.
> I hope, that it will work for git 1.4.x, too.
> If it does not work for git 1.4.x, then we will just ignore this issue until
> people report real demand, I guess.


All this seems fair. As Miklos pointed and when it comes at Debian,
using a recent Pootle version needs to install either a backported
package or a package from Debian lenny (which is what we do on
i18n.debian.net). So, having to install a backported git is not that a
big deal.

In short, if supporting git versions prior to 1.5 was possible, it
would be good. If that's complicated and involve losing valuable
developer time, it's not worth it.

Actually, people building Pootle production servers with Debian should
indeed use Etch plus Pootle from testing and git from www.backports.org




-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread F Wolff
On Do, 2008-07-03 at 01:56 +0200, Lars Kruse wrote:
> Hi,
> 
> I just committed Miklos' patches for the git module as r7710.
> This should fix problems with git v1.5.3 (or higher).
> (I did it, since I did not notice any objections ...)

Perfect! Thank you everybody for helping out to solve and test this.

Friedel




-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Lars Kruse
Hi,

I just committed Miklos' patches for the git module as r7710.
This should fix problems with git v1.5.3 (or higher).
(I did it, since I did not notice any objections ...)


> > I think if we want to support Debian stable, then we have to support
> > 1.4.4.4, since that's the official version Debian comes with. There are
> > major changes between 1.4.x and 1.5.x, and - to be honest - I'm not too
> > motivated to write code for <1.5.x.
> > 
> > So I would vote for C).
> > 
> > Just my two cents.
> 
> I think these are very valid comments. This whole conversation is about
> a bug anyway, and git is (as you mention) previously unsupported. If the
> code to support older git versions is available, we obviously use it,
> but I'm not too concerned about halting anything just to support all
> versions.

I agree. Thus I will add a module for git<1.5.2 within the next days.
I hope, that it will work for git 1.4.x, too.
If it does not work for git 1.4.x, then we will just ignore this issue until
people report real demand, I guess.

Lars

-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread F Wolff
On Wo, 2008-07-02 at 23:18 +0200, Miklos Vajna wrote:
> On Wed, Jul 02, 2008 at 02:36:34AM +0200, Lars Kruse <[EMAIL PROTECTED]> 
> wrote:

...

> > C)
> > - applying Miklos patches to the current git support
> > - ignoring incompatibility with git<=1.5.2
> 
> I think the situation where compabitility with git<=1.5.2 makes sense is
> Debian stable. It has Pootle 0.10.1. It just does not have Git support.
> If a sysadmin decides to install newer a never (it was called
> unofficial) version of Pootle, then I think it is not that hard to
> install a newer version of Git as well.
> 
> I think if we want to support Debian stable, then we have to support
> 1.4.4.4, since that's the official version Debian comes with. There are
> major changes between 1.4.x and 1.5.x, and - to be honest - I'm not too
> motivated to write code for <1.5.x.
> 
> So I would vote for C).
> 
> Just my two cents.

I think these are very valid comments. This whole conversation is about
a bug anyway, and git is (as you mention) previously unsupported. If the
code to support older git versions is available, we obviously use it,
but I'm not too concerned about halting anything just to support all
versions.

Friedel


-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Miklos Vajna
On Wed, Jul 02, 2008 at 02:36:34AM +0200, Lars Kruse <[EMAIL PROTECTED]> wrote:
> 1) the current implementation does not work without the "--work-tree" 
> parameter
> (e.g. with the two patches that were sent by Miklos (30.6.2008))
> 
> 2) git v1.5.3 (or higher) behaves as expected -> it is specified/documented to
> need both "--git-dir" and "--work-tree" for any operation outside of the
> current directory
> 
> 3) for git v1.5.2 (and before) we have to change to the (base of the?) local 
> git
> repository before executing git

Right. the work-tree/git-dir switches allow out-of-tree git commands
which I did not need when I initially did Git support, and unfortunately
I forgot about them.

> C)
> - applying Miklos patches to the current git support
> - ignoring incompatibility with git<=1.5.2

I think the situation where compabitility with git<=1.5.2 makes sense is
Debian stable. It has Pootle 0.10.1. It just does not have Git support.
If a sysadmin decides to install newer a never (it was called
unofficial) version of Pootle, then I think it is not that hard to
install a newer version of Git as well.

I think if we want to support Debian stable, then we have to support
1.4.4.4, since that's the official version Debian comes with. There are
major changes between 1.4.x and 1.5.x, and - to be honest - I'm not too
motivated to write code for <1.5.x.

So I would vote for C).

Just my two cents.


pgpmyXzRn776n.pgp
Description: PGP signature
-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Wynand Winterbach
Miklos Vajna wrote:
> On Mon, Jun 30, 2008 at 11:35:13PM +0200, Miklos Vajna <[EMAIL PROTECTED]> 
> wrote:
>   
>> here is a patch, on top of my previous one.
>> 
>
> Friedel, if you could review/commit these 2 patches, I would appreciate
> it. I think they are definitely useful not only for Debian but for
> anybody who use po files outside the Pootle directory (we at Frugalware
> do not use external po files, that's why I haven't hit this bug yet).
>
> Thanks.
Miklos, I'll also review your changes tomorrow and try to check them in 
as soon as I can. If Friedel is slow to respond, it's because he's at a 
conference this week :).

Regards
Wynand
> 
>
> -
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> 
>
> ___
> Translate-pootle mailing list
> Translate-pootle@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/translate-pootle
>   


-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Wynand Winterbach
Miklos Vajna wrote:
> On Tue, Jul 01, 2008 at 09:03:37PM +0200, Wynand Winterbach <[EMAIL 
> PROTECTED]> wrote:
>   
>> Miklos, I'll also review your changes tomorrow and try to check them in as 
>> soon as I can. If Friedel is slow to respond, it's because he's at a 
>> conference this week :).
>> 
>
> Oh, OK, I was not about to hurry you, just wanted to point out these
> patches were not meant to specific to the Debian guys. :-)
>   
No worries Miklos; I just didn't want you to think that we're ignoring 
you (we *love* patches :)).

Cheers
Wynand
> 
>
> -
> Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
> Studies have shown that voting for your favorite open source project,
> along with a healthy diet, reduces your potential for chronic lameness
> and boredom. Vote Now at http://www.sourceforge.net/community/cca08
> 
>
> ___
> Translate-pootle mailing list
> Translate-pootle@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/translate-pootle
>   


-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Christian Perrier
Quoting F Wolff ([EMAIL PROTECTED]):

> >From Christians' feedback, I understand that things are well tested, and
> that we are happy with this working. (I haven't tested this yet.)

s/well tested/tested

:-)

We don't have anything in prodcution yet (but I now really work on
this, for translations related to the Debian Installer-->you can for
instance begin some work on Afrikaans translation of D-I in Pootle if
you would like to help...:-))

So,  as all this is not used in prodcution, I can't tell this is "well
tested".




-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-02 Thread Christian Perrier
Quoting Lars Kruse ([EMAIL PROTECTED]):

> C)
> - applying Miklos patches to the current git support
> - ignoring incompatibility with git<=1.5.2
> 
> Personally I would prefer (A) over (B) due to the cleaner code (in the
> long-term). But of course, I would not mind (B), too.
> The current version of git in debian stable seems to imply that (C) is not a
> good option for us, or?

We worked this around by using a more recent version of git, for
sure. But, if there's any way to support older versions, it would
certainly be better as you will at some moment definitely find someone
who prefers sticking with "supported" version of packages and software
on their distro.

So, if it is possible to support git versions below 1.5.2, it would
get my own vote.



-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread Christian Perrier
Quoting F Wolff ([EMAIL PROTECTED]):

> Well, how far is the next Debian stable away? I would prefer A as well


When it's ready..:-)

The official target release date is Sept. 2008 but we will quite
certainly not make it.

You can bet on something like "end of year" but, well, we're talking
about Debian, not Ubuntu where the release (nearly laways) happens,
whether things are really settled or not..:-)




-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread F Wolff
On Wo, 2008-07-02 at 02:36 +0200, Lars Kruse wrote:
> Hi,
> 
> > > Does this solve bug 347 properly? (Do we now support the older versions
> > > of git?) I would just like to document this properly.
> > 
> > Unfortunately no:
> > 
> > $ ~/git/git/git --git-dir git/setup/.git --work-tree git/setup add HACKING
> > Unknown option: --work-tree
> > 
> > $ ~/git/git/git --version
> > git version 1.5.2
> > 
> > for <1.5.3 you still need to manually chdir() to the repo, perform the
> > operation and then chdir() back. And that's already done by
> > http://bugs.locamotion.org/attachment.cgi?id=125&action=view ;-)
> 
> I am not sure, if I get the complete picture of the state of the git support.
> Please correct me, if I am wrong about something:
> 
> 1) the current implementation does not work without the "--work-tree" 
> parameter
> (e.g. with the two patches that were sent by Miklos (30.6.2008))
> 
> 2) git v1.5.3 (or higher) behaves as expected -> it is specified/documented to
> need both "--git-dir" and "--work-tree" for any operation outside of the
> current directory
> 
> 3) for git v1.5.2 (and before) we have to change to the (base of the?) local 
> git
> repository before executing git
> 
> 
> If these three assumptions are valid, then I would see the following
> alternative solutions:
> 
> A)
> - applying Miklos patches to the current git support
> - adding a second module for git support (e.g. git-1.5.2.py) that would
> include the ugly os.chdir workarounds. We have to keep both in sync until
> we will finally remove support for git<=1.5.2. The current module for the
> Lucene indexing engine is splitted in a similar way, so I don't see problems 
> in
> implementing this.
> 
> B)
> - adding the os.chdir workaround to the current git interface and removing all
> occourences of --git-dir and --work-tree.
> 
> C)
> - applying Miklos patches to the current git support
> - ignoring incompatibility with git<=1.5.2
> 
> Personally I would prefer (A) over (B) due to the cleaner code (in the
> long-term). But of course, I would not mind (B), too.
> The current version of git in debian stable seems to imply that (C) is not a
> good option for us, or?
> 
> Any opinions?
> 
> Lars

Well, how far is the next Debian stable away? I would prefer A as well
if somebody is willing to do the work.

Friedel


-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread Lars Kruse
Hi,

> > Does this solve bug 347 properly? (Do we now support the older versions
> > of git?) I would just like to document this properly.
> 
> Unfortunately no:
> 
> $ ~/git/git/git --git-dir git/setup/.git --work-tree git/setup add HACKING
> Unknown option: --work-tree
> 
> $ ~/git/git/git --version
> git version 1.5.2
> 
> for <1.5.3 you still need to manually chdir() to the repo, perform the
> operation and then chdir() back. And that's already done by
> http://bugs.locamotion.org/attachment.cgi?id=125&action=view ;-)

I am not sure, if I get the complete picture of the state of the git support.
Please correct me, if I am wrong about something:

1) the current implementation does not work without the "--work-tree" parameter
(e.g. with the two patches that were sent by Miklos (30.6.2008))

2) git v1.5.3 (or higher) behaves as expected -> it is specified/documented to
need both "--git-dir" and "--work-tree" for any operation outside of the
current directory

3) for git v1.5.2 (and before) we have to change to the (base of the?) local git
repository before executing git


If these three assumptions are valid, then I would see the following
alternative solutions:

A)
- applying Miklos patches to the current git support
- adding a second module for git support (e.g. git-1.5.2.py) that would
include the ugly os.chdir workarounds. We have to keep both in sync until
we will finally remove support for git<=1.5.2. The current module for the
Lucene indexing engine is splitted in a similar way, so I don't see problems in
implementing this.

B)
- adding the os.chdir workaround to the current git interface and removing all
occourences of --git-dir and --work-tree.

C)
- applying Miklos patches to the current git support
- ignoring incompatibility with git<=1.5.2

Personally I would prefer (A) over (B) due to the cleaner code (in the
long-term). But of course, I would not mind (B), too.
The current version of git in debian stable seems to imply that (C) is not a
good option for us, or?

Any opinions?

Lars

-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread Miklos Vajna
On Tue, Jul 01, 2008 at 10:14:07PM +0200, F Wolff <[EMAIL PROTECTED]> wrote:
> Does this solve bug 347 properly? (Do we now support the older versions
> of git?) I would just like to document this properly.

Unfortunately no:

$ ~/git/git/git --git-dir git/setup/.git --work-tree git/setup add HACKING
Unknown option: --work-tree

$ ~/git/git/git --version
git version 1.5.2

for <1.5.3 you still need to manually chdir() to the repo, perform the
operation and then chdir() back. And that's already done by
http://bugs.locamotion.org/attachment.cgi?id=125&action=view ;-)


pgp7c4910p48L.pgp
Description: PGP signature
-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread Miklos Vajna
On Tue, Jul 01, 2008 at 09:03:37PM +0200, Wynand Winterbach <[EMAIL PROTECTED]> 
wrote:
> Miklos, I'll also review your changes tomorrow and try to check them in as 
> soon as I can. If Friedel is slow to respond, it's because he's at a 
> conference this week :).

Oh, OK, I was not about to hurry you, just wanted to point out these
patches were not meant to specific to the Debian guys. :-)


pgpztyATXdC8u.pgp
Description: PGP signature
-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread F Wolff
On Di, 2008-07-01 at 18:38 +0200, Miklos Vajna wrote:
> On Mon, Jun 30, 2008 at 11:35:13PM +0200, Miklos Vajna <[EMAIL PROTECTED]> 
> wrote:
> > here is a patch, on top of my previous one.
> 
> Friedel, if you could review/commit these 2 patches, I would appreciate
> it. I think they are definitely useful not only for Debian but for
> anybody who use po files outside the Pootle directory (we at Frugalware
> do not use external po files, that's why I haven't hit this bug yet).
> 
> Thanks.

Hallo Miklos

Thank you for this! I quickly looked over this, and it looks file to
me.. I would just like to make sure I understand where things stand.

>From Christians' feedback, I understand that things are well tested, and
that we are happy with this working. (I haven't tested this yet.)

Does this solve bug 347 properly? (Do we now support the older versions
of git?) I would just like to document this properly.

If you are happy with this, I'm happy. If we don't hear any objections
from Lars, I'll probably commit this in the next day or so.

Keep well, and thank you again.
Friedel


-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-07-01 Thread Miklos Vajna
On Mon, Jun 30, 2008 at 11:35:13PM +0200, Miklos Vajna <[EMAIL PROTECTED]> 
wrote:
> here is a patch, on top of my previous one.

Friedel, if you could review/commit these 2 patches, I would appreciate
it. I think they are definitely useful not only for Debian but for
anybody who use po files outside the Pootle directory (we at Frugalware
do not use external po files, that's why I haven't hit this bug yet).

Thanks.


pgpsx7iiSoMmP.pgp
Description: PGP signature
-
Sponsored by: SourceForge.net Community Choice Awards: VOTE NOW!
Studies have shown that voting for your favorite open source project,
along with a healthy diet, reduces your potential for chronic lameness
and boredom. Vote Now at http://www.sourceforge.net/community/cca08___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-30 Thread Miklos Vajna
On Mon, Jun 30, 2008 at 08:27:35PM +0200, Christian Perrier <[EMAIL PROTECTED]> 
wrote:
> That would be better as, currently, trying to commit when nothing is
> pending is indeed triggering erros like:
> 
> [GIT] commit of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') 
> failed: 

here is a patch, on top of my previous one.
diff -u translate/storage/versioncontrol/git.py 
translate/storage/versioncontrol/git.py
--- translate/storage/versioncontrol/git.py (working copy)
+++ translate/storage/versioncontrol/git.py (working copy)
@@ -75,8 +75,12 @@
 command.extend(["-m", message])
 exitcode, output_commit, error = run_command(command)
 if exitcode != 0:
+if len(error):
+msg = error
+else:
+msg = output_commit
 raise IOError("[GIT] commit of ('%s', '%s') failed: %s" \
-% (self.root_dir, self.location_rel, error))
+% (self.root_dir, self.location_rel, msg))
 # push changes
 command = self._get_git_command(["push"])
 exitcode, output_push, error = run_command(command)


pgpXsO8bfKefA.pgp
Description: PGP signature
-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-30 Thread Christian Perrier
Quoting Miklos Vajna ([EMAIL PROTECTED]):
> On Mon, Jun 30, 2008 at 09:08:27AM +0200, Christian Perrier <[EMAIL 
> PROTECTED]> wrote:
> > The failure message changed..:-)
> > [GIT] commit of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') 
> > failed: 
> 
> Heh. Are you sure there were actually changes to commit?
> 
> I guess the problem is that commit failed because there were no changes
> to commit, and in this case the stderr is empty.

Yes, you're right, my mistake.

I was thinking I still had pending changes but I actually had zapped
the git cloned tree and recloned it. So nothing was left to commit

> 
> If this is the case, I'm not exactly sure what would be the right
> solution, maybe check if stderr is empty and if yes, dump stdout instead
> stderr in the error message?


That would be better as, currently, trying to commit when nothing is
pending is indeed triggering erros like:

[GIT] commit of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') 
failed: 


-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-30 Thread Miklos Vajna
On Mon, Jun 30, 2008 at 09:08:27AM +0200, Christian Perrier <[EMAIL PROTECTED]> 
wrote:
> The failure message changed..:-)
> [GIT] commit of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') 
> failed: 

Heh. Are you sure there were actually changes to commit?

I guess the problem is that commit failed because there were no changes
to commit, and in this case the stderr is empty.

If this is the case, I'm not exactly sure what would be the right
solution, maybe check if stderr is empty and if yes, dump stdout instead
stderr in the error message?

Thanks.


pgpOdr4xMmH46.pgp
Description: PGP signature
-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-30 Thread Christian Perrier
Quoting Miklos Vajna ([EMAIL PROTECTED]):
> On Sun, Jun 29, 2008 at 05:51:34PM +0200, Miklos Vajna <[EMAIL PROTECTED]> 
> wrote:
> > I'll send a patch to correct this later tonight.
> 
> Could you try this one, please?



As soon as possible, sure.



-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-30 Thread Christian Perrier
Quoting Miklos Vajna ([EMAIL PROTECTED]):
> On Sun, Jun 29, 2008 at 05:51:34PM +0200, Miklos Vajna <[EMAIL PROTECTED]> 
> wrote:
> > I'll send a patch to correct this later tonight.
> 
> Could you try this one, please?

Tried it.


The failure message changed..:-)
[GIT] commit of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') 
failed: 


2008-06-30 09:00:55: Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/Pootle/users.py", line 259, in handle
page = self.getpage(pathwords, session, argdict)
  File "/usr/lib/python2.4/site-packages/Pootle/pootle.py", line 523, in getpage
return indexpage.ProjectIndex(project, session, argdict, dirfilter)
  File "/usr/lib/python2.4/site-packages/Pootle/indexpage.py", line 321, in 
__init__
self.handleactions()
  File "/usr/lib/python2.4/site-packages/Pootle/indexpage.py", line 443, in 
handleactions
self.project.commitpofile(self.session, self.dirname, commitfile)
  File "/usr/lib/python2.4/site-packages/Pootle/projects.py", line 599, in 
commitpofile
versioncontrol.commitfile(pathname, message="Commit from %s by user %s. %s" 
%
  File 
"/usr/lib/python2.4/site-packages/translate/storage/versioncontrol/__init__.py",
 line 292, in commitfile
return get_versioned_object(filename).commit(message)
  File 
"/usr/lib/python2.4/site-packages/translate/storage/versioncontrol/git.py", 
line 73, in commit
raise IOError("[GIT] commit of ('%s', '%s') failed: %s" \
IOError: [GIT] commit of ('/var/lib/pootle/di/level2/tasksel', 
'debian/po/fr.po') failed:



-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-29 Thread Miklos Vajna
On Sun, Jun 29, 2008 at 05:51:34PM +0200, Miklos Vajna <[EMAIL PROTECTED]> 
wrote:
> I'll send a patch to correct this later tonight.

Could you try this one, please?
Index: translate/storage/versioncontrol/git.py
===
--- translate/storage/versioncontrol/git.py (revision 7679)
+++ translate/storage/versioncontrol/git.py (working copy)
@@ -39,17 +39,23 @@
 """
 import os
 return os.path.join(self.root_dir, self.RCS_METADIR)
+
+def _get_git_command(self, args):
+"""prepends generic git arguments to conrete ones
+"""
+command = ["git", "--git-dir", self._get_git_dir(), "--work-tree", 
self.root_dir]
+command.extend(args)
+return command
 
 def update(self, revision=None):
 """Does a clean update of the given path"""
 # git checkout
-command = ["git", "--git-dir", self._get_git_dir(),
-"checkout", self.location_rel]
+command = self._get_git_command(["checkout", self.location_rel])
 exitcode, output_checkout, error = run_command(command)
 if exitcode != 0:
 raise IOError("[GIT] checkout failed (%s): %s" % (command, error))
 # pull changes
-command = ["git", "--git-dir", self._get_git_dir(), "pull"]
+command = self._get_git_command(["pull"])
 exitcode, output_pull, error = run_command(command)
 if exitcode != 0:
 raise IOError("[GIT] pull failed (%s): %s" % (command, error))
@@ -58,14 +64,13 @@
 def commit(self, message=None):
 """Commits the file and supplies the given commit message if present"""
 # add the file
-command = ["git", "--git-dir", self._get_git_dir(),
-"add", self.location_rel]
+command = self._get_git_command(["add", self.location_rel])
 exitcode, output_add, error = run_command(command)
 if exitcode != 0:
 raise IOError("[GIT] add of ('%s', '%s') failed: %s" \
 % (self.root_dir, self.location_rel, error))
 # commit file
-command = ["git", "--git-dir", self._get_git_dir(), "commit"]
+command = self._get_git_command(["commit"])
 if message:
 command.extend(["-m", message])
 exitcode, output_commit, error = run_command(command)
@@ -73,7 +78,7 @@
 raise IOError("[GIT] commit of ('%s', '%s') failed: %s" \
 % (self.root_dir, self.location_rel, error))
 # push changes
-command = ["git", "--git-dir", self._get_git_dir(), "push"]
+command = self._get_git_command(["push"])
 exitcode, output_push, error = run_command(command)
 if exitcode != 0:
 raise IOError("[GIT] push of ('%s', '%s') failed: %s" \
@@ -83,8 +88,7 @@
 def getcleanfile(self, revision=None):
 """Get a clean version of a file from the git repository"""
 # run git-show
-command = ["git", "--git-dir", self._get_git_dir(), "show",
-"HEAD:%s" % self.location_rel]
+command = self._get_git_command(["show", "HEAD:%s" % 
self.location_rel])
 exitcode, output, error = run_command(command)
 if exitcode != 0:
 raise IOError("[GIT] 'show' failed for ('%s', %s): %s" \


pgpffv8ox0KWT.pgp
Description: PGP signature
-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


Re: [translate-pootle] Still problems committing with git

2008-06-29 Thread Miklos Vajna
On Sun, Jun 29, 2008 at 02:39:52PM +0200, Christian Perrier <[EMAIL PROTECTED]> 
wrote:
> Trace:
> 
> 2008-06-29 13:58:19: Traceback (most recent call last):
>   File "/usr/lib/python2.4/site-packages/Pootle/users.py", line 259, in handle
> page = self.getpage(pathwords, session, argdict)
>   File "/usr/lib/python2.4/site-packages/Pootle/pootle.py", line 523, in 
> getpage
> return indexpage.ProjectIndex(project, session, argdict, dirfilter)
>   File "/usr/lib/python2.4/site-packages/Pootle/indexpage.py", line 321, in 
> __init__
> self.handleactions()
>   File "/usr/lib/python2.4/site-packages/Pootle/indexpage.py", line 443, in 
> handleactions
> self.project.commitpofile(self.session, self.dirname, commitfile)
>   File "/usr/lib/python2.4/site-packages/Pootle/projects.py", line 599, in 
> commitpofile
> versioncontrol.commitfile(pathname, message="Commit from %s by user %s. 
> %s" %
>   File 
> "/usr/lib/python2.4/site-packages/translate/storage/versioncontrol/__init__.py",
>  line 292, in commitfile
> return get_versioned_object(filename).commit(message)
>   File 
> "/usr/lib/python2.4/site-packages/translate/storage/versioncontrol/git.py", 
> line 60, in commit
> raise IOError("[GIT] add of ('%s', '%s') failed: %s" \
> IOError: [GIT] add of ('/var/lib/pootle/di/level2/tasksel', 
> 'debian/po/fr.po') failed: fatal: pathspec 'debian/po/fr.po' did not match 
> any files

Thanks.

The fix seem to be to use the --work-tree option as well:

Example:

$ git --git-dir git/test/.git add HACKING
fatal: pathspec 'HACKING' did not match any files

I think this is the current situation.

$ git --git-dir git/test/.git --work-tree git/test add HACKING

And this works fine.

I'll send a patch to correct this later tonight.


pgp9iV75zeEHZ.pgp
Description: PGP signature
-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle


[translate-pootle] Still problems committing with git

2008-06-29 Thread Christian Perrier
> > Now, 1.5.5. But I now have to check if the problem is still here.
> 
> There are apparently some problems  remaining, still.


There are.

I have a project on i18n.debian.org that uses a git repository as
reference. The repo was cloned with a login that has commit access to
the repository.

Even though I'm using an up-to-date git, I get:

Erreur
[GIT] add of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') failed: 
fatal: pathspec 'debian/po/fr.po' did not match any files 
Retour

While runnins "git status" in the relevant directory, I get:
# On branch master
# Changed but not updated:
#   (use "git add ..." to update what will be committed)
#
#   modified:   debian/po/fr.po
#

If I run the commit then push attempt from command line, it works as
expected.


Trace:

2008-06-29 13:58:19: Traceback (most recent call last):
  File "/usr/lib/python2.4/site-packages/Pootle/users.py", line 259, in handle
page = self.getpage(pathwords, session, argdict)
  File "/usr/lib/python2.4/site-packages/Pootle/pootle.py", line 523, in getpage
return indexpage.ProjectIndex(project, session, argdict, dirfilter)
  File "/usr/lib/python2.4/site-packages/Pootle/indexpage.py", line 321, in 
__init__
self.handleactions()
  File "/usr/lib/python2.4/site-packages/Pootle/indexpage.py", line 443, in 
handleactions
self.project.commitpofile(self.session, self.dirname, commitfile)
  File "/usr/lib/python2.4/site-packages/Pootle/projects.py", line 599, in 
commitpofile
versioncontrol.commitfile(pathname, message="Commit from %s by user %s. %s" 
%
  File 
"/usr/lib/python2.4/site-packages/translate/storage/versioncontrol/__init__.py",
 line 292, in commitfile
return get_versioned_object(filename).commit(message)
  File 
"/usr/lib/python2.4/site-packages/translate/storage/versioncontrol/git.py", 
line 60, in commit
raise IOError("[GIT] add of ('%s', '%s') failed: %s" \
IOError: [GIT] add of ('/var/lib/pootle/di/level2/tasksel', 'debian/po/fr.po') 
failed: fatal: pathspec 'debian/po/fr.po' did not match any files

(the git clone is in /var/lib/pootle/di/level2/tasksel and the
modified file is really debian/po/fr.po


-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
___
Translate-pootle mailing list
Translate-pootle@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/translate-pootle