I am going to have to agree with your colleague. I use Django a lot and you
are editing config.py and urls.py which are all python code.
On Thu, Dec 4, 2008 at 10:30 PM, Bruno Desthuilliers <
[EMAIL PROTECTED]> wrote:
> HT a écrit :
>
>> A colleague of mine is arguing that since it is easy to wri
HT a écrit :
A colleague of mine is arguing that since it is easy to write config like:
FOO = {'bar': ('a': 'b'), 'abc': ('z': 'x')}
in config.py and just import it to get FOO, but difficult to achieve the
same using an ini file and ConfigParser, and since Python files are just
text, we should
On Thu, 4 Dec 2008 at 11:35, HT wrote:
I can think of lots of arguments why this is a bad idea, but I don't
seem to be able to think of a really convincing one.
I think it depends on the problem domain. As someone else said, there
are issues with being able to inject arbitrary code via the con
Chris Rebert wrote:
> On Thu, Dec 4, 2008 at 11:35 AM, HT <[EMAIL PROTECTED]> wrote:
>> FOO = {'bar': ('a': 'b'), 'abc': ('z': 'x')}
>
> I'll assume you meant ('a', 'b') as colons in parens don't make sense.
Yes, sorry.
> Well, it is pretty weird to be allowed to put arbitrary code in a mere
> c
On 4 Dec, 19:35, HT <[EMAIL PROTECTED]> wrote:
> A colleague of mine is arguing that since it is easy to write config like:
>
> FOO = {'bar': ('a': 'b'), 'abc': ('z': 'x')}
>
> in config.py and just import it to get FOO, but difficult to achieve the
> same using an ini file and ConfigParser, and si
On Thu, Dec 4, 2008 at 11:35 AM, HT <[EMAIL PROTECTED]> wrote:
> A colleague of mine is arguing that since it is easy to write config like:
>
> FOO = {'bar': ('a': 'b'), 'abc': ('z': 'x')}
I'll assume you meant ('a', 'b') as colons in parens don't make sense.
>
> in config.py and just import it t