From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id AF2931381F3 for ; Tue, 21 May 2013 10:43:01 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 04E51E0810; Tue, 21 May 2013 10:43:01 +0000 (UTC) Received: from momout1-smtp.messagingengine.com (momout1-smtp.messagingengine.com [66.111.4.229]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 6D241E0810 for ; Tue, 21 May 2013 10:43:00 +0000 (UTC) Received: from compute2.internal (compute2.nyi.mail.srv.osa [10.202.2.42]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id DAA1EDD; Tue, 21 May 2013 06:42:59 -0400 (EDT) Received: from frontend2.nyi.mail.srv.osa ([10.202.2.161]) by compute2.internal (MEProxy); Tue, 21 May 2013 06:42:59 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-type:to:subject:references:date :mime-version:content-transfer-encoding:from:message-id :in-reply-to; s=smtpout; bh=mu80zYSC9jRKPb3OCHHLdZF+8c4=; b=KVMP jJu0P1VXUa/Ns82tKpld6qdHIKuqQ9DJJlIznZ055CKlpbuPCnZHcDx5PNqVPggL 5q5diHp8FsYaQZQUFw8m0c83hQBzp7EzwQJTbyBpaf1v0aKirwlmrWm6IHaaFqxE 8kBYKWnuR/VULsBKbUJpqobUxV9ZzwOyM2UoItM= X-Sasl-enc: axjz0Ez7SOg75xeQWVpqvLRVipQoQTivbC2q69vLK87H 1369132979 Received: from verkdatorn.npdb (unknown [94.25.229.68]) by mail.messagingengine.com (Postfix) with ESMTPA id 365F9200099; Tue, 21 May 2013 06:42:59 -0400 (EDT) Content-Type: text/plain; charset=utf-8; format=flowed; delsp=yes To: gentoo-python@lists.gentoo.org, "IAN DELANEY" Subject: Re: [gentoo-python] recent trend of django-foo tests References: <20130520170533.462ab085@archtester.homenetwork> <20130521013616.694f7026@archtester.homenetwork> <20130522013524.6a288215@archtester.homenetwork> Date: Tue, 21 May 2013 14:42:55 +0400 Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Discussions centering around the Python ecosystem in Gentoo Linux X-BeenThere: gentoo-python@gentoo.org X-BeenThere: gentoo-python@lists.gentoo.org MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: "Nikolaj Sjujskij" Message-ID: In-Reply-To: <20130522013524.6a288215@archtester.homenetwork> User-Agent: Opera Mail/12.15 (Linux) X-Archives-Salt: fb1269ce-0eb7-486f-a609-d099621c766c X-Archives-Hash: 33d604811b9e73e3904746185cc251fc Den 2013-05-21 21:35:24 skrev IAN DELANEY : > On Tue, 21 May 2013 12:56:50 +0400 > "Nikolaj Sjujskij" wrote: > >> Den 2013-05-20 20:37:53 skrev IAN DELANEY : >> >>> Ja, tack tack for att forsoka, med nej. (Please add the grammatical >>> nice-ities to the vowel o). >> I've got bad news for you: actually my native language is Russian :) >> > Oh dear, more bad news, this isn't a good week. Header read; > "Den 2013-05-20 20:37:53 skrev" > Den is 'the', skrev is wrote in swedish. Yep, my email client speaks Swedish :) >>> I got a fix from #django on the second >>> attempt. I was close on the first attempt, so for the benefit of >>> all, >>> >>> first export SECRET_KEY='green', followed by >>> >>> - "from django.conf import \ >>> global_settings;global_settings.SECRET_KEY='green'" ${test} >>> + "from django.conf import \ >>> global_settings;global_settings.SECRET_KEY='$SECRET_KEY'" ${test} > well I'm open to an explanation too, but in brief, he said set the key > in bash, then on a second attempt on re-reading my query more closely, > he corrected it to the above. An alternate was SECRET_KEY="green" > python -c ..., that is pre-pending the setting of the secret key to the > call to python, which should work if you try. I settled for the above. I mean, python should ignore (and it does for me) arguments after -c option, however you do that in bash: % python global_settings.py % python -c "print('$LANG')" global_settings.py ru_RU.UTF-8 I'm not sure you understand my code snippets correctly. I demonstrate how python ignores "global_settings.py" argument and doesn't run the script whose name was passed after `-c ` option. >> I positively fail to see how that change could fix anything. >> % python global_settings.py >> > '/usr/lib64/python2.7/site-packages/django/conf/global_settings.pyc'> >> > I'm guessing here the manufactured global_settings.py could be used > effectively, I'd have to go back and try some more to do so. But hey > thx for the effort. >> % python -c 'import sys; print sys.platform' global_settings.py >> linux2 >> >>> and presto. >>> >>> * python2_7: running distutils-r1_run_phase python_test >>> * test test_compiler.py passed under python2.7 >>> * test test_compressor.py passed under python2.7 >>> another bug bites the dust. >> Well, if that somehow had worked, it's all right, I guess. >> > a good news snippet to offset the bad. What can I say? I'm just pointing out that I for one can't understand what's happening there and why it seems to work while it shouldn't. Therefore it may break again unexpectedly, so just keep that in mind :)