-
Notifications
You must be signed in to change notification settings - Fork 12
Add a Parking Lot #53
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
Draft
jchampio
wants to merge
4
commits into
postgres:main
Choose a base branch
from
jchampio:dev/parking
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from 1 commit
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
46 changes: 46 additions & 0 deletions
46
pgcommitfest/commitfest/migrations/0011_patch_status_parked.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
# Generated by Django 4.2.19 on 2025-03-07 23:55 | ||
|
||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
dependencies = [ | ||
("commitfest", "0010_add_failing_since_column"), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name="patchoncommitfest", | ||
name="status", | ||
field=models.IntegerField( | ||
choices=[ | ||
(1, "Needs review"), | ||
(2, "Waiting on Author"), | ||
(3, "Ready for Committer"), | ||
(4, "Committed"), | ||
(5, "Moved to next CF"), | ||
(6, "Rejected"), | ||
(7, "Returned with feedback"), | ||
(8, "Withdrawn"), | ||
(9, "Moved to Parking Lot"), | ||
], | ||
default=1, | ||
), | ||
), | ||
migrations.RunSQL(""" | ||
INSERT INTO commitfest_patchstatus (status, statusstring, sortkey) VALUES | ||
(1,'Needs review',10), | ||
(2,'Waiting on Author',15), | ||
(3,'Ready for Committer',20), | ||
(4,'Committed',25), | ||
(5,'Moved to next CF',30), | ||
(6,'Rejected',50), | ||
(7,'Returned with Feedback',50), | ||
(8,'Withdrawn', 50), | ||
(9,'Moved to Parking Lot', 30) | ||
ON CONFLICT (status) DO UPDATE SET statusstring=excluded.statusstring, sortkey=excluded.sortkey; | ||
"""), | ||
migrations.RunSQL( | ||
"DELETE FROM commitfest_patchstatus WHERE status < 1 OR status > 9" | ||
), | ||
] |
26 changes: 26 additions & 0 deletions
26
pgcommitfest/commitfest/migrations/0012_commitfest_status_parking.py
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
# Generated by Django 4.2.19 on 2025-03-08 03:56 | ||
|
||
from django.db import migrations, models | ||
|
||
|
||
class Migration(migrations.Migration): | ||
dependencies = [ | ||
("commitfest", "0011_patch_status_parked"), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterField( | ||
model_name="commitfest", | ||
name="status", | ||
field=models.IntegerField( | ||
choices=[ | ||
(1, "Future"), | ||
(2, "Open"), | ||
(3, "In Progress"), | ||
(4, "Closed"), | ||
(5, "Parking"), | ||
], | ||
default=1, | ||
), | ||
), | ||
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -38,17 +38,20 @@ class CommitFest(models.Model): | |
STATUS_OPEN = 2 | ||
STATUS_INPROGRESS = 3 | ||
STATUS_CLOSED = 4 | ||
STATUS_PARKING = 5 | ||
_STATUS_CHOICES = ( | ||
(STATUS_FUTURE, "Future"), | ||
(STATUS_OPEN, "Open"), | ||
(STATUS_INPROGRESS, "In Progress"), | ||
(STATUS_CLOSED, "Closed"), | ||
(STATUS_PARKING, "Parking"), | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. nit: Seems good to change the name to "Parking Lot" There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. as discussed in the other thread. Let's call it "Drafts" |
||
) | ||
_STATUS_LABELS = ( | ||
(STATUS_FUTURE, "default"), | ||
(STATUS_OPEN, "info"), | ||
(STATUS_INPROGRESS, "success"), | ||
(STATUS_CLOSED, "danger"), | ||
(STATUS_PARKING, "info"), | ||
) | ||
name = models.CharField(max_length=100, blank=False, null=False, unique=True) | ||
status = models.IntegerField( | ||
|
@@ -228,6 +231,7 @@ class PatchOnCommitFest(models.Model): | |
STATUS_REJECTED = 6 | ||
STATUS_RETURNED = 7 | ||
STATUS_WITHDRAWN = 8 | ||
STATUS_PARKED = 9 | ||
_STATUS_CHOICES = ( | ||
(STATUS_REVIEW, "Needs review"), | ||
(STATUS_AUTHOR, "Waiting on Author"), | ||
|
@@ -237,6 +241,7 @@ class PatchOnCommitFest(models.Model): | |
(STATUS_REJECTED, "Rejected"), | ||
(STATUS_RETURNED, "Returned with feedback"), | ||
(STATUS_WITHDRAWN, "Withdrawn"), | ||
(STATUS_PARKED, "Moved to Parking Lot"), | ||
) | ||
_STATUS_LABELS = ( | ||
(STATUS_REVIEW, "default"), | ||
|
@@ -247,6 +252,7 @@ class PatchOnCommitFest(models.Model): | |
(STATUS_REJECTED, "danger"), | ||
(STATUS_RETURNED, "danger"), | ||
(STATUS_WITHDRAWN, "danger"), | ||
(STATUS_PARKED, "warning"), | ||
) | ||
OPEN_STATUSES = [STATUS_REVIEW, STATUS_AUTHOR, STATUS_COMMITTER] | ||
|
||
|
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems incorrect? I.e. it won't remove anything afaict.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I meant to add an explanation to the commit but didn't. This is fully cargo-culted from the last change made to
commitfest_patchstatus
: 535af6eIf this table doesn't need that much pruning in practice, that's fine and I can remove it. But I can't take a look at the current state of the prod database to really know for sure 😁
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(Maybe @mhagander knows why this should or should not be done this time around?)