msg203081 - (view) |
Author: (deleted250130) |
Date: 2013-11-16 20:40 |
All functions of compileall are providing a maxlevels argument which defaults to 10. But it is currently not possible to disable this recursion limitation. Maybe it would be useful to have a special value like -1 to disable this limitation and allow to compile in an infinite amount of subdirectories. Also I'm noticing maxlevels is the only argument which is not available on command line. Does it default there to 10 too? Maybe it would be useful if it could be configured too (in this case it could theoretically replace -l). |
|
|
msg203685 - (view) |
Author: PCManticore (Claudiu.Popa) *  |
Date: 2013-11-21 22:17 |
Here's a patch which adds support for controlling the maxlevels on command line. Currently, compileall uses a binary choice, either we don't process subdirectories or we process at most 10 subdirectories. This seems to be the case since its inception, in " Changeset: 1828 (b464e1d0b2fb) New way of generating .pyc files, thanks to Sjoerd. User: Guido van Rossum <guido@python.org> Date: 1994-08-29 10:52:58 +0000 (1994-08-29) " The patch adds a new command option, -r, where `-r 0` is equivalent to specifying -l. I guess we can't modify -l to actually control the maxlevels, due to backward compatibility concerns. |
|
|
msg215897 - (view) |
Author: PCManticore (Claudiu.Popa) *  |
Date: 2014-04-10 18:25 |
Ping. :) Can someone review this patch, please? |
|
|
msg215935 - (view) |
Author: PCManticore (Claudiu.Popa) *  |
Date: 2014-04-11 17:38 |
Added patch which addresses the comments of Berker Peksag. Thanks for the review! |
|
|
msg221619 - (view) |
Author: R. David Murray (r.david.murray) *  |
Date: 2014-06-26 17:23 |
Do we really want to allow infinite recursion (say a symbolic link loop)? |
|
|
msg221621 - (view) |
Author: R. David Murray (r.david.murray) *  |
Date: 2014-06-26 17:26 |
Ah, bad font, I thought the -l was a -1. I see you aren't adding the infinite recursion, the just ability to control the maximum. The patch looks good to me. |
|
|
msg225541 - (view) |
Author: Benjamin Peterson (benjamin.peterson) *  |
Date: 2014-08-19 20:53 |
Why can't we just reuse the "-l" option? |
|
|
msg225542 - (view) |
Author: PCManticore (Claudiu.Popa) *  |
Date: 2014-08-19 21:05 |
Backward compatibility reasons, I guess. compileall -l completely deactivates the recursion, so using -l for controlling the number of levels seems to overwrite its original meaning. |
|
|
msg225544 - (view) |
Author: Roundup Robot (python-dev)  |
Date: 2014-08-19 21:13 |
New changeset a62368778d6c by Benjamin Peterson in branch 'default': allow recursion depth to be specified (closes #19628) http://hg.python.org/cpython/rev/a62368778d6c |
|
|
msg253591 - (view) |
Author: (deleted250130) |
Date: 2015-10-28 08:27 |
I'm wondering what the recursion limit is if -l and -r are not given. Does it default to 10 too or is there no limit? If the first is the case maybe this should also get documented. |
|
|