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

Test somehow that generated files are up to date: run make regen-all #74445

Closed
vstinner opened this issue May 3, 2017 · 6 comments
Closed

Test somehow that generated files are up to date: run make regen-all #74445

vstinner opened this issue May 3, 2017 · 6 comments
Labels
3.7 (EOL) end of life tests Tests in the Lib/test dir

Comments

@vstinner
Copy link
Member

vstinner commented May 3, 2017

BPO 30259
Nosy @vstinner, @zware
PRs
  • [WIP] bpo-30259: Test regen check #2542
  • [WIP] bpo-30259: Test regen-all check #2543
  • 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 = None
    closed_at = <Date 2017-07-03.13:38:20.533>
    created_at = <Date 2017-05-03.16:26:48.613>
    labels = ['3.7', 'tests']
    title = 'Test somehow that generated files are up to date: run make regen-all'
    updated_at = <Date 2017-07-03.13:38:20.532>
    user = 'https://github.com/vstinner'

    bugs.python.org fields:

    activity = <Date 2017-07-03.13:38:20.532>
    actor = 'vstinner'
    assignee = 'none'
    closed = True
    closed_date = <Date 2017-07-03.13:38:20.533>
    closer = 'vstinner'
    components = ['Tests']
    creation = <Date 2017-05-03.16:26:48.613>
    creator = 'vstinner'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 30259
    keywords = []
    message_count = 6.0
    messages = ['292915', '292917', '296866', '296867', '297583', '297585']
    nosy_count = 2.0
    nosy_names = ['vstinner', 'zach.ware']
    pr_nums = ['2542', '2543']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue30259'
    versions = ['Python 3.7']

    @vstinner
    Copy link
    Member Author

    vstinner commented May 3, 2017

    bpo-23404 replaced "make touch" with "make regen-all". Generated files are no more regenerated based on file modification time anymore, the action is now explicit.

    Zachary Ware proposed to add a buildbot to check that generated files are up to date: run "make regen-all" and test that no file was modified.

    @vstinner vstinner added 3.7 (EOL) end of life tests Tests in the Lib/test dir labels May 3, 2017
    @vstinner
    Copy link
    Member Author

    vstinner commented May 3, 2017

    I also asked if something similar should be done for autoconf?
    http://bugs.python.org/issue23404#msg292829

    @vstinner
    Copy link
    Member Author

    Oh, Zachary: it seems like you already implemented this check, no?

    "Use Travis to make sure all generated files are up to date"
    [MERGED] #2080

    @vstinner
    Copy link
    Member Author

    make -j4
    make -j4 regen-all clinic
    changes=git status --porcelain
    if ! test -z "$changes"
    then
    echo "Generated files not up to date"
    echo "$changes"
    exit 1
    fi

    I understand that we build the whole Python, and only later check if generated files are up to date.

    Why not checking if generated files are up to date *before* compiling Python?

    @vstinner
    Copy link
    Member Author

    vstinner commented Jul 3, 2017

    #2543 confirms that the "make regen-all" test works, the CI fails with:

    Generated files not up to date

    M Include/Python-ast.h

    @vstinner
    Copy link
    Member Author

    vstinner commented Jul 3, 2017

    #2542 confirms that the "make clinic" test works, the CI fails with:

    Generated files not up to date

    M Modules/clinic/posixmodule.c.h

    M Modules/posixmodule.c

    --

    I close the issue, thanks Zach for the automated tests!

    @vstinner vstinner closed this as completed Jul 3, 2017
    @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
    3.7 (EOL) end of life tests Tests in the Lib/test dir
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant