Skip to content

Draft P4PER#4 - P4PER Purpose and Guidelines#7

Merged
qobilidop merged 8 commits into
p4lang:mainfrom
qobilidop:p4per-4
May 30, 2026
Merged

Draft P4PER#4 - P4PER Purpose and Guidelines#7
qobilidop merged 8 commits into
p4lang:mainfrom
qobilidop:p4per-4

Conversation

@qobilidop
Copy link
Copy Markdown
Member

@qobilidop qobilidop commented Apr 27, 2026

Tracking issue: #4

My goal here is to come up with a reasonable first draft. Further revisions are needed to move it from Draft to Active.

@fruffy fruffy self-assigned this May 1, 2026
Copy link
Copy Markdown
Member

@smolkaj smolkaj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great to me!!

A few questions and possible suggestions, all minor.

Comment thread docs/p4per-4.md
Comment thread docs/p4per-4.md Outdated
Comment thread docs/p4per-4.md Outdated

## P4PER number

A P4PER is uniquely identified by a number. To refer to a P4PER, use the format P4PER-N where N is the P4PER number. For example, this P4PER is P4PER-4.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Idea: Given that we use issue numbers to identify papers, perhaps P4PER#1234 is nicer (since # is what's used by github)?

Bonus: p4lang/p4per#123 will be understood by GitHub tooling!

Orthogonal nit: I find p4per signficantly easer to type than P4PER, so I'd prepfer p4per#123 as the canonical way to reference a paper.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agreed

Copy link
Copy Markdown
Member Author

@qobilidop qobilidop May 17, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm slightly against this, but open to change if more people prefer P4PER#4 or p4per#4. Let me make my arguments first:

  1. p4per#4 aligns with the tracking issue p4lang/p4per#4, but it doesn't align with the URL or filename.
    • For the URL, something like p4per#4 is awkward to use, as it means going the the section named 4 on the page named p4per. It's much more conventional to use p4per-4, like what we do currently: https://p4lang.github.io/p4per/p4per-4/ (preview at https://p4lang.github.io/p4per/pr-preview/7/p4per-4/)
    • For a filename, p4per#4.md is awkward as well, it's more conventional to use p4per-4.md
    • These being said, we could keep using p4per-4 in URL and filename, but use P4PER#4/p4per#4 in text.
  2. Looking at similar projects, I feel P4PER-N is more conventional in general. Examples:

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Switched to use P4PER#N.

Comment thread docs/p4per-4.md Outdated

A P4PER is uniquely identified by a number. To refer to a P4PER, use the format P4PER-N where N is the P4PER number. For example, this P4PER is P4PER-4.

To get a unique number for your P4PER, create an issue in the [P4PER GitHub repo](https://github.com/p4lang/p4per), and use that issue number as your P4PER number.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue, or PR, or both?
Both create unique IDs.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I imagine creating an issue may feel artifical, whereas one has to create a PR to submit a p4per anyhow?

Copy link
Copy Markdown
Member Author

@qobilidop qobilidop May 1, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I preferred issue as I think the lifetime of a P4PER might involve multiple PRs:

  • Creating and iterating on several versions of a Draft.
  • Getting it actually Accepted.
  • Having all the implementation done and marking it as Final.
  • Also, PRs in other repos can refer to this issue if they are part of the implementation.

What do you think?

Since you brought this up, now I realize these justifications are not obvious. So maybe it's worth adding them to the text directly.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@qobilidop What you describe sounds like something that can be done in a single PR, unless we have amendments?

Copy link
Copy Markdown
Member Author

@qobilidop qobilidop May 17, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I feel I failed to describe what I actually have in mind. So let me try again. Will update the text as well to make this clearer.

The main thing I want to argue for here is having a tracking issue per P4PER. This tracking issue serves the following purposes:

  1. Unique P4PER number assignment.
  2. Central hub to link to/from all related PRs/issues/links. Most importantly the PRs that create/update/implement the P4PER.
  3. A thread for public discussion about this P4PER. For example, it could be that all the related PRs have been merged, but someone has something to bring up for discussion about this P4PER. Then this tracking issue is a natural place.

@fruffy Agree what I described in #7 (comment) could be done in a single PR usually. What I wanted to emphasize there (but didn't make it clear) was that some P4PERs might take a significantly long time period to fully develop and implement, like months or years. For these P4PERs, I'd prefer checking them in in Draft/Accepted status first, rather than having them in a PR for months/years until Final. #2 is a concrete example. I think it's already a well-written Draft. I'd prefer to check it in as a Draft. In the future when the authors are ready to push it forward, there could be follow-up PRs to turn it into Accepted/Final.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does #7 (comment) address the concern here?

@fruffy
Copy link
Copy Markdown
Contributor

fruffy commented May 11, 2026

Back from vacation, will try to give this a review by end of this week.

Comment thread docs/p4per-4.md

```mermaid
flowchart LR
Draft --> Accepted
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a rich process, but will we actually follow through with it? Or do we need it?

With implementation I assume you refer to other parts in P4Lang

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a rich process, but will we actually follow through with it? Or do we need it?

Agree the current presentation is making the process more complicated than necessary. I'm working on a simplification:

  1. I think the definition of each status is more important here. The transitions between statuses could be more flexible.
  2. This flowchart is best viewed as a reference of the common status update progressions, in order to illustrate the relationships between the status. It doesn't mean each edge has to be a separate PR. If a P4PER author wants to go directly to Final in a single PR, that should be allowed.

With implementation I assume you refer to other parts in P4Lang

Yes, that's what I mean, essentially PRs in P4Lang repos like P4C, P4Runtime, BMv2, etc.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does #7 (comment) address the concern here?

@qobilidop qobilidop force-pushed the p4per-4 branch 2 times, most recently from 06491a6 to 12cffbc Compare May 16, 2026 19:52
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 16, 2026

Preview removed.

qobilidop added 2 commits May 17, 2026 13:28
Signed-off-by: Bili Dong <qobilidop@gmail.com>
Signed-off-by: Bili Dong <qobilidop@gmail.com>
… style

Signed-off-by: Bili Dong <qobilidop@gmail.com>
Comment thread docs/p4per-4.md Outdated
Active -.-> Final
```

### P4PER submission
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fruffy I rewrote this section for a simpler P4PER submission process. Does it look good to you now?

qobilidop added 2 commits May 17, 2026 13:55
Signed-off-by: Bili Dong <qobilidop@gmail.com>
Signed-off-by: Bili Dong <qobilidop@gmail.com>
Signed-off-by: Bili Dong <qobilidop@gmail.com>
@qobilidop qobilidop changed the title Draft P4PER-4: P4PER Purpose and Guidelines Draft P4PER#4 - P4PER Purpose and Guidelines May 22, 2026
qobilidop added 2 commits May 30, 2026 09:25
Signed-off-by: Bili Dong <qobilidop@gmail.com>
Signed-off-by: Bili Dong <qobilidop@gmail.com>
@qobilidop
Copy link
Copy Markdown
Member Author

I think this P4PER is already in a good shape by Draft standards. I'm giving myself an editor approval and merging it. Will send a follow-up PR to ask for approver approval and move it from Draft to Active.

@qobilidop qobilidop merged commit 855cdfa into p4lang:main May 30, 2026
2 checks passed
github-actions Bot added a commit that referenced this pull request May 30, 2026
@qobilidop qobilidop deleted the p4per-4 branch May 31, 2026 17:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants