1 |
On Mon, 29 Aug 2011 21:05:20 +0200 |
2 |
Fabian Groffen <grobian@g.o> wrote: |
3 |
|
4 |
> On 29-08-2011 11:42:03 +0200, Fabian Groffen wrote: |
5 |
> > On 29-08-2011 11:30:46 +0200, Burcin Erocal wrote: |
6 |
> > > > "--dir-file=%s/dir %s/%s" % (EPREFIX, inforoot, inforoot, |
7 |
> > > > x))[1] TypeError: not all arguments converted during string |
8 |
> > > > formatting |
9 |
> > > |
10 |
> > > I also ran into this last week. The following patch fixes the |
11 |
> > > problem for me. It seems to be introduced in the prefix version |
12 |
> > > of portage. |
13 |
> > > |
14 |
> > |
15 |
> > Thanks, there was a bug about it, I now see there is a ) missing. |
16 |
> > I'll apply your patch soon. |
17 |
> |
18 |
> I've been looking at default, and didn't find extra parenthesis there, |
19 |
> so I tried the following. Does that work for you? |
20 |
> |
21 |
> http://git.overlays.gentoo.org/gitweb/?p=proj/portage.git;a=commitdiff;h=749ef8e20137bede1a9824448b2676224b06f71b;hp=5b6156b085ab5ae518fa6c4ed9b2e2c5b75fd184 |
22 |
> or |
23 |
> http://prefix.gentooexperimental.org:8000/portage-prefix/rev/4e2a4854863a |
24 |
|
25 |
I didn't have time to test the patch myself, since we already have a |
26 |
report of it not working, here is a justification for my patch... |
27 |
|
28 |
AFAICT, the original error message indicates that more arguments are |
29 |
provided to % than there are place holders in the string. The + |
30 |
operator has lower precedence than %, so the string is not concatenated |
31 |
with the part on the previous line. Note that the string in the error |
32 |
message has 3 place holders only, the fourth should come from the line |
33 |
above. I added parenthesis around the string addition to fix the |
34 |
precedence problem. |
35 |
|
36 |
|
37 |
Cheers, |
38 |
Burcin |