Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Upgrade Commitfest to Workflow Manager#62

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Closed
polobo wants to merge12 commits intopostgres:mainfrompolobo:upgrade-to-workflow

Conversation

polobo
Copy link
Contributor

@polobopolobo commentedApr 7, 2025
edited
Loading

This is now mostly a referential PR that shows the end goal. First step on getting there is over in PR#65

Note: I'm now seeing just how tied-in CFBot is to what I hoped were just human-readable labels. There is definitely a subset of these changes that can go in without full surgery on the CFBot. But I'm doing surgery on CFBot right now to at least making getting some of the others in more easily. In particular, not yet pushed, but a new API endpoint to start reducing the amount of screen scraping needed.

Key Features

  • Draft Commitfest (Yearly @ feature freeze) (Parked Status)
  • Bugs (and Priority) Commitfest (Yearly @ feature freeze) (Open Status)
  • Commitfest Proper now uses just the (Open & In Progress) Statuses
  • Propose Ongoing instead of In Progress. More succinct.
  • Targeted but Guided Movement (No more Next)
  • Newly Designed Patch Management UX
  • Added Revert/Re-Open Actions (new with 12)
  • Workflow Help Page
  • Updated Workflow-related History Wording

Architecture

  • Workflow Module
  • Commitfest Re-Entry Permitted
  • Most Recent PoC Only Is Editable
  • Unique Active Workflow Roles (needs index tweak with patch 12)
  • Triggers enforce that Future CFs cannot have Patches (new with 12)

Comments

This is probably about 95% the way done, though this is my first Python code submission ever and I haven't read up on Django yet. I remembered to do format/lint at the end of the first push (commit 11) - can rebase if needed but figured this probably goes in as a single commit anyway. Commit 12 reflects the changes to revert "Future" to being a memo commitfest (no patches, enforced by trigger) and Open to being the normal "next CF" while Bugs is removed.

The first four commits affect the desired changes with minimal new backend or middleware coding. They do add the Parked CommitFest status option, as well as constraints ensuring that a Patch has exactly one primary PatchOnCommitFest (poc) and that among the Commitfests all statuses except Close only appear once. The UX changes to the /patch viewer then leverage these to implement the relevant "Move to" actions for each non-Closed Commitfest status; via a new /transition action leveraging most of the Workflow model.

The fifth commit tries and improves upon finding the primary PoC for a patching using the unique partial index instead of a collection filter-and-sort. Not being familiar with Django this is my best guess at what to be doing here.

The sixth commit just makes the different actions, and patch view, use the Workflow model added in the first patch.

Seven through ten are a bit tack-on as I was preparing to submit this pull request; they make no substantive changes to the proposed Workflow model but clean up some details in the UX.

Oh, yeah, the Makefile and .editorconfig changes made my life easier so I tossed them in for discussion.

Also, couldn't figure out how to login as normal (password normal). Will open a separate issue once I try harder but it didn't just work like the readme said.

Related

#53 - PR. Implements Parked without a reserved commitfest id. Close
#17 - Most of the discussion was mine and this is what I was aiming for. Close
#25 - Introduces the feature-freeze annual commitfest switch-over and tweaks the existing three-part commitfest to two-parts. Update
#40 - Not addressed with the initial pull request but definitely a related concern. Reframe Issue Subject
#19 - Adding a new fixed "Feedback" is justified with the Workflow description but also made optional. Close and just use#11
#15 - The author listing cell in the new UI delegates to the Edit screen for now; try and get this in prior to reworking that element of the UI. Leave Open

David J. (David G. Johnston on the mailing lists and elsewhere)
You can also find me on the PostgreSQL Hacking Discord (#commitfest-dev)

Upgrading to Workflow involves many changes.  These few are basiciallynon-invasive and set the stage for what is to come.Introduced:workflow.html - a help page for the new idea of WorkflowCommitFest.STATUS_PARKEDNew Workflow Model to implement Workflow rules and functionalityEnforcement of the Following Constraints: - "At most one" non-Closed Commitfest Status Presence - "At most one" non-Moved POC Status Presence - Closed POC status include leavedate, otherwise it is absentAlso, added a convenience Make target for restoring test environmentAlso, added *.inc to the .editorconfig for html fragmentsWorkflow Highlights:Commitfests are now just Future-In Progress-ClosedYearly Close/Create at v18 Feature Freeze: Drafts v19, Bugs v18
In the interest of breaking up this major change to both UX, backend,and Workflow this patch separates out the main UX redesign choices forindependent consideration.There is a new workflow display that will be polished and describedonce the final components have been incorporated.  For now it simplyplaces all of the action menu items on the screen; and incorporatesa more coordinated and flow-oriented layout for the informationin the existing key-value table.The #history-table is hidden by default but does include potentiallyuseful information and so is expected to remain long-term.  The statushistory field in the keyvalue-table may be moved here at some point.The elements from the #keyvalue-table that did not get incorporatedinto the workflow display are placed into a new workflow supplementaltable.Unlike the key-value table, the new tables are horizontally compact.The #keyvalue-table is presently hidden but viewable.  Conceptually,the contents of this table should never be needed in this view andat some point the table itself can be removed.  For now it is leftas a fallback.The existing action bar has been renamed the administrative bar.This will be visible only to staff and has minimal logic for showingand hiding UI widgets.  That way, should the UI logic be faulty, itis generally still possible for staff to fix it.  In this commit thecontents of the bar remain unchanged, only the file name is different.
Remove all usage of close/next in the UI (just administrative actions).Remove all 'next' detection logic.  The UI will provide valid optionsto the user to choose between and they can make an informed choice;especially since for the typical user there will only be a single choice,to the Future Commitfest or back to the Parked one.  Committers canalso choose to bring any patch into the In Progress or Open/Interlude.The implicit constraint 'next' applied to the system was that,practically speaking, as Patches moved they always move to a Commitfestthat was started in the future: thus current_patch_on_commitfest couldjust use a descending start date sort to find the primary Commitfest.The transition action uses the Workflow implementation which allowsfor a Patch to re-enter the same Commitfest.  This changes theentrydate on the POC which is now used to find the current Commitfest.The Workflow module tries to improve upon the History messages beinggenerated.  Additional thoughts forthcoming in this area.  Should besimple enough to retain the status quo on these if desired, especiallysince I'm disliking the absence of a cfid column; which is why i addedthe relevant POC Commitfest name to the messages.The new code is a bit chatty in terms of feedback to the user.  Though,on the flip side, it intentionally doesn't feel the need to verifythat the button just clicked was intended.  That needs to be tidiedup based upon the guidelines I need to review.
Implement the Workflow rules checked for in the model within the GUI.This way, people only see the actions relevant to their situation.None of the URLs have changed and the only modifications to thecontext environment so far have been additive - thus up to herethere have been only a couple of minor backend changes.  Namely,enforcing the already implicit policy of only opening up at mostone of each Commitfest type at any given it.  And allowing forre-entrancy of a Patch to a Commitfest.The UI does enforce a "Commit or Reject" policy for Patch resolution.Staff can still use Returned with Feedback.  The author is expectedto Withdraw their patch if they do not plan to act on the feedback,or move it back to Parked and Waiting on Author.  Or they canWithdraw and create a new patch in the future.  While the Workflowis not against giving people options, the volume of both rejectedand returned resolutions is too small to warrant  distinguishing them.Hopefully the finished UX is intuitive.  The core three actors in theWorkflow - author, reviewer, committer - have their core actions incolumns left-to-right (though the columns are action-type oriented,not actor oriented).  The headers are the verbs for the actionsin the second row.  The third row is actor-oriented listing theauthor(s), reviewer(a), and committer along with related membershipactions.The fourth column is where the new movement implementation appears,making /close/next obsolete, especially with the addition of Parked.Having run out of actor categories the empty cell in the bottom-leftbecomes a perfect place to display the core information from thekey-value table (which has been hidden).  Namely, the status of theCommitfest and Patch this POC pertains to, the version (hyperlinkon the label to the Edit screen), the topic (also with a labelhyperlink to Edit), the Subscribe/Unsubscribe button, and thelast modified timestamp.Emails, CFBot, and Links also brought over in a key-value table;while History is also hidden but part of the final design.  Thehidden key-value table is being phased out.  The key elements fromit that need to be figured out are: - Status (is a form of History and that should get a re-work) - Created (doesn't seem actionable, especially now with Parked) - Latest Email (redundant with Email content?)ID doesn't seem to useful and can be gotten from the URL if needed.Title is already at the top of the page.All other fields are incorporated into the Workflow UI.
By creating the poc_enforce_maxoneoutcome_idx unique partial indexwe have ensured that every Patch has only one current commitfestdefined by having a status that isn't Moved.  Update Patch to findthis PoC via the index and then return its commitfest propertyfor current_commitfest (and note the method as being deprecated).
Make getting a POC while only having a patchid a single Workflow call.Patch and committer use the committer lookup and change interface.Status and close use the updatePOCStatus interface used by transition.All four leverage PoC as their main hook for patch and commitfest info.
It is desirable to be able to view the status history along withentry and leave dates.Add an edit button for authors to match up with reviewer and committer.Also, explicitly label what we are displaying in the final row.
The idea of having actions visible and then redirect for authenticationis acceptable in general but the /patch view is now driven by therole of the user viewing the page that it seems easier to simply showno actions if the user is not authenticated and add a note just abovethe action table indicating the read-only mode.Add missing is_staff protection for the administrative actions form.Just outright removing the key-value table if you are not logged in.Don't want to edit it, want to get rid of it.
Categories are labels/titles and should use title case.  Use initialcapital letter on all non-joining words.In Progress is an OK label choice but Ongoing communicates the samething with a single word just like all the other options.In the workflow the "Parked" status is being used for commitfestslabelled, e.g.,  Draft v18, so use Drafts as the category label too.Change Open to Bugs to relfect its new usage.Once committed a large technical refactor/rename pass over the modelsand code to make the enums match up with the usage is planned.
Authors and committers can move patches.Only open patches can be committed or rejcted.Closed patches can no be reverted/re-opened if committed/rejected.Only open patch can be moved.Enforce via triggers that future commitfests may not have patches.
@polobopolobo marked this pull request as draftApril 13, 2025 02:22
Copy link
Collaborator

@JelteFJelteF left a comment

Choose a reason for hiding this comment

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

Overall I think this has some good ideas. It's a big enough change in the usage of the site that we should probably discuss this also on the hackers mailinglist once there's a bit more mature proposal.

To help make this easier reviewable, and allow merging incremental improvements quicker. I think it would be helpful if you moved some of the changes to separate PRs. Things like the editorconfig/makefile changes as well as some refactoringslike patch_tr_cfbot.inc

("commitfest", "0010_add_failing_since_column"),
]
operations = [
migrations.RunSQL("""
Copy link
Collaborator

Choose a reason for hiding this comment

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

nit: would be nice to includereverse_sql too in all theseRunSQL migrations, so that the migration can be reverted. Mostly useful for development and testing.

]
operations = [
migrations.RunSQL("""
CREATE FUNCTION assert_poc_not_future_for_poc()
Copy link
Collaborator

Choose a reason for hiding this comment

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

Instead of restricting what you can do with "Future" commitfests, why not remove them completely? (honest question, they seem kinda useless to me)

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

I was going to but Robert immediately made the point that having a Calendar/Schedule of our planned Commitfests has value. That could be done statically...but it is trivial to just make it be data-driven. The workflow would just ignore them and anything else is just presentation. Our existing "List of commitfests" is on the rework list.

Copy link
Collaborator

@JelteFJelteFApr 14, 2025
edited
Loading

Choose a reason for hiding this comment

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

I definitely agree a schedule of planned commitfests has value, but having admins manually create "Future" commitfests is a pretty crude way to do that. And it doesn't even work well in practice, e.g. there hasn't been a single "Future" commitfest for at least 3 months.

I think a much better way would be to statically document/hardcode these dates, they are the same every year. This would also allow us to have a "Start commitfest" button that automatically creates a new "Open" commitfest for the next start/end date. i.e. instead of creating entries in the database with their only purpose being displaying a schedule, we could also display the schedule without these entries existing, because we already know the dates of the next commitfests.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

All good points. Probably want to put them into an issue at this point.

For my part I’m going to include the database constraint/trigger that prohibits Future CFs from having patches associated with them to at least avoid having to deal with that possibility when we do address this in the future. It also allows removal of the “next” action implementation which is the primary incompatibility that exists with Workflow; which itself enables Parked/Drafts.

I’ll be changing the Action drop-down menu but postpone the main table rework as it will break CFBot.

CFBot can readily use the new Workflow endpoint to find the CF IDs it needs to scrape. Given it already handles two CFs being scraped handling three should be a reasonable extension.

I’ll add a schedule to the new workflow doc page.

(STATUS_AUTHOR, "Waiting on Author"),
(STATUS_COMMITTER, "Ready for Committer"),
(STATUS_COMMITTED, "Committed"),
(STATUS_NEXT, "Moved to next CF"),
(STATUS_NEXT, "Moved"),
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nice. This also makes sense without your other changes. It's not always moved to the next commitfest currently either, e.g. a previously closed one can years later be moved to the open commitfest again.

bin is closed and a new one is created. If the feature freeze is for
version 18 then the new drafts bin is called "Drafts v19".
</p>
<h3>Patches on Commitfests (PoC)</h3>
Copy link
Collaborator

Choose a reason for hiding this comment

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

Terrible acronym, because it conflicts with the much more commonly used "Proof of Concept". I know it's called that way in the code, I hate it there too. We should definitely not use it publicly.

In general I think "patches on commitfests" should be considered an implementation detail (and I'm not sure I even like the implementation). "patches on commitfests" is not something users should know about. Users should simply be thinking of a "patches", not a "patches on commitfests". From a users perspective a patch has these things which are internally implemented using "patches on commitfests"

  1. A current status
  2. A current commitfest
  3. A list of previous commitfests

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

Good point. I hate Patch though...since a patch is physical file being applied to the codebase. CFBot calls it Submission - probably because of the fact its job is to apply patch files. How about we start calling the things in the Commitfests Submissions publicly in CFApp and resolve the internal naming mess later?

Copy link
Collaborator

Choose a reason for hiding this comment

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

I agree that Patch is an overloaded term. I'm not a huge fan of "Submission" either, it's rather vague and thus often needs the "commitfests" prefix to clarify. How about we call it a "Patch Set"/"Patchset" instead of a "Submission".

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

After also considering Patch Series I’m most accepting of Patch. It contains versioned patch sets.

state. The PoC they were moved from is updated to "Moved" to indicate this
flow-of-time action.
</p>
<h4>Is Abandoned</h4>
Copy link
Collaborator

Choose a reason for hiding this comment

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

I cannot find anything about this in the code. What is the intent here?

Also, given we don't automatically move patches anymore. I think we probably need better wording here, because otherwise all patches in the active commitfest would be called abandoned if it was closed.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

I'm changing it to"Is Ignored"

I'm giving a name/label to what already exists in reality. Open patches (WoA, NR, RfC) on Closed Commitfests.
CFBot definitely ignores it and its visibility within the CFApp is significantly reduced in that state, effectively ignored by most people.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

We do/should? Continue to check for thread messages on them though…consider whether such thread activity can alter the status of the submission.

is made aware of these files and can incorporate information pertaining to them
into its reporting.
</p>
<h3>Commitfests</h3>
Copy link
Collaborator

Choose a reason for hiding this comment

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

You already sortof introduced commitfests in the workflow section. I think this needs some re-ordering/deduplicating/merging of information.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

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

As with patch, its intended more as a reference section for the topic. But I too don't consider it quite publication worthy yet. Just waiting to see if new/different material needs to be considered as well.

Copy link
Collaborator

@JelteFJelteF left a comment

Choose a reason for hiding this comment

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

Pressed the wrong button. Also I didn't do a full review of the code yet. But I at least wanted to share the feedback I had after an initial (partial) pass

@JelteF
Copy link
Collaborator

Also, couldn't figure out how to login as normal (password normal).

Yeah this seems to be broken. I haven't looked into it closely yet, but I think it's probably that the admin login form does not allow logins as non-staff users.

@JelteF
Copy link
Collaborator

Could you create a separate PR for your editorconfig changes? Then I can merge that and I don't have to press "Approve CI run" button anytime you make a change to this PR, because this is your first PR to this repo and github doesn't trust you yet.

@polobo
Copy link
ContributorAuthor

Could you create a separate PR for your editorconfig changes? Then I can merge that and I don't have to press "Approve CI run" button anytime you make a change to this PR, because this is your first PR to this repo and github doesn't trust you yet.

Will do.

@polobopolobo mentioned this pull requestApr 14, 2025
@polobopolobo closed thisMay 28, 2025
@polobopolobo deleted the upgrade-to-workflow branchMay 28, 2025 15:03
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@JelteFJelteFJelteF requested changes

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@polobo@JelteF

[8]ページ先頭

©2009-2025 Movatter.jp