This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author nadeem.vawda
Recipients eric.araujo, nadeem.vawda, tarek
Date 2012-02-24.14:46:34
SpamBayes Score 2.06523e-07
Marked as misclassified No
Message-id <1330094795.44.0.467789061974.issue14106@psf.upfronthosting.co.za>
In-reply-to
Content
As I understand it, a MANIFEST.in directive:

    recursive-include foo bar.*

is meant to match files under foo for with names beginning with "bar.".
However, the actual regex that is generated for this line is:

    r'^foo/.*bar\.[^/]*\Z(?ms)'

which matches any filename under foo that contains "bar." anywhere in the
base filename. For example, if foo contains files bar.py and test_bar.py,
then the pattern will match both filenames. Is this the intended
behaviour? I would have expected it to only match bar.py.

If the desired behavior is what I expected (and not how it currently
works), then the desired regex is:

    r'^foo/(.*/)?bar\.[^/]*\Z(?ms)'

The attached patch (against 2.7) implements this change. It is dependent
on the fix for issue 6884. I have tested it on both Linux and Windows.
History
Date User Action Args
2012-02-24 14:46:35nadeem.vawdasetrecipients: + nadeem.vawda, tarek, eric.araujo
2012-02-24 14:46:35nadeem.vawdasetmessageid: <1330094795.44.0.467789061974.issue14106@psf.upfronthosting.co.za>
2012-02-24 14:46:34nadeem.vawdalinkissue14106 messages
2012-02-24 14:46:34nadeem.vawdacreate