Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Bugs

[issue14034] Add argparse howto

 

 

Python bugs RSS feed   Index | Next | Previous | View Threaded


report at bugs

Apr 28, 2012, 8:58 PM

Post #1 of 8 (133 views)
Permalink
[issue14034] Add argparse howto

Ezio Melotti <ezio.melotti [at] gmail> added the comment:

> Would be nice to get another review.

I left several comments on rietveld.

Overall the tutorial seems really nice and easy to follow (except a couple of parts, noted in the comments).

I would replace all the uses of pow(x, y) with x**y in the code, and possibly with x^y in the output/descriptions (x**y is probably fine there too).

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Apr 28, 2012, 9:21 PM

Post #2 of 8 (124 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Ezio Melotti <ezio.melotti [at] gmail> added the comment:

A few more comments:

* in the review I mentioned highlighting specific code lines (this would be really great given the incremental nature of the howto), but apparently that requires a pygment 1.1 [0].

* all the output examples could use ".. highlightlang:: sh", but:
1. the sh highlighter is not so good imho;
2. you would have to switch back and forth from sh and python (unless there's a better way to do it);

* the sidebar box with the tutorial looks better if you put it between the <hr> and the introductory paragraph.

Maybe Georg has something to say about the first two comments.

[0]: see last example in http://sphinx.pocoo.org/markup/code.html#line-numbers

----------
nosy: +georg.brandl

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Apr 29, 2012, 10:40 AM

Post #3 of 8 (120 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Tshepang Lekhonkhobe <tshepang [at] gmail> added the comment:

addressing the bulk of your comments

this does not address last message, where you want the lines highlighted; it will be rather tedious; to me the code snippets are short enough, removing the need for highlighting

----------
Added file: http://bugs.python.org/file25409/argparse_howto4.patch

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

Apr 30, 2012, 12:48 AM

Post #4 of 8 (121 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Tshepang Lekhonkhobe <tshepang [at] gmail> added the comment:

Thanks so much for your thorough attention to detail. I've addressed all your latest comments.

----------
Added file: http://bugs.python.org/file25417/argparse_howto5.patch

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

May 6, 2012, 6:55 AM

Post #5 of 8 (120 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Roundup Robot <devnull [at] psf> added the comment:

New changeset 48385618525b by Ezio Melotti in branch '2.7':
#14034: added the argparse tutorial. Patch by Tshepang Lekhonkhobe.
http://hg.python.org/cpython/rev/48385618525b

New changeset 11703cb2a2f3 by Ezio Melotti in branch '3.2':
#14034: added the argparse tutorial. Patch by Tshepang Lekhonkhobe.
http://hg.python.org/cpython/rev/11703cb2a2f3

New changeset 645969f4193b by Ezio Melotti in branch 'default':
#14034: merge argparse tutorial from 3.2.
http://hg.python.org/cpython/rev/645969f4193b

----------
nosy: +python-dev

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

May 6, 2012, 7:06 AM

Post #6 of 8 (117 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Roundup Robot <devnull [at] psf> added the comment:

New changeset 549aa1460811 by Ezio Melotti in branch '2.7':
#14034: adapt to Python 2 and fix indentation.
http://hg.python.org/cpython/rev/549aa1460811

New changeset d5b7be0629c0 by Ezio Melotti in branch '3.2':
#14034: fix indentation.
http://hg.python.org/cpython/rev/d5b7be0629c0

New changeset e14c860f6eee by Ezio Melotti in branch 'default':
#14034: merge indentation fixes from 3.2.
http://hg.python.org/cpython/rev/e14c860f6eee

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

May 6, 2012, 7:10 AM

Post #7 of 8 (115 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Ezio Melotti <ezio.melotti [at] gmail> added the comment:

Committed, thanks for the patch!

(Note that the example with "TypeError: unorderable types: NoneType() >= int()" works fine in Python 2 (by accident), and that I left it unchanged. Some error messages are also different on Python 2, but I left the ones from Python 3.)

----------
assignee: docs [at] pytho -> ezio.melotti
resolution: -> fixed
stage: needs patch -> committed/rejected
status: open -> closed

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com


report at bugs

May 7, 2012, 1:03 AM

Post #8 of 8 (112 views)
Permalink
[issue14034] Add argparse howto [In reply to]

Tshepang Lekhonkhobe <tshepang [at] gmail> added the comment:

thanks so much for your rime in reviewing and committing

----------

_______________________________________
Python tracker <report [at] bugs>
<http://bugs.python.org/issue14034>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com

Python bugs RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.