1 |
Den 2013-05-20 13:05:33 skrev IAN DELANEY <della5@×××××××××.au>: |
2 |
|
3 |
> |
4 |
> Am generally reluctant to enter things here, however this issues |
5 |
> appears apt. Recent versions of django-xxx packages' test suites have |
6 |
> made a habit of falling over, which is no surprise in itself, but they |
7 |
> have a new cause. They all expect to find a setting to SECRET_KEY |
8 |
> which is set in djang.conf.global_settings. |
9 |
> |
10 |
> For while I thought |
11 |
> |
12 |
> "${PYTHON}" -c "from django.conf import \ |
13 |
> global_settings;global_settings.SECRET_KEY='green'" ${test} |
14 |
> |
15 |
> did the trick but it seems that the ${test} after the import with -c " |
16 |
> " is discarded somehow and never actually run with the attempt to set |
17 |
> SECRET_KEY='green'. |
18 |
% python -h |
19 |
... |
20 |
-c cmd : program passed in as string (_terminates option list_) |
21 |
|
22 |
So ${test} seems to be ignored or misinterpreted. |
23 |
|
24 |
|
25 |
You could try creating ./global_settings.py in : |
26 |
|
27 |
from django.conf import global_settings |
28 |
global_settings.SECRET_KEY='green' |
29 |
|
30 |
print(global_settings) # testing purposes! |
31 |
|
32 |
Now: |
33 |
% python -c 'import global_settings' |
34 |
<module 'django.conf.global_settings' from |
35 |
'/usr/lib64/python2.7/site-packages/django/conf/global_settings.pyc'> |