Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #103575 > unrolled thread
| Started by | wrong.address.1@gmail.com |
|---|---|
| First post | 2016-02-27 03:18 -0800 |
| Last post | 2016-03-01 19:46 -0800 |
| Articles | 20 on this page of 113 — 30 participants |
Back to article view | Back to comp.lang.python
Everything good about Python except GUI IDE? wrong.address.1@gmail.com - 2016-02-27 03:18 -0800
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-27 22:36 +1100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-27 04:02 -0800
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-27 23:07 +1100
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-28 17:34 +1100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-27 23:39 -0800
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-28 19:49 +1100
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-28 19:44 +1100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 02:25 -0800
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-28 21:34 +1100
Re: Everything good about Python except GUI IDE? Gordon Levi <gordon@address.invalid> - 2016-02-29 00:08 +1100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 05:13 -0800
Re: Everything good about Python except GUI IDE? Gordon Levi <gordon@address.invalid> - 2016-02-29 00:24 +1100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 05:49 -0800
Re: Everything good about Python except GUI IDE? Chris Warrick <kwpolska@gmail.com> - 2016-02-28 15:00 +0100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 06:11 -0800
Re: Everything good about Python except GUI IDE? Chris Warrick <kwpolska@gmail.com> - 2016-02-28 15:26 +0100
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 08:50 -0800
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-29 11:39 +1100
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-29 11:54 +1100
Re: Everything good about Python except GUI IDE? Ben Finney <ben+python@benfinney.id.au> - 2016-02-29 12:05 +1100
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-29 12:13 +1100
Lineendings (was Everything good about Python except GUI IDE?) Rustom Mody <rustompmody@gmail.com> - 2016-02-28 17:39 -0800
Re: Lineendings (was Everything good about Python except GUI IDE?) Chris Angelico <rosuav@gmail.com> - 2016-02-29 12:49 +1100
Re: Lineendings (was Everything good about Python except GUI IDE?) Rustom Mody <rustompmody@gmail.com> - 2016-02-28 17:55 -0800
Re: Lineendings (was Everything good about Python except GUI IDE?) Chris Angelico <rosuav@gmail.com> - 2016-02-29 13:02 +1100
Re: Lineendings (was Everything good about Python except GUI IDE?) Rustom Mody <rustompmody@gmail.com> - 2016-02-28 18:08 -0800
Re: Lineendings (was Everything good about Python except GUI IDE?) Ben Finney <ben+python@benfinney.id.au> - 2016-02-29 13:35 +1100
Re: Lineendings (was Everything good about Python except GUI IDE?) Rustom Mody <rustompmody@gmail.com> - 2016-02-28 20:48 -0800
Re: Everything good about Python except GUI IDE? Mark Lawrence <breamoreboy@yahoo.co.uk> - 2016-02-28 17:09 +0000
Re: Everything good about Python except GUI IDE? Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-02-28 11:56 -0500
Re: Everything good about Python except GUI IDE? Gordon Levi <gordon@address.invalid> - 2016-03-02 20:44 +1100
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-28 23:50 +1100
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-29 04:53 +1100
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-29 13:22 +1100
Re: Everything good about Python except GUI IDE? Gregory Ewing <greg.ewing@canterbury.ac.nz> - 2016-02-29 17:40 +1300
Re: Everything good about Python except GUI IDE? "Sven R. Kunze" <srkunze@mail.de> - 2016-02-28 13:23 +0100
Re: Everything good about Python except GUI IDE? BartC <bc@freeuk.com> - 2016-02-28 12:38 +0000
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 04:54 -0800
Re: Everything good about Python except GUI IDE? BartC <bc@freeuk.com> - 2016-02-28 13:07 +0000
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 05:20 -0800
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-28 15:51 +0200
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 06:03 -0800
Re: Everything good about Python except GUI IDE? BartC <bc@freeuk.com> - 2016-02-28 14:29 +0000
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-29 11:49 +1100
Re: Everything good about Python except GUI IDE? BartC <bc@freeuk.com> - 2016-02-29 11:56 +0000
Re: Everything good about Python except GUI IDE? Terry Reedy <tjreedy@udel.edu> - 2016-02-28 19:49 -0500
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-28 17:08 +0200
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 08:41 -0800
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-28 23:38 +0200
Re: Everything good about Python except GUI IDE? Gordon Levi <gordon@address.invalid> - 2016-02-29 15:47 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-29 08:18 +0200
Re: Everything good about Python except GUI IDE? Rustom Mody <rustompmody@gmail.com> - 2016-02-28 23:20 -0800
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-29 19:20 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-29 10:37 +0200
Re: Everything good about Python except GUI IDE? Grant Edwards <invalid@invalid.invalid> - 2016-02-29 15:43 +0000
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-03-01 03:17 +1100
Re: Everything good about Python except GUI IDE? Grant Edwards <invalid@invalid.invalid> - 2016-02-29 18:17 +0000
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-03-01 05:31 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-29 10:25 +0200
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-29 19:33 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-29 10:46 +0200
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-03-02 03:44 +1100
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-03-02 05:07 +1100
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-03-02 13:22 +1100
Speaking of Javascript [was Re: Everything good about Python except GUI IDE?] Steven D'Aprano <steve@pearwood.info> - 2016-03-03 04:05 +1100
Re: Speaking of Javascript [was Re: Everything good about Python except GUI IDE?] Chris Angelico <rosuav@gmail.com> - 2016-03-03 04:46 +1100
Re: Speaking of Javascript [was Re: Everything good about Python except GUI IDE?] Jon Ribbens <jon+usenet@unequivocal.co.uk> - 2016-03-02 18:29 +0000
Re: Speaking of Javascript [was Re: Everything good about Python except GUI IDE?] Chris Angelico <rosuav@gmail.com> - 2016-03-03 07:55 +1100
Re: Speaking of Javascript [was Re: Everything good about Python except GUI IDE?] Jon Ribbens <jon+usenet@unequivocal.co.uk> - 2016-03-02 22:01 +0000
Re: Everything good about Python except GUI IDE? Terry Reedy <tjreedy@udel.edu> - 2016-02-29 21:33 -0500
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-03-01 15:31 +1100
Re: Everything good about Python except GUI IDE? Gordon Levi <gordon@address.invalid> - 2016-03-02 20:44 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-03-02 13:57 +0200
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-02-29 11:14 +1100
Re: Everything good about Python except GUI IDE? Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-02-28 12:08 -0500
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-03-02 03:35 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-03-01 20:06 +0200
Re: Everything good about Python except GUI IDE? wxjmfauth@gmail.com - 2016-03-01 11:30 -0800
Re: Everything good about Python except GUI IDE? wxjmfauth@gmail.com - 2016-03-01 11:39 -0800
Re: Everything good about Python except GUI IDE? Steven D'Aprano <steve@pearwood.info> - 2016-03-02 12:51 +1100
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-03-02 13:15 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-03-02 07:41 +0200
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-03-02 16:58 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-03-02 10:20 +0200
Re: Everything good about Python except GUI IDE? Christian Gollwitzer <auriocus@gmx.de> - 2016-03-02 23:00 +0100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-03-03 00:36 +0200
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-28 13:38 +0100
Re: Everything good about Python except GUI IDE? cl@isbd.net - 2016-02-28 12:52 +0000
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-28 14:19 +0100
Re: Everything good about Python except GUI IDE? Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2016-02-28 12:03 -0500
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-28 18:41 +0100
Re: Everything good about Python except GUI IDE? BartC <bc@freeuk.com> - 2016-02-27 13:35 +0000
Re: Everything good about Python except GUI IDE? MWS <miragewebstudio12@gmail.com> - 2016-02-27 20:05 +0530
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-27 15:20 +0100
Re: Everything good about Python except GUI IDE? wrong.address.1@gmail.com - 2016-02-27 10:13 -0800
Re: Everything good about Python except GUI IDE? Chris Angelico <rosuav@gmail.com> - 2016-02-28 05:29 +1100
Re: Everything good about Python except GUI IDE? Marko Rauhamaa <marko@pacujo.net> - 2016-02-27 20:35 +0200
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-27 19:51 +0100
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-28 00:20 +0100
Re: Everything good about Python except GUI IDE? Gordon Levi <gordon@address.invalid> - 2016-02-28 16:49 +1100
Re: Everything good about Python except GUI IDE? Sibylle Koczian <nulla.epistola@web.de> - 2016-02-28 11:46 +0100
Re: Everything good about Python except GUI IDE? Virgil Stokes <vs@it.uu.se> - 2016-02-28 12:26 +0100
Re: Everything good about Python except GUI IDE? Sibylle Koczian <nulla.epistola@web.de> - 2016-02-28 11:46 +0100
Re: Everything good about Python except GUI IDE? mm0fmf <none@invalid.com> - 2016-02-28 18:47 +0000
Re: Everything good about Python except GUI IDE? Dietmar Schwertberger <maillist@schwertberger.de> - 2016-02-28 20:09 +0100
Re: Everything good about Python except GUI IDE? Michael Torrie <torriem@gmail.com> - 2016-02-28 18:24 -0700
Re: Everything good about Python except GUI IDE? Mike S <mscir@yahoo.com> - 2016-03-02 23:27 -0800
Re: Everything good about Python except GUI IDE? Marco Kaulea <marco.kaulea@gmail.com> - 2016-02-27 18:57 +0100
Re: Everything good about Python except GUI IDE? Anthony Papillion <anthony@cajuntechie.org> - 2016-02-27 13:45 -0600
Re: Everything good about Python except GUI IDE? Mark Lawrence <breamoreboy@yahoo.co.uk> - 2016-02-27 20:52 +0000
Re: Everything good about Python except GUI IDE? MRAB <python@mrabarnett.plus.com> - 2016-02-27 21:35 +0000
Re: Everything good about Python except GUI IDE? Mike <termim@gmail.com> - 2016-03-01 19:46 -0800
Page 5 of 6 — ← Prev page 1 2 3 4 [5] 6 Next page →
| From | Steven D'Aprano <steve@pearwood.info> |
|---|---|
| Date | 2016-03-02 12:51 +1100 |
| Message-ID | <56d64730$0$1589$c3e8da3$5496439d@news.astraweb.com> |
| In reply to | #103809 |
On Wed, 2 Mar 2016 05:06 am, Marko Rauhamaa wrote:
> Steven D'Aprano <steve@pearwood.info>:
>
>> On Sun, 28 Feb 2016 11:38 pm, BartC wrote:
>>> It's the GUI users who are the Neanderthals, having to effectively
>>> point at things with sticks. Or have to physically move that rock
>>> themselves (ie. drag a file to a wastebasket).
>>
>> I haven't physically moved an icon to the wastebasket for years. I
>> point at the icon, right-click, and tell it "move yourself to the
>> trash".
>
> Do you find that interface convenient? Do you often find yourself
> clickety-clicking around to perform bulk file operations?
Sometimes. Especially with media files which display a thumbnail, it is far
more convenient to be able to look at the icon and recognise the file than
to try to guess from the filename "x73nfh.jpg". And having recognised the
file visually, its often easier to drag it into the folder of your choice
than to type "mv x7<tab> dir<tab>" in a separate window.
But not always. It's much easier to do "mv foo* dir<tab>". Horses for
courses.
>> Language is pretty important. But when you need to drive a nail into a
>> piece of wood, would you rather hit the nail with a hammer, or explain
>> to the hammer the precise direction and magnitude of force you would
>> like it to apply when it impacts the nails?
>
> I don't know. My everyday file manipulation needs are so diverse that I
> couldn't imagine how a GUI would make my life easier.
*shrug*
Then perhaps they're not as diverse as you think.
> What I'm thinking is, could Python turn into a serious competitor to
> bash? The standard shell suffers greatly from sloppy quoting, and many
> of the age-old list-processing idioms are more awkward than cute.
No. Python's syntax is too wordy to make a good shell. You need brackets and
quote marks for everything:
# bash
ls foo/bar
# Python
ls("foo/bar")
iPython is usable, by adding non-standard syntax to its REPL. I don't think
it's a serious contender as replacement for bash, but you could give it a
try. But the standard Python REPL? No.
> A python shell would need a well-thought-out default import plus a way
> to string together external commands. Maybe JSON or similar could be the
> standard I/O framing format (instead of SPC-separated fields and
> LF-separated records).
You really want to be typing JSON by hand instead of space-separated
fields/arguments?
# Python using JSON
ls('["-l", "foo/bar", "spam/ham"]')
# bash
ls -l foo/bar spam/ham
Bugger that for a game of soldiers.
--
Steven
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2016-03-02 13:15 +1100 |
| Message-ID | <mailman.89.1456884942.20602.python-list@python.org> |
| In reply to | #103829 |
On Wed, Mar 2, 2016 at 12:51 PM, Steven D'Aprano <steve@pearwood.info> wrote:
> On Wed, 2 Mar 2016 05:06 am, Marko Rauhamaa wrote:
>
>> Steven D'Aprano <steve@pearwood.info>:
>>
>>> On Sun, 28 Feb 2016 11:38 pm, BartC wrote:
>>>> It's the GUI users who are the Neanderthals, having to effectively
>>>> point at things with sticks. Or have to physically move that rock
>>>> themselves (ie. drag a file to a wastebasket).
>>>
>>> I haven't physically moved an icon to the wastebasket for years. I
>>> point at the icon, right-click, and tell it "move yourself to the
>>> trash".
>>
>> Do you find that interface convenient? Do you often find yourself
>> clickety-clicking around to perform bulk file operations?
>
> Sometimes. Especially with media files which display a thumbnail, it is far
> more convenient to be able to look at the icon and recognise the file than
> to try to guess from the filename "x73nfh.jpg". And having recognised the
> file visually, its often easier to drag it into the folder of your choice
> than to type "mv x7<tab> dir<tab>" in a separate window.
>
> But not always. It's much easier to do "mv foo* dir<tab>". Horses for
> courses.
Absolutely. Tab completion *ROCKS* when you know the file name -
point-and-click is *SUPERB* when you want to identify things by some
form of metadata that the GUI can pull out and display (image/video
file thumbnails being one example; executable files can include their
own icons, esp on Windows; etcetera). The downside of the GUI, here,
is that it sometimes is quite costly to generate those thumbnails; tab
completion is done by reading the directory, but thumbnailing a bunch
of JPGs requires reading the file contents (even if you were actually
planning on clicking on one of the text files in the same directory).
Like you say, horses for courses; but in many cases, I'd recommend
starting with the cheap option - the command line - and moving to the
costlier one only in the situations where you know it's of value.
>> What I'm thinking is, could Python turn into a serious competitor to
>> bash? The standard shell suffers greatly from sloppy quoting, and many
>> of the age-old list-processing idioms are more awkward than cute.
>
> No. Python's syntax is too wordy to make a good shell. You need brackets and
> quote marks for everything:
>
> # bash
> ls foo/bar
>
> # Python
> ls("foo/bar")
>
> iPython is usable, by adding non-standard syntax to its REPL. I don't think
> it's a serious contender as replacement for bash, but you could give it a
> try. But the standard Python REPL? No.
>> A python shell would need a well-thought-out default import plus a way
>> to string together external commands. Maybe JSON or similar could be the
>> standard I/O framing format (instead of SPC-separated fields and
>> LF-separated records).
I think the non-standard syntax plan is the way to do it. But the
thing is, you either have a code-like structure where you delimit
everything, or you have the messy rules involving quoting and
interpolation. The well-established basic shell syntax of
space-delimited parameters with optional quoting is a great balance
between verbosity and complexity.
Not sure what "LF-separated records" has to do with "SPC-separated
fields", though. The latter is all about how you type a command, and
the former is all about the way different commands interact via stdin
and stdout.
> You really want to be typing JSON by hand instead of space-separated
> fields/arguments?
>
> # Python using JSON
> ls('["-l", "foo/bar", "spam/ham"]')
>
> # bash
> ls -l foo/bar spam/ham
>
> Bugger that for a game of soldiers.
No kidding, but at least it's consistent. Maybe there's a
middle-ground, where it's still perfectly consistent, while not being
quite as verbose?
ChrisA
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-03-02 07:41 +0200 |
| Message-ID | <87egbtbfmy.fsf@elektro.pacujo.net> |
| In reply to | #103829 |
Steven D'Aprano <steve@pearwood.info>:
> On Wed, 2 Mar 2016 05:06 am, Marko Rauhamaa wrote:
>> A python shell would need a well-thought-out default import plus a
>> way to string together external commands. Maybe JSON or similar could
>> be the standard I/O framing format (instead of SPC-separated fields
>> and LF-separated records).
>
> You really want to be typing JSON by hand instead of space-separated
> fields/arguments?
>
> # Python using JSON
> ls('["-l", "foo/bar", "spam/ham"]')
>
> # bash
> ls -l foo/bar spam/ham
>
> Bugger that for a game of soldiers.
I was talking about JSON for the standard I/O, not the command-line
arguments, as in:
ps -ef | awk '/httpd/ { print $2 }'
where "ps -ef" emits SPC-separated fields and LF-separated records, and
awk parses and processes them.
Marko
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2016-03-02 16:58 +1100 |
| Message-ID | <mailman.93.1456898305.20602.python-list@python.org> |
| In reply to | #103838 |
On Wed, Mar 2, 2016 at 4:41 PM, Marko Rauhamaa <marko@pacujo.net> wrote:
> Steven D'Aprano <steve@pearwood.info>:
>
>> On Wed, 2 Mar 2016 05:06 am, Marko Rauhamaa wrote:
>>> A python shell would need a well-thought-out default import plus a
>>> way to string together external commands. Maybe JSON or similar could
>>> be the standard I/O framing format (instead of SPC-separated fields
>>> and LF-separated records).
>>
>> You really want to be typing JSON by hand instead of space-separated
>> fields/arguments?
>>
>> # Python using JSON
>> ls('["-l", "foo/bar", "spam/ham"]')
>>
>> # bash
>> ls -l foo/bar spam/ham
>>
>> Bugger that for a game of soldiers.
>
> I was talking about JSON for the standard I/O, not the command-line
> arguments, as in:
>
> ps -ef | awk '/httpd/ { print $2 }'
>
> where "ps -ef" emits SPC-separated fields and LF-separated records, and
> awk parses and processes them.
If you want to change that, you have to change the entire ecosystem,
not just the shell. You would have to teach every single program to
use a different structure.
A lot of programs already do support NUL-separation - usually with a
-z parameter or something. But you won't be able to magically get them
all to use JSON. And I doubt it would be advantageous anyway.
ChrisA
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-03-02 10:20 +0200 |
| Message-ID | <878u21uw7p.fsf@elektro.pacujo.net> |
| In reply to | #103840 |
Chris Angelico <rosuav@gmail.com>:
> On Wed, Mar 2, 2016 at 4:41 PM, Marko Rauhamaa <marko@pacujo.net> wrote:
>> I was talking about JSON for the standard I/O, not the command-line
>> arguments, as in:
>>
>> ps -ef | awk '/httpd/ { print $2 }'
>>
>> where "ps -ef" emits SPC-separated fields and LF-separated records, and
>> awk parses and processes them.
>
> If you want to change that, you have to change the entire ecosystem,
> not just the shell. You would have to teach every single program to
> use a different structure.
Correct. There could be translation utilities in the interim.
> A lot of programs already do support NUL-separation - usually with a
> -z parameter or something. But you won't be able to magically get them
> all to use JSON. And I doubt it would be advantageous anyway.
The advantages are obvious. Barely any programs do proper escaping, and
security problems abound.
Maybe a starting point would be a Python Toybox (<URL:
https://en.wikipedia.org/wiki/Toybox>).
Ecosystem intertia aside, key to the success of such an endeavor would
be to find a Python equivalent for
ps -ef | awk '/httpd/ { print $2 }'
that would be at least as convenient for the fingers and the eye.
Marko
[toc] | [prev] | [next] | [standalone]
| From | Christian Gollwitzer <auriocus@gmx.de> |
|---|---|
| Date | 2016-03-02 23:00 +0100 |
| Message-ID | <nb7nki$fdk$1@dont-email.me> |
| In reply to | #103845 |
Am 02.03.16 um 09:20 schrieb Marko Rauhamaa:
> Chris Angelico <rosuav@gmail.com>:
>
>> On Wed, Mar 2, 2016 at 4:41 PM, Marko Rauhamaa <marko@pacujo.net> wrote:
>>> I was talking about JSON for the standard I/O, not the command-line
>>> arguments, as in:
>>>
>>> ps -ef | awk '/httpd/ { print $2 }'
>>>
>>> where "ps -ef" emits SPC-separated fields and LF-separated records, and
>>> awk parses and processes them.
>>
>> If you want to change that, you have to change the entire ecosystem,
>> not just the shell. You would have to teach every single program to
>> use a different structure.
>
> Correct. There could be translation utilities in the interim.
>
>> A lot of programs already do support NUL-separation - usually with a
>> -z parameter or something. But you won't be able to magically get them
>> all to use JSON. And I doubt it would be advantageous anyway.
>
> The advantages are obvious. Barely any programs do proper escaping, and
> security problems abound.
Have a look at PowerShell. It's not Python, and it is from MS - but it
works along those lines, passing .NET objects through the pipe. Owing to
that, instead of $2=="something" in the awk progra, you can address the
field(attribute) $2 by the correct name instead of a positional argument.
Christian
Caveat emptor: never used it myself
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-03-03 00:36 +0200 |
| Message-ID | <87twkoa4nt.fsf@elektro.pacujo.net> |
| In reply to | #103904 |
Christian Gollwitzer <auriocus@gmx.de>:
> Have a look at PowerShell. It's not Python, and it is from MS - but it
> works along those lines, passing .NET objects through the pipe. Owing
> to that, instead of $2=="something" in the awk progra, you can address
> the field(attribute) $2 by the correct name instead of a positional
> argument.
Requirements for what I have in mind:
1. It would have to be and feel like real Python.
2. External commands should be available as callable Python functions.
3. Functions/commands should return streams. (Generators, maybe?)
4. Pipelines should have an intuitive syntax (but still be valid
Python).
Requirements 3 and 4 apply to regular Python code as well.
Marko
[toc] | [prev] | [next] | [standalone]
| From | Dietmar Schwertberger <maillist@schwertberger.de> |
|---|---|
| Date | 2016-02-28 13:38 +0100 |
| Message-ID | <mailman.11.1456663122.9760.python-list@python.org> |
| In reply to | #103614 |
On 28.02.2016 13:23, Sven R. Kunze wrote: > I recently introduced LaTeX to my girlfriend. LaTeX is quite ugly and > it has this "distinct compile/execute step", so initially I hesitated > to show it to her. But her MS Word experience got worse and worse the > more complex (and especially larger) her workload became. Word became > less responsive and results became even less reproducible (footnote > numbering, styling, literature, etc.). Well, MS Word is a bad example, as it's lacking even some very basic features like a good user interface for styles. (This is the reason why most people are using Word just like a typwriter instead of creating structured documents.) There were and probably still are better word processors, especially for scientific use. The discussion here is not about "any GUI builder", but about a "good and easy to use GUI builder". Regards, Dietmar
[toc] | [prev] | [next] | [standalone]
| From | cl@isbd.net |
|---|---|
| Date | 2016-02-28 12:52 +0000 |
| Message-ID | <h57bqc-d41.ln1@esprimo.zbmc.eu> |
| In reply to | #103628 |
Dietmar Schwertberger <maillist@schwertberger.de> wrote: > On 28.02.2016 13:23, Sven R. Kunze wrote: > > I recently introduced LaTeX to my girlfriend. LaTeX is quite ugly and > > it has this "distinct compile/execute step", so initially I hesitated > > to show it to her. But her MS Word experience got worse and worse the > > more complex (and especially larger) her workload became. Word became > > less responsive and results became even less reproducible (footnote > > numbering, styling, literature, etc.). > Well, MS Word is a bad example, as it's lacking even some very basic > features like a good user interface for styles. (This is the reason why > most people are using Word just like a typwriter instead of creating > structured documents.) > There were and probably still are better word processors, especially for > scientific use. > E.g. Latex or reStructuredText, not GUI. -- Chris Green ยท
[toc] | [prev] | [next] | [standalone]
| From | Dietmar Schwertberger <maillist@schwertberger.de> |
|---|---|
| Date | 2016-02-28 14:19 +0100 |
| Message-ID | <mailman.12.1456665571.9760.python-list@python.org> |
| In reply to | #103632 |
On 28.02.2016 13:52, cl@isbd.net wrote: > Dietmar Schwertberger <maillist@schwertberger.de> wrote: >> There were and probably still are better word processors, especially for >> scientific use. > E.g. Latex or reStructuredText, not GUI. I was more thinking of TechWriter on RISC OS. For Windows there are probably similar offerings. Try selling LaTex as standard word processor to a corporate environment. I guarantee you that you will fail. Regards, Dietmar
[toc] | [prev] | [next] | [standalone]
| From | Dennis Lee Bieber <wlfraed@ix.netcom.com> |
|---|---|
| Date | 2016-02-28 12:03 -0500 |
| Message-ID | <mailman.17.1456678999.9760.python-list@python.org> |
| In reply to | #103614 |
On Sun, 28 Feb 2016 13:38:33 +0100, Dietmar Schwertberger
<maillist@schwertberger.de> declaimed the following:
>Well, MS Word is a bad example, as it's lacking even some very basic
>features like a good user interface for styles. (This is the reason why
>most people are using Word just like a typwriter instead of creating
>structured documents.)
Office 2002 (or was it 2003... Whatever I had on my WinXP box) was, I
thought, rather easy to work styles in... Automatically shifting from
header to body text style on <enter>; Having first body paragraph after a
header use block format while subsequent paragraphs used indented format...
Office 2010 and 2013 OTOH, with their "ribbon" interface taking up a
fifth of the usable screen, have made style control cryptic and hard to
adjust.
--
Wulfraed Dennis Lee Bieber AF6VN
wlfraed@ix.netcom.com HTTP://wlfraed.home.netcom.com/
[toc] | [prev] | [next] | [standalone]
| From | Dietmar Schwertberger <maillist@schwertberger.de> |
|---|---|
| Date | 2016-02-28 18:41 +0100 |
| Message-ID | <mailman.20.1456681304.9760.python-list@python.org> |
| In reply to | #103614 |
On 28.02.2016 18:03, Dennis Lee Bieber wrote: > Office 2002 (or was it 2003... Whatever I had on my WinXP box) was, I > thought, rather easy to work styles in... Automatically shifting from > header to body text style on <enter>; Having first body paragraph after a > header use block format while subsequent paragraphs used indented format... The style editor was always crappy. Most people won't notice due to the lack of comparison. Word processors like Fireworkz and TechWriter got it right to handle layered styles and effects. Easy to edit and easy to apply. And also easy to get rid of them again with a region editor which made it easy to select all modifications that were applied to a text and to delete or modify them. In comparison, MS Word is a mechanical typewriter. Regards, Dietmar
[toc] | [prev] | [next] | [standalone]
| From | BartC <bc@freeuk.com> |
|---|---|
| Date | 2016-02-27 13:35 +0000 |
| Message-ID | <nas8hh$inb$1@dont-email.me> |
| In reply to | #103575 |
On 27/02/2016 11:18, wrong.address.1@gmail.com wrote: > I have some VB forms with more than a hundred objects. If I cannot drag and drop text boxes, list boxes, labels, etc., it will be too much work to create that with several lines of code for each object. > > Isn't there any good GUI IDE like Visual Basic? I hope there are some less well known GUI IDEs which I did not come across. Thanks. All the dialog boxes I've ever created (if that's what you mean by forms), have been done by writing code. Never with drag and drop. Provided you know what to write in those few lines (which would be the stumbling block for me), then a few hundred lines of script code isn't a lot. And Python is a scripting language. And once one form or part of one is done, you might able to just copy and adapt the code instead of having to write everything from scratch. -- Bartc
[toc] | [prev] | [next] | [standalone]
| From | MWS <miragewebstudio12@gmail.com> |
|---|---|
| Date | 2016-02-27 20:05 +0530 |
| Message-ID | <mailman.177.1456583757.20994.python-list@python.org> |
| In reply to | #103575 |
On Saturday 27 February 2016 04:48 PM, wrong.address.1@gmail.com wrote: > I have some VB forms with more than a hundred objects. If I cannot drag and drop text boxes, list boxes, labels, etc., it will be too much work to create that with several lines of code for each object. > > Isn't there any good GUI IDE like Visual Basic? I hope there are some less well known GUI IDEs which I did not come across. Thanks. Hello, I too faced such a problem, being familiar with basic i too found it difficult to transition from designer to text only, but i found the solution, i.e. qt, try pyqt, for desigining try qt creator, i don't know if qt designer is still installable but qt creator is. you can easily design your forms and generate python code and then integrate them with your program. a little commandline stuff, but you can always batch it up. George
[toc] | [prev] | [next] | [standalone]
| From | Dietmar Schwertberger <maillist@schwertberger.de> |
|---|---|
| Date | 2016-02-27 15:20 +0100 |
| Message-ID | <mailman.179.1456589293.20994.python-list@python.org> |
| In reply to | #103575 |
On 27.02.2016 12:18, wrong.address.1@gmail.com wrote: > Isn't there any good GUI IDE like Visual Basic? I hope there are some less well known GUI IDEs which I did not come across. Thanks. As of today, there's no Python GUI builder comparable to VB 6. There are some like QtDesigner or wxGlade, but they either don't generate Python code directly or they can only be used if you know the underlying toolkit good enough to create the GUI yourself. You may try out some, but I can almost guarantee you that you will come to the same result. If you want a GUI, create it yourself using either wxPython or PyQt. For engineering applications that's probably the weakest point that Python has. It's holding back a lot of people... Well, for most measurement or control software a GUI is not really needed, but still people want it. Regards, Dietmar
[toc] | [prev] | [next] | [standalone]
| From | wrong.address.1@gmail.com |
|---|---|
| Date | 2016-02-27 10:13 -0800 |
| Message-ID | <fb41e935-11b3-4919-aa22-ab5c22f6f50c@googlegroups.com> |
| In reply to | #103588 |
On Saturday, 27 February 2016 18:08:36 UTC+2, Dietmar Schwertberger wrote: > On 27.02.2016 12:18, wrong.address.1@gmail.com wrote: > > Isn't there any good GUI IDE like Visual Basic? I hope there are some less well known GUI IDEs which I did not come across. Thanks. > > As of today, there's no Python GUI builder comparable to VB 6. > Thanks for stating this clearly. Everyone here has been trying to show me various ways to do the kind of things I will want to, but nobody clearly admits the limitations I will have to accept if I start with Python. I am starting to wonder if VB.net would be a better solution for the time being. I have learnt enough VB.net to manage my work but it is bloated and Microsoft dependent. > There are some like QtDesigner or wxGlade, but they either don't > generate Python code directly or they can only be used if you know the > underlying toolkit good enough to create the GUI yourself. You may try > out some, but I can almost guarantee you that you will come to the same > result. > If you want a GUI, create it yourself using either wxPython or PyQt. I will check it. I got the impression that you can create a GUI but that has to be converted to Python, and then you need a wrapper to put these forms in, and then they can be compiled or converted to *.exe with py2exe. Not a good way for development/debugging. > > For engineering applications that's probably the weakest point that > Python has. > It's holding back a lot of people... > > Well, for most measurement or control software a GUI is not really > needed, but still people want it. > In the 1980s everyone was happy with inputs from the command line on a line editor, but today people expect GUIs with graphics and often even animations. It is surprising that a language which seems very popular does not have GUI development infrastructure in place these many years after it got into common use. > > Regards, > > Dietmar
[toc] | [prev] | [next] | [standalone]
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2016-02-28 05:29 +1100 |
| Message-ID | <mailman.185.1456597743.20994.python-list@python.org> |
| In reply to | #103597 |
On Sun, Feb 28, 2016 at 5:13 AM, <wrong.address.1@gmail.com> wrote: > In the 1980s everyone was happy with inputs from the command line on a line editor, but today people expect GUIs with graphics and often even animations. > > It is surprising that a language which seems very popular does not have GUI development infrastructure in place these many years after it got into common use. There IS development infrastructure for building GUIs. It's just that the best way to build a cross-platform GUI is code, not drag-and-drop. There are a number of ways to build a GUI in Python (wxPython, PyGTK/PyGObject, PyQt, Tkinter), and some of those have drag-and-drop builders, but not all. Even back in the 90s, when "cross-platform" wasn't a big thing, it was possible to build a window layout using code instead of the builder, and there were a number of situations when that was better (I gave the example of a database form; one of my projects was a generic table editing tool, and what it did was ask the database for a list of columns, and create label+entry field for each one - purely under script control). It's worth noting, too, that the language and the GUI toolkits are independent (only one of the ones I mentioned is even packaged with Python, and it's an optional part); and, thanks to code, the GUI toolkits and GUI builders are also independent. You can pick up a third-party window builder, and as long as it emits valid Python code, it'll work. I've written huge numbers of Python scripts and applications, and I don't think I've ever built a GUI in Python for anything other than testing. ChrisA
[toc] | [prev] | [next] | [standalone]
| From | Marko Rauhamaa <marko@pacujo.net> |
|---|---|
| Date | 2016-02-27 20:35 +0200 |
| Message-ID | <877fhqf1cq.fsf@elektro.pacujo.net> |
| In reply to | #103597 |
wrong.address.1@gmail.com: > In the 1980s everyone was happy with inputs from the command line on a > line editor, but today people expect GUIs with graphics and often even > animations. I don't know who these "people" are, but GUIs certainly have their uses. If you are doing your work professionally, I suppose product management tells you what features are needed in the product. > It is surprising that a language which seems very popular does not > have GUI development infrastructure in place these many years after it > got into common use. It's suprprising that there don't seem to be good GUI applications in existence. Web apps are notoriously bad. (My relatively small experiences with GUI development suggest GUI builders are to blame for the bad GUIs much of the time.) Marko
[toc] | [prev] | [next] | [standalone]
| From | Dietmar Schwertberger <maillist@schwertberger.de> |
|---|---|
| Date | 2016-02-27 19:51 +0100 |
| Message-ID | <mailman.189.1456600133.20994.python-list@python.org> |
| In reply to | #103597 |
On 27.02.2016 19:13, wrong.address.1@gmail.com wrote: > I am starting to wonder if VB.net would be a better solution for the time being. I have learnt enough VB.net to manage my work but it is bloated and Microsoft dependent. I would recommend the Python option... > I will check it. I got the impression that you can create a GUI but that has to be converted to Python, and then you need a wrapper to put these forms in, and then they can be compiled or converted to *.exe with py2exe. Not a good way for development/debugging. For PyQt with Qt Designer the development flow looks like e.g. https://nikolak.com/pyqt-qt-designer-getting-started/ For non-trivial GUIs you will probably find it easier to create the GUI in Python code yourself. But maybe the created Python code will show you how to use PyQt in the beginning. You will find many "Getting started with..." for both PyQt and wxPython. For either GUI toolkit, you should get a book - either "wxPython in Action" or "Rapid GUI Programming with Python and Qt" (or both). For both toolkits the electronic documentation is not for Python but for C++. For wxPython you get a .chm help file, which contains all documentation in one file and a wxPython demo which contains a browser and example code for almost all GUI components. For PyQt the documentation is online. While it is quite complete, I always have difficulties to find the information I'm looking for... wxPython is currently not really an option for Python 3, but this will change very soon. (Well, it can be used with Python 3 already, but for a beginner I would recommend to start with the so called "classic" version for Python 2, especially as the included demo will be the main source of information.) For debugging you just run the interpreter with the .py file. It's reasonably simple to debug with e.g. WingIDE. When you create a GUI in Python code, it's often the easiest way to explore properties and methods of the GUI classes from the debugger prompt. Regards, Dietmar
[toc] | [prev] | [next] | [standalone]
| From | Dietmar Schwertberger <maillist@schwertberger.de> |
|---|---|
| Date | 2016-02-28 00:20 +0100 |
| Message-ID | <mailman.195.1456615248.20994.python-list@python.org> |
| In reply to | #103597 |
On 27.02.2016 19:51, Dietmar Schwertberger wrote: > You will find many "Getting started with..." for both PyQt and wxPython. P.S.: I forgot to mention that both toolkits have very helpful mailing lists. The toolkits have different licenses. With wxPython you don't need to worry. For PyQt you should check which versions and licenses of PyQt and Qt are applicable and whether they are OK for your purpose. Regards, Dietmar
[toc] | [prev] | [next] | [standalone]
Page 5 of 6 — ← Prev page 1 2 3 4 [5] 6 Next page →
Back to top | Article view | comp.lang.python
csiph-web