Skip to content

General question on PR's, when several PR's have a dependency on a commone one #9480

Closed
@abelbraaksma

Description

@abelbraaksma

Not a bug, just a question on expected best practice in this repo. Suppose you prepared a few PR's, but some of these are dependent on a different change (in my case: I just need to move a function up in a module so it gets in scope for others), how best go about it? I can think of:

  1. Create a separate branch + PR for the common change, then start new branches off this branch for the next PR's.
    • Downside: each dependent PR will show the changes of the common PR which may confuse reviewers
    • Upside: I can submit all PR's without necessarily waiting for agreement
  2. Create a separate branch + PR for the common change. Wait until this is merged into master, then start other PR's off this branch.
    • Downside: you'll need to wait before the common PR is accepted. If you continue with new PR's locally, you'll have to rebase.
    • Upside: cleaner history, easier review as each PR is isolated
  3. If it's a small common change, do that change for each PR and let merging fix it.
    • Downside: each PR will have this change, merging may show conflicts, reviewers may be confused seeing the same change
    • Upside: no added PR-dependency complexity

I'm sure this stuff happens all the time and I'm not Git-whiz, so perhaps / hopefully there's a simple(r) answer here.

(I'm currently assuming #1 or #2 to be the proper way, which I started #9481)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions