Re: Language extensions in programs under /usr/bin
On Tue, Oct 07, 2003 at 06:07:58PM -0400, Marco Paganini wrote: On Tue, Oct 07, 2003 at 05:57:42PM -0400, Daniel Burrows wrote: That would not be a problem, as no other program imports ask.py... Are you confident that no other program will ever want to import ask? Yes. ask.py is just the main executable. It imports all the other modules (which have the .py extension and should be in /usr/lib/ask or something). That'd be /usr/share (lib is for arch-dependant data, see FHS) -- Robert Millan [..] but the delight and pride of Aule is in the deed of making, and in the thing made, and neither in possession nor in his own mastery; wherefore he gives and hoards not, and is free from care, passing ever on to some new work. -- J.R.R.T, Ainulindale (Silmarillion)
Re: Language extensions in programs under /usr/bin
On Tue, Oct 07, 2003 at 06:37:31PM -0400, Daniel Burrows wrote: On Tue, Oct 07, 2003 at 06:07:58PM -0400, Marco Paganini [EMAIL PROTECTED] was heard to say: On Tue, Oct 07, 2003 at 05:57:42PM -0400, Daniel Burrows wrote: That would not be a problem, as no other program imports ask.py... Are you confident that no other program will ever want to import ask? Yes. ask.py is just the main executable. It imports all the other modules (which have the .py extension and should be in /usr/lib/ask or something). Sorry that I'm not letting this go, but I'm not sure you understand my concern (I'm not sure that this is a showstopper, but I'd like to know that you've at least considered it) It could be called a-s-k, too. What do you think Marco? -- Robert Millan [..] but the delight and pride of Aule is in the deed of making, and in the thing made, and neither in possession nor in his own mastery; wherefore he gives and hoards not, and is free from care, passing ever on to some new work. -- J.R.R.T, Ainulindale (Silmarillion)
Re: Language extensions in programs under /usr/bin
On Wed, Oct 08, 2003 at 12:19:58AM +, Robert Millan wrote: On Tue, Oct 07, 2003 at 06:07:58PM -0400, Marco Paganini wrote: Yes. ask.py is just the main executable. It imports all the other modules (which have the .py extension and should be in /usr/lib/ask or something). That'd be /usr/share (lib is for arch-dependant data, see FHS) ... except that the Python policy seems to have bizarre rules about this. I assume this is because .pyc files are placed in the same directory as the corresponding .py files and are architecture-dependent. -- Colin Watson [EMAIL PROTECTED]
Re: Language extensions in programs under /usr/bin
On Wed, Oct 08, 2003 at 09:57:42AM +0100, Colin Watson wrote: | That'd be /usr/share (lib is for arch-dependant data, see FHS) | | ... except that the Python policy seems to have bizarre rules about | this. I assume this is because .pyc files are placed in the same | directory as the corresponding .py files and are architecture-dependent. I don't think it's the .pyc files, AFAIK they're just architecture independent bytecode. I believe it's because some Python modules come with blah.so files which need to live with their corresponding blah.py files, so they can't be put into /usr/share. Cameron.
Re: Language extensions in programs under /usr/bin
On Mon, Oct 06, 2003 at 08:26:44PM -0400, Marco Paganini wrote: I'm packaging a Python program called ask for distribution. Currently, the main executable is called ask.py. a. Whack upstream with a cluebat. b. Repeat a. c. What happens when the program gets reimplemented in another language? d. Keep repeating a. -- Marcelo
Re: Language extensions in programs under /usr/bin
On Mon, Oct 06, 2003 at 07:50:07PM -0500, John Hasler wrote: Besides, if dumb names were a problem we'd do something about openoffice.org. $ ls /usr/bin/*openoffice* /usr/bin/openoffice What is dumb about that? The thread is about naming of files within /usr/bin. Chris pgpsBIj7fhkCn.pgp Description: PGP signature
Re: Language extensions in programs under /usr/bin
I'm packaging a Python program called ask for distribution. Currently, the main executable is called ask.py. a. Whack upstream with a cluebat. Euh, I think you messed up. Marco *is* upstream. On the other hand, Marco being upstream defeats John's argument: Leave it. The program will be known as ask.py everywhere outside Debian. Changing the name is asking for confusion. So perhaps the discussion should be retaken. P.S: keep me on CC, i'm not subscribed. -- Robert Millan [..] but the delight and pride of Aule is in the deed of making, and in the thing made, and neither in possession nor in his own mastery; wherefore he gives and hoards not, and is free from care, passing ever on to some new work. -- J.R.R.T, Ainulindale (Silmarillion)
Re: Language extensions in programs under /usr/bin
On Tue, Oct 07, 2003 at 01:24:37PM +, Robert Millan wrote: I'm packaging a Python program called ask for distribution. Currently, the main executable is called ask.py. a. Whack upstream with a cluebat. Euh, I think you messed up. Marco *is* upstream. So perhaps the discussion should be retaken. I'm pretty sure I remember a discussion earlier this year about this exact same topic. Basically, the result came down to scripts shouldn't have language-specific extensions, because they add nothing useful, and because the program could be rewritten in another language to do exactly the same thing, and so the language extension would then be incorrect. Unfortunately, I can't find the discussion, so I can't give more details. But, in this case, I'd suggest that the author find a better name. If 'ask' is a common word, and shouldn't be used as a command, then surely the same applies to 'ask.py' - after all, someone else could write another 'ask' script in Python, and apply the same logic - which would result in a name clash again. Oops. P.S: keep me on CC, i'm not subscribed. Done. - Matt
Re: Language extensions in programs under /usr/bin
Chris writes: $ ls /usr/bin/*openoffice* /usr/bin/openoffice What is dumb about that? The thread is about naming of files within /usr/bin. Since the package is named openoffice.org supposedly for trademark reasons I assumed that the binary was as well. -- John Hasler [EMAIL PROTECTED] (John Hasler) Dancing Horse Hill Elmwood, WI
Re: Language extensions in programs under /usr/bin
a. Whack upstream with a cluebat. Euh, I think you messed up. Marco *is* upstream. That doesn't preclude whackig upstream with a cluebat :-) Here, he can use mine. -- Marcelo
Re: Language extensions in programs under /usr/bin
On Mon, Oct 06, 2003 at 08:26:44PM -0400, Marco Paganini [EMAIL PROTECTED] was heard to say: I'm packaging a Python program called ask for distribution. Currently, the main executable is called ask.py. It seems unusual (and why not say, *ugly*) to have the language extension added to the program, but in this case, it was a deliberate decision to avoid clash with any other programs (ask is a pretty common name) under /usr/bin. What is the Debian policy on this? What would be the best approach, to leave the program as ask.py (unusual) or rename it to ask (possibility of name conflicts and breakage of existing installations)? I think it's worth pointing out that if a file called ask.py is in /usr/bin, the statement: import ask from a Python program in /usr/bin which hasn't modified its sys.path will, unless I am terribly confused, pick up ask.py instead of whatever module it was looking for. I'm not aware of any module named ask right now, but I can certainly imagine someone creating one. Daniel -- / Daniel Burrows [EMAIL PROTECTED] ---\ | Put no trust in cryptic comments. | \-- A duck! -- http://www.python.org -/
Re: Language extensions in programs under /usr/bin
Marco Paganini wrote: I'm packaging a Python program called ask for distribution. Currently, the main executable is called ask.py. It seems unusual (and why not say, *ugly*) to have the language extension added to the program, but in this case, it was a deliberate decision to avoid clash with any other programs (ask is a pretty common name) under /usr/bin. What is the Debian policy on this? What would be the best approach, to leave the program as ask.py (unusual) or rename it to ask (possibility of name conflicts and breakage of existing installations)? Please rename it to 'ask' or to something better. See debian-policy thread (msgid [EMAIL PROTECTED]) policy should frown on programs in PATH with language extentions (ie, .pl) Cheers, -- Bill. [EMAIL PROTECTED] Imagine a large red swirl here.
Re: Language extensions in programs under /usr/bin
Hi Marcello, Euh, I think you messed up. Marco *is* upstream. That doesn't preclude whackig upstream with a cluebat :-) Here, he can use mine. I tried whacking myself repeatedly with the cluebat. Unfortunately, it was not as effective as whacking someone else. But I think I got the clue anyway. :) Regards, Paga -- Marco Paganini | UNIX / Linux / Networking [EMAIL PROTECTED] | PGP: http://www.paganini.net/pgp/ http://www.paganini.net | Magnus Frater te spectat...
Re: Language extensions in programs under /usr/bin
Hi Daniel, I think it's worth pointing out that if a file called ask.py is in /usr/bin, the statement: import ask from a Python program in /usr/bin which hasn't modified its sys.path will, unless I am terribly confused, pick up ask.py instead of whatever module it was looking for. I'm not aware of any module named ask right now, but I can certainly imagine someone creating one. That would not be a problem, as no other program imports ask.py... Regards, Paga Daniel -- / Daniel Burrows [EMAIL PROTECTED] ---\ | Put no trust in cryptic comments. | \-- A duck! -- http://www.python.org -/ -- Marco Paganini | UNIX / Linux / Networking [EMAIL PROTECTED] | PGP: http://www.paganini.net/pgp/ http://www.paganini.net | Magnus Frater te spectat...
Re: Language extensions in programs under /usr/bin
On Tue, Oct 07, 2003 at 05:57:42PM -0400, Daniel Burrows wrote: That would not be a problem, as no other program imports ask.py... Are you confident that no other program will ever want to import ask? Yes. ask.py is just the main executable. It imports all the other modules (which have the .py extension and should be in /usr/lib/ask or something). Regards, Paga -- / Daniel Burrows [EMAIL PROTECTED] ---\ | We've got nothing to fear but the stuff that we're | | afraid of! -- Fluble | \-Evil Overlord, Inc: planning your future today. http://www.eviloverlord.com-/ -- Marco Paganini | UNIX / Linux / Networking [EMAIL PROTECTED] | PGP: http://www.paganini.net/pgp/ http://www.paganini.net | Magnus Frater te spectat...
Re: Language extensions in programs under /usr/bin
On Tue, Oct 07, 2003 at 05:48:17PM -0400, Marco Paganini [EMAIL PROTECTED] was heard to say: Hi Daniel, I think it's worth pointing out that if a file called ask.py is in /usr/bin, the statement: import ask from a Python program in /usr/bin which hasn't modified its sys.path will, unless I am terribly confused, pick up ask.py instead of whatever module it was looking for. I'm not aware of any module named ask right now, but I can certainly imagine someone creating one. That would not be a problem, as no other program imports ask.py... Are you confident that no other program will ever want to import ask? Daniel -- / Daniel Burrows [EMAIL PROTECTED] ---\ | We've got nothing to fear but the stuff that we're | | afraid of! -- Fluble | \-Evil Overlord, Inc: planning your future today. http://www.eviloverlord.com-/
Re: Language extensions in programs under /usr/bin
Hi, Yes. ask.py is just the main executable. It imports all the other modules (which have the .py extension and should be in /usr/lib/ask or something). That'd be /usr/share (lib is for arch-dependant data, see FHS) Oops, sorry! Slippery fingers. I meant /usr/share... Regards, Paga -- Robert Millan [..] but the delight and pride of Aule is in the deed of making, and in the thing made, and neither in possession nor in his own mastery; wherefore he gives and hoards not, and is free from care, passing ever on to some new work. -- J.R.R.T, Ainulindale (Silmarillion) -- Marco Paganini | UNIX / Linux / Networking [EMAIL PROTECTED] | PGP: http://www.paganini.net/pgp/ http://www.paganini.net | Magnus Frater te spectat...
Re: Language extensions in programs under /usr/bin
On Tue, Oct 07, 2003 at 06:07:58PM -0400, Marco Paganini [EMAIL PROTECTED] was heard to say: On Tue, Oct 07, 2003 at 05:57:42PM -0400, Daniel Burrows wrote: That would not be a problem, as no other program imports ask.py... Are you confident that no other program will ever want to import ask? Yes. ask.py is just the main executable. It imports all the other modules (which have the .py extension and should be in /usr/lib/ask or something). Sorry that I'm not letting this go, but I'm not sure you understand my concern (I'm not sure that this is a showstopper, but I'd like to know that you've at least considered it) Say next year I decide to write a new library of Python routines. For whatever reason, I decide that I want to call it ask. So I put my code in ask.py, and distribute it as a standard Python module. Now, some programmer writes a program which uses my ask module. When this program is run on a computer containing your ask.py program, it will run your program instead of loading my module. The main reason that I see for not being concerned about this is that no-one will write an ask module -- the name is too short, too generic, and it's not obvious what an ask module would do. On the other hand, a few days ago I'd have said the same thing about an ask program. I hope that's clearer. Daniel -- / Daniel Burrows [EMAIL PROTECTED] ---\ |Witches and pickles went together like...she hesitated at | | the stomach-curdling addition of peaches and cream, and | | mentally substituted 'things that went together very well' | | -- Terry Pratchett | \-- A duck! -- http://www.python.org -/
Language extensions in programs under /usr/bin
Hi all, I'm packaging a Python program called ask for distribution. Currently, the main executable is called ask.py. It seems unusual (and why not say, *ugly*) to have the language extension added to the program, but in this case, it was a deliberate decision to avoid clash with any other programs (ask is a pretty common name) under /usr/bin. What is the Debian policy on this? What would be the best approach, to leave the program as ask.py (unusual) or rename it to ask (possibility of name conflicts and breakage of existing installations)? Regards, Paga -- Marco Paganini | UNIX / Linux / Networking [EMAIL PROTECTED] | PGP: http://www.paganini.net/pgp/ http://www.paganini.net | Magnus Frater te spectat...
Re: Language extensions in programs under /usr/bin
Paga writes: What would be the best approach, to leave the program as ask.py (unusual) or rename it to ask (possibility of name conflicts and breakage of existing installations)? Leave it. The program will be known as ask.py everywhere outside Debian. Changing the name is asking for confusion. Besides, if dumb names were a problem we'd do something about openoffice.org. -- John Hasler [EMAIL PROTECTED] Dancing Horse Hill Elmwood, Wisconsin
Re: Language extensions in programs under /usr/bin
On Mon, Oct 06, 2003 at 07:50:07PM -0500, John Hasler wrote: Besides, if dumb names were a problem we'd do something about openoffice.org. Besides, for people who work with Python they often see the .py extension and don't consider it any more dumb than, say, .pl, .sh, .rb(?) and others. -- Steve C. Lamb | I'm your priest, I'm your shrink, I'm your PGP Key: 8B6E99C5 | main connection to the switchboard of souls. ---+- signature.asc Description: Digital signature
Re: Language extensions in programs under /usr/bin
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Well, so far, it's keep the extension, which is good as it won't break existing installations and create confusion... Thanks, Paga On Mon, Oct 06, 2003 at 05:55:48PM -0700, Steve C. Lamb wrote: On Mon, Oct 06, 2003 at 07:50:07PM -0500, John Hasler wrote: Besides, if dumb names were a problem we'd do something about openoffice.org. Besides, for people who work with Python they often see the .py extension and don't consider it any more dumb than, say, .pl, .sh, .rb(?) and others. -- Steve C. Lamb | I'm your priest, I'm your shrink, I'm your PGP Key: 8B6E99C5 | main connection to the switchboard of souls. ---+- - -- Marco Paganini | UNIX / Linux / Networking [EMAIL PROTECTED] | PGP: http://www.paganini.net/pgp/ http://www.paganini.net | Magnus Frater te spectat... -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.2 (GNU/Linux) iD8DBQE/ghPML2FWjNfH2XwRAsw2AJsH8Iu6qPLVlEZhRadGRW13fQie9ACeNCgt 1itXNAX3b1okmiUEQWFwu6g= =MVU/ -END PGP SIGNATURE-