#177 Automatically request module for non-standard branches.
Merged by cqi. Opened by ralph.
ralph/fedpkg auto-module  into  master

Download 177.patch

This is half of fedrepo_req#129.

Whenever a user requests a non-standard branch, we will also submit a request for a matching module with matching stream and matching SLs.

In a subsequent changeset, we want to make the admin tool automatically populate new module repos with a useful modulemd starter template.

Should s/not//?

Run command fedpkg-stage --module-name testrepo request-branch some-version --sl "security_fixes:2020-12-01", three issues are created:

  • New Branch "some-version" for "rpms/testrepo"
    https://stg.pagure.io/releng/fedora-scm-requests/issue/40
  • New Repo for "modules/testrepo"
    https://stg.pagure.io/releng/fedora-scm-requests/issue/41
  • New Branch "some-version" for "modules/testrepo"
    https://stg.pagure.io/releng/fedora-scm-requests/issue/42

Is this result expected?

Is this result expected?

I get the answer from the test in test_cli.py. It's yes.

All these issues have same id 2. Would it be good to use three different ids to represent different issues?

It would be good to write a docstring for _request_repo and _request_branch to describe method and arguments.

It would be ... but, it's just an artifact of the mocking. I didn't dig into see how difficult it would be to change and have a different value for each.

rebased onto 56080f9d0e53602b65638401faa79840cfa9feb7

5 new commits added

  • Better mocking. Return different values for each new request.
  • Typofix.
  • Add docstrings.
  • Automatically request module for non-standard branches.
  • Refactor: parameterize the request_repo and request_branch functionality.

OK, @cqi, all of your comments should be addressed at this point. Can you give this a second round of review?

Looks good to me. :thumbsup: Thanks @ralph

Looks good to me too.

Pull-Request has been merged by cqi

Metadata