From: Alan McKinnon <alan.mckinnon@gmail.com>
To: gentoo-user@lists.gentoo.org
Subject: Re: [gentoo-user] bash stopped running python scripts...
Date: Tue, 4 Aug 2009 10:05:45 +0200 [thread overview]
Message-ID: <200908041005.45470.alan.mckinnon@gmail.com> (raw)
In-Reply-To: <4A775FF0.503@kutulu.org>
On Tuesday 04 August 2009 00:08:48 Mike Edenfield wrote:
> > I have the identical file, it works here.
>
> That's very odd, as everything I've read over the past hour indicates
> that it's not supposed to work if you put a shell script in that line,
> but that's clearly not always true.
I didn't diff it, just compared yours and mine visually
> What's the #! line in your /usr/bin/emerge file?
$ head /usr/bin/emerge
#!/usr/bin/python
# Copyright 2006-2009 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id: emerge 13131 2009-03-18 01:43:41Z zmedico $
import sys
# This block ensures that ^C interrupts are handled quietly.
try:
import signal
>
> > Your original post has a "X connection to localhost:11.0 broken" error,
> > which is mighty unusual. The error is common enough, but has nothing to
> > do with python.
>
> I know where that particular error is coming from. The first
> non-comment line in /usr/bin/emerge is "import sys". Since bash is
> interpreting the script instead of python, when it gets to that line, it
> runs ImageMagick's "import" command. It just indicates that bash
> ignored the #! line and kept going.
Ah, now stuff makes sense, like your reference to ImageMagick
> The bug Remy sent me to did have two working solutions: replacing the
> shell script with a symlink, or replacing "#!/usr/bin/python" with
> "#!/usr/bin/env python" in emerge/ebuild, both of which point the #!
> line at a real executable. I'm now curious why that shell script works
> for anyone.
--
alan dot mckinnon at gmail dot com
next prev parent reply other threads:[~2009-08-04 8:07 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-03 20:56 [gentoo-user] bash stopped running python scripts Mike Edenfield
2009-08-03 21:03 ` Alan McKinnon
2009-08-03 21:22 ` Mike Edenfield
2009-08-03 21:48 ` Alan McKinnon
2009-08-03 22:08 ` Mike Edenfield
2009-08-04 8:05 ` Alan McKinnon [this message]
2009-08-03 21:14 ` [gentoo-user] " Remy Blank
2009-08-03 21:28 ` Mike Edenfield
2009-08-04 11:13 ` Graham Murray
2009-08-04 12:59 ` Mike Edenfield
2009-08-04 17:41 ` Remy Blank
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200908041005.45470.alan.mckinnon@gmail.com \
--to=alan.mckinnon@gmail.com \
--cc=gentoo-user@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox