Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tools/parser/unparse.py is out of date. #58900

Closed
mdickinson opened this issue Apr 29, 2012 · 8 comments
Closed

Tools/parser/unparse.py is out of date. #58900

mdickinson opened this issue Apr 29, 2012 · 8 comments
Assignees
Labels
type-bug An unexpected behavior, bug, or error

Comments

@mdickinson
Copy link
Member

BPO 14695
Nosy @mdickinson, @bitdancer
Files
  • unparse.patch
  • test_unparse_in_test_tools.patch
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/mdickinson'
    closed_at = <Date 2012-05-07.09:27:57.038>
    created_at = <Date 2012-04-29.19:44:33.535>
    labels = ['type-bug']
    title = 'Tools/parser/unparse.py is out of date.'
    updated_at = <Date 2012-05-07.10:08:23.709>
    user = 'https://github.com/mdickinson'

    bugs.python.org fields:

    activity = <Date 2012-05-07.10:08:23.709>
    actor = 'mark.dickinson'
    assignee = 'mark.dickinson'
    closed = True
    closed_date = <Date 2012-05-07.09:27:57.038>
    closer = 'mark.dickinson'
    components = ['Demos and Tools']
    creation = <Date 2012-04-29.19:44:33.535>
    creator = 'mark.dickinson'
    dependencies = []
    files = ['25410', '25483']
    hgrepos = []
    issue_num = 14695
    keywords = ['patch']
    message_count = 8.0
    messages = ['159645', '159976', '160095', '160096', '160097', '160100', '160123', '160124']
    nosy_count = 3.0
    nosy_names = ['mark.dickinson', 'r.david.murray', 'python-dev']
    pr_nums = []
    priority = 'normal'
    resolution = 'fixed'
    stage = 'patch review'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue14695'
    versions = ['Python 3.2', 'Python 3.3']

    @mdickinson
    Copy link
    Member Author

    Here's a patch that makes all tests in Tools/parser/test_unparse.py pass on the default branch. (The 'yield from' bits would have to be removed for 3.2.)

    @mdickinson mdickinson added the type-bug An unexpected behavior, bug, or error label Apr 29, 2012
    @bitdancer
    Copy link
    Member

    There is a test_tools file now. test_unparse could be called from it.

    @mdickinson
    Copy link
    Member Author

    Ah, that's good to know. I think I'll commit the fix and then look into hooking test_unparse into test_tools.

    For 3.2, it turns out that all that's missing is support for Starred.

    @mdickinson
    Copy link
    Member Author

    Committed in revision c80576303892 (3.2), revision 89e928048903 (default). (I put 14965 instead of 14695 in the commit messages by mistake.)

    @mdickinson
    Copy link
    Member Author

    David: Any suggestions for how best to integrate test_unparse.py into test_tools?

    We could move the contents of test_unparse.py directly in test_tools.py and just kill the old test_unparse.py.

    Alternatively, we could import those TestCase subclasses from test_unparse; is there a better way of doing this than temporarily hacking sys.path to add the Tools/parser directory, as in the attached patch?

    @bitdancer
    Copy link
    Member

    Since we are already doing path hackery in that test file to get things to run, I think your patch would be fine.

    If we grow more tests for the stuff in Tools (which would be good), we might want to consider reorganizing things, but for now I think that the simplest thing that works is good.

    @python-dev
    Copy link
    Mannequin

    python-dev mannequin commented May 7, 2012

    New changeset f9344a3eaaa6 by Mark Dickinson in branch 'default':
    Issue bpo-14695: Run Tools/parser/test_unparse.py as part of test_tools.
    http://hg.python.org/cpython/rev/f9344a3eaaa6

    @mdickinson
    Copy link
    Member Author

    Thanks, David!

    @mdickinson mdickinson self-assigned this May 7, 2012
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    2 participants