Gentoo Archives: gentoo-python

From: Nikolaj Sjujskij <sterkrig@×××××××.com>
To: gentoo-python@l.g.o, IAN DELANEY <della5@×××××××××.au>
Subject: Re: [gentoo-python] recent trend of django-foo tests
Date: Tue, 21 May 2013 08:56:59
Message-Id: op.wxfe40qch7emz2@verkdatorn.npdb
In Reply to: Re: [gentoo-python] recent trend of django-foo tests by IAN DELANEY
1 Den 2013-05-20 20:37:53 skrev IAN DELANEY <della5@×××××××××.au>:
2
3 > On Mon, 20 May 2013 13:18:53 +0400
4 > "Nikolaj Sjujskij" <sterkrig@×××××××.com> wrote:
5 >
6 >> Den 2013-05-20 13:05:33 skrev IAN DELANEY <della5@×××××××××.au>:
7 >>
8 >> ...
9 >> -c cmd : program passed in as string (_terminates option list_)
10 >>
11 >> So ${test} seems to be ignored or misinterpreted.
12 >>
13 >>
14 >> You could try creating ./global_settings.py in :
15 >>
16 >> from django.conf import global_settings
17 >> global_settings.SECRET_KEY='green'
18 >>
19 >> print(global_settings) # testing purposes!
20 >>
21 >> Now:
22 >> % python -c 'import global_settings'
23 >> <module 'django.conf.global_settings' from
24 >> '/usr/lib64/python2.7/site-packages/django/conf/global_settings.pyc'>
25 >
26 > Ja, tack tack for att forsoka, med nej. (Please add the grammatical
27 > nice-ities to the vowel o).
28 I've got bad news for you: actually my native language is Russian :)
29
30 > I got a fix from #django on the second
31 > attempt. I was close on the first attempt, so for the benefit of all,
32 >
33 > first export SECRET_KEY='green', followed by
34 >
35 > - "from django.conf import \
36 > global_settings;global_settings.SECRET_KEY='green'" ${test}
37 > + "from django.conf import \
38 > global_settings;global_settings.SECRET_KEY='$SECRET_KEY'" ${test}
39 I positively fail to see how that change could fix anything.
40
41 % python global_settings.py
42 <module 'django.conf.global_settings' from
43 '/usr/lib64/python2.7/site-packages/django/conf/global_settings.pyc'>
44
45 % python -c 'import sys; print sys.platform' global_settings.py
46 linux2
47
48 > and presto.
49 >
50 > * python2_7: running distutils-r1_run_phase python_test
51 > * test test_compiler.py passed under python2.7
52 > * test test_compressor.py passed under python2.7
53 > another bug bites the dust.
54 Well, if that somehow had worked, it's all right, I guess.

Replies

Subject Author
Re: [gentoo-python] recent trend of django-foo tests IAN DELANEY <della5@×××××××××.au>