Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #100713

Re: Ignore error with non-zero exit status

From Chris Angelico <rosuav@gmail.com>
Newsgroups comp.lang.python
Subject Re: Ignore error with non-zero exit status
Date 2015-12-22 11:25 +1100
Message-ID <mailman.51.1450743944.2237.python-list@python.org> (permalink)
References (7 earlier) <2726691.rQGQ7FqzaZ@PointedEars.de> <mailman.26.1450704200.2237.python-list@python.org> <2827307.1DEaE21uzt@PointedEars.de> <n5a3ei$pee$1@ger.gmane.org> <CALwzidnkTPUT_Ezfh065oNWmi+2r6TXoqpYYCfD3AJK-xaUNnQ@mail.gmail.com>

Show all headers | View raw


On Tue, Dec 22, 2015 at 11:17 AM, Ian Kelly <ian.g.kelly@gmail.com> wrote:
> On Dec 21, 2015 4:55 PM, "Terry Reedy" <tjreedy@udel.edu> wrote:
>>
>> Nothing has changed since except for
>> https://www.python.org/dev/peps/pep-0498/
>> already added to 3.6.
>
> https://xkcd.com/927/

The 927ness of it was discussed at length prior to implementation. PEP
498 isn't really another competing string format operation; it's more
like an alternative expression format. It's more in competition with
this:

msg = "The sum of " + str(x) + " and " + str(y) + " is " + str(x+y) + "."

which puts the interpolated expressions at the "correct place" in the
string - but at the cost of being verbose, messy, and error-prone.
Compare:

msg = f"The sum of {x} and {y} is {x+y}."

(Yes, there's a slight semantic difference; the latter uses format()
rather than str(). But otherwise, it's compiled to the "".join(...)
equivalent of the repeated concatenation example.)

ChrisA

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

How to ignore error with anon-zero exit status Ganesh Pal <ganesh1pal@gmail.com> - 2015-12-20 23:00 +0530
  Ignore error with non-zero exit status (was: How to ignore error with anon-zero exit status) Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-20 22:22 +0100
    Re: Ignore error with non-zero exit status (was: How to ignore error with anon-zero exit status) Chris Angelico <rosuav@gmail.com> - 2015-12-21 08:56 +1100
      Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-20 23:46 +0100
        Re: Ignore error with non-zero exit status Chris Angelico <rosuav@gmail.com> - 2015-12-21 10:09 +1100
          Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 08:51 +0100
            Re: Ignore error with non-zero exit status Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-12-21 12:58 +0000
              Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 14:19 +0100
                Re: Ignore error with non-zero exit status Chris Angelico <rosuav@gmail.com> - 2015-12-22 00:23 +1100
                Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 15:05 +0100
                Re: Ignore error with non-zero exit status Chris Angelico <rosuav@gmail.com> - 2015-12-22 01:11 +1100
                Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 15:19 +0100
                Re: Ignore error with non-zero exit status Mark Lawrence <breamoreboy@yahoo.co.uk> - 2015-12-21 16:07 +0000
                Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 23:30 +0100
                Re: Ignore error with non-zero exit status Random832 <random832@fastmail.com> - 2015-12-21 11:30 -0500
                Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 23:27 +0100
                Re: Ignore error with non-zero exit status Steven D'Aprano <steve@pearwood.info> - 2015-12-22 10:32 +1100
                Re: Ignore error with non-zero exit status Terry Reedy <tjreedy@udel.edu> - 2015-12-21 18:53 -0500
                Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-22 13:17 +0100
                Re: Ignore error with non-zero exit status Chris Angelico <rosuav@gmail.com> - 2015-12-22 11:05 +1100
                Re: Ignore error with non-zero exit status Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-21 17:17 -0700
                Re: Ignore error with non-zero exit status Chris Angelico <rosuav@gmail.com> - 2015-12-22 11:25 +1100
        Re: Ignore error with non-zero exit status Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-21 13:30 -0700
        Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Ben Finney <ben+python@benfinney.id.au> - 2015-12-22 07:58 +1100
        Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-21 14:16 -0700
          Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Jon Ribbens <jon+usenet@unequivocal.co.uk> - 2015-12-21 21:44 +0000
            Re: Meaning and purpose of the Subject field Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 23:55 +0100
            Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Steven D'Aprano <steve@pearwood.info> - 2015-12-22 10:14 +1100
              Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Jon Ribbens <jon+usenet@unequivocal.co.uk> - 2015-12-21 23:24 +0000
                Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-21 16:57 -0700
                Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Tim Chase <python.list@tim.thechases.com> - 2015-12-22 09:56 -0600
              Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Cameron Simpson <cs@zip.com.au> - 2015-12-22 14:36 +1100
              Re: Meaning and purpose of the Subject field Random832 <random832@fastmail.com> - 2015-12-21 23:22 -0500
                Re: Meaning and purpose of the Subject field Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-22 13:26 +0100
              Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Grant Edwards <invalid@invalid.invalid> - 2015-12-22 15:17 +0000
                Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Ian Kelly <ian.g.kelly@gmail.com> - 2015-12-22 08:28 -0700
                Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Grant Edwards <invalid@invalid.invalid> - 2015-12-22 22:32 +0000
        Re: Meaning and purpose of the Subject field (was: Ignore error with non-zero exit status) Dennis Lee Bieber <wlfraed@ix.netcom.com> - 2015-12-21 16:55 -0500
    Re: Ignore error with non-zero exit status (was: How to ignore error with anon-zero exit status) Ganesh Pal <ganesh1pal@gmail.com> - 2015-12-21 08:22 +0530
      Re: Ignore error with non-zero exit status Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2015-12-21 08:54 +0100

csiph-web