-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
Archive labels #25237
Comments
I want to give a try to this issue/feature. Please assign this to me. want to enhance the web skills. |
Yes, of course.
paragraph before you start implementing it. |
By the way, what do you mean with |
I work on majorly golang and js. Just got started in open source contribution. 💯 |
Due to time shortage, I will share my initial finding soon, tomorrrow!. |
Understanding the requirements→Understanding of ISSUES/LABELS/PROJECTS/MILESTONES
That means from point a and b if mile stone is closed, then we need to archive the labels. No matter is issues are completed or closed state.
That means from point a is closed, then we need to archive the labels.
Solution Proposed →
2 Frontend side →
Issues Listing on the UI →
Yes, by default all the issues should be populated in the list including archived labels tagged issues too.
Yes, by default we should only suggest the unarchived label. We should provide an option “Exclude Archive Label” enabled by default. If the “Exclude Archive Label” is set unchecked we should display the archived labels as well. Special use case to keep “Exclude Archive Label” in the search list of label as below. As we have currently 3 version of Gitea to maintain 1.19, 1.20 and 1.21rc, there will be bug fixes in we need to release the minor version . So taking the “backport/*” labels, if any new maintainer comes and he/she doesn’t have understanding of labels , which label should be tagged to the issue or pr. Obviously we have archived the labels of old versions. So if we select couple of issues in the issue-action menu we should give this option to user to see the unarchived labels as well.
In this case lets go with option 2. Yes UI changes will be less and but we give the user an option to “Exclude Archive Label” in the search list as well as in issue-action menu to ease the work. Motivation is the same as #2.
No, we don’t need count number of unarchived labels or total labels. But if we want we can put a filter in label screen to filter this number. But I am highly encourage not to put in ISSUE/Milestone/PR/Project screen. It will be overkill. And we count the number of issues/pr tagged a particular label. Not the label itself. PS:I have two more scenario.
I am open for all suggestions and feedback. will be grateful. cc / @delvh |
Okay, I think I got the gist of what you're trying to say. Here are my thoughts about that:
I meant this counter: That has also shown me an edge case I haven't considered yet:
I think something got "lost in translation" there:
|
I appreciate your feedback, and I agree with points 1, 3, and 4 as you mentioned. Regarding point 2, I should have attach the screenshots earlier. It would have been helpful to provide visual evidence from my side. I have carefully considered your feedback and taken into account your points, along with my own thoughts. Together, we have reached the following discussion till now.
If you see the milestone only open milestone count are there. Github does not have archival label feature yet for labels. For Gitea UI : The count is total number of labels including archived. In the current label screen in gitea → There is no count on label button, and total count is down. After archival labels features in gitea →
Will be anchor tag grey in color. “2 archived” will be a separate tab in Label window in gitea as below screen shot Current label drop down in gitea when not selecting any issue/pr → When adding archive functionality when not selecting any issue → When clicking on issue and then inside “Label” menu we will list the archived labels at the end. Implementation Proposed →
2 Frontend side →
I am open for further discussion. cc// @delvh |
I dont think we need a filter for issues based on archived labels ... rather just use as is but sort them with lower prio ... |
Also i would not add a lable counter as this has no helpfull information but will take space in ui. we dont have to port bad stuff from gh over to us |
It was suggested by delvh. Whatever suits the best on the issue screen as UI point of view. Happy to implement. 😄 |
Uh yes if this is a button to filter the displayed lables to select, then its an awesome feature but should be visible distinguish from the other "issue pre filters" |
awesome ui mockup!!! - ACK :) |
I haven't quite understood yet why we should display it on the |
Feedback Noted. I thought we are sharing the same modal for editing and new label stuff.
Motivation was the same, If any one wants creates an archived label. He/she can edit that label to archive it. |
## Archived labels This adds the structure to allow for archived labels. Archived labels are, just like closed milestones or projects, a medium to hide information without deleting it. It is especially useful if there are outdated labels that should no longer be used without deleting the label entirely. ## Changes 1. UI and API have been equipped with the support to mark a label as archived 2. The time when a label has been archived will be stored in the DB ## Outsourced for the future There's no special handling for archived labels at the moment. This will be done in the future. ## Screenshots ![image](https://github.com/go-gitea/gitea/assets/80308335/208f95cd-42e4-4ed7-9a1f-cd2050a645d4) ![image](https://github.com/go-gitea/gitea/assets/80308335/746428e0-40bb-45b3-b992-85602feb371d) Part of #25237 --------- Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
resolved by #26478 |
Erm, no. |
Followup #26478 ## Archived labels UI Changed: * Enhanced the Filtered UI page to seamlessly incorporate a list of archived labels. Outsourced: * Defer the implementation of specialized handling for archived labels to upcoming pull requests. This step will be undertaken subsequent to the successful merge of this pull request. Screenshots ![image](https://github.com/go-gitea/gitea/assets/80308335/1f33cfb2-2bac-46f0-9103-9e62d235b1d2) ![image](https://github.com/go-gitea/gitea/assets/80308335/3609acd0-b1ba-4ee9-8c4e-1a34dbc37dd7) ![image](https://github.com/go-gitea/gitea/assets/80308335/9860196d-2391-409b-a9a0-1205ab4b412b) --- Part of #25237 --------- Co-authored-by: Giteabot <teabot@gitea.io> Co-authored-by: silverwind <me@silverwind.io>
Do labels actually hide currently on latest dev commit? Or just label status=archives is implemented as a flag? Because we have org-level labels, which are marked as archived, but I can see them everywhere still (on the issue list filter, at issue page in labels select). |
Both: |
Alright, thank you |
Currently this is WIP, will be out in stable release 1.21. Less work is left to support this feature. 😄 |
Followup #26820 ## Archived labels UI for issue filter and issue filter actions for issues/pull request pages. Changed: * Enhanced the Issue filter and Issue filter actions UI page to seamlessly incorporate a list of archived labels. * Pagination functionality is same as before. If archived label checkbox is checked then we are adding a query string`archived=true` in the url to save the state of page. * Issue filter actions menu is separated into different template. * Adding the archived flag in issue url labels. * Pull Request page is also work the same. Outsourced: * Defer the implementation of specialized handling for archived labels to upcoming pull requests. This step will be undertaken subsequent to the successful merge of this pull request. Screenshots ### Issue page <img width="1360" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/d7efb2ef-5b2b-449d-83f0-d430a32ec432"> ### Issue page with label filter on archived label checkbox when not checked --> No archived label is there in list <img width="1249" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/ceea68ef-91f2-4693-910f-2e25e236bfc9"> ### Issue page with label filter on archived label checkbox when checked --> Show archived label in the list. <img width="710" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/2414d26b-2079-4c3c-bd9e-f2f5411bcabf"> ### Issue page with label filter on issue action menu on archived label checkbox when checked --> Show archived label in the list. <img width="409" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/259cac87-3e21-4778-99a2-a6a0b8c81178"> ### Applied the archived=true in Issue labels when archived checkbox is checked. <img width="984" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/657ce3db-c0ae-402e-b12d-3b580d3c2ed0"> --- Part of #25237 --------- Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Giteabot <teabot@gitea.io>
…itea#27115) Followup go-gitea#26820 ## Archived labels UI for issue filter and issue filter actions for issues/pull request pages. Changed: * Enhanced the Issue filter and Issue filter actions UI page to seamlessly incorporate a list of archived labels. * Pagination functionality is same as before. If archived label checkbox is checked then we are adding a query string`archived=true` in the url to save the state of page. * Issue filter actions menu is separated into different template. * Adding the archived flag in issue url labels. * Pull Request page is also work the same. Outsourced: * Defer the implementation of specialized handling for archived labels to upcoming pull requests. This step will be undertaken subsequent to the successful merge of this pull request. Screenshots ### Issue page <img width="1360" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/d7efb2ef-5b2b-449d-83f0-d430a32ec432"> ### Issue page with label filter on archived label checkbox when not checked --> No archived label is there in list <img width="1249" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/ceea68ef-91f2-4693-910f-2e25e236bfc9"> ### Issue page with label filter on archived label checkbox when checked --> Show archived label in the list. <img width="710" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/2414d26b-2079-4c3c-bd9e-f2f5411bcabf"> ### Issue page with label filter on issue action menu on archived label checkbox when checked --> Show archived label in the list. <img width="409" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/259cac87-3e21-4778-99a2-a6a0b8c81178"> ### Applied the archived=true in Issue labels when archived checkbox is checked. <img width="984" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/657ce3db-c0ae-402e-b12d-3b580d3c2ed0"> --- Part of go-gitea#25237 --------- Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: delvh <dev.lh@web.de> Co-authored-by: Giteabot <teabot@gitea.io>
…) (#27381) Backport #27115 by @puni9869 Followup #26820 ## Archived labels UI for issue filter and issue filter actions for issues/pull request pages. Changed: * Enhanced the Issue filter and Issue filter actions UI page to seamlessly incorporate a list of archived labels. * Pagination functionality is same as before. If archived label checkbox is checked then we are adding a query string`archived=true` in the url to save the state of page. * Issue filter actions menu is separated into different template. * Adding the archived flag in issue url labels. * Pull Request page is also work the same. Outsourced: * Defer the implementation of specialized handling for archived labels to upcoming pull requests. This step will be undertaken subsequent to the successful merge of this pull request. Screenshots ### Issue page <img width="1360" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/d7efb2ef-5b2b-449d-83f0-d430a32ec432"> ### Issue page with label filter on archived label checkbox when not checked --> No archived label is there in list <img width="1249" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/ceea68ef-91f2-4693-910f-2e25e236bfc9"> ### Issue page with label filter on archived label checkbox when checked --> Show archived label in the list. <img width="710" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/2414d26b-2079-4c3c-bd9e-f2f5411bcabf"> ### Issue page with label filter on issue action menu on archived label checkbox when checked --> Show archived label in the list. <img width="409" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/259cac87-3e21-4778-99a2-a6a0b8c81178"> ### Applied the archived=true in Issue labels when archived checkbox is checked. <img width="984" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/657ce3db-c0ae-402e-b12d-3b580d3c2ed0"> --- Part of #25237 Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: puni9869 <80308335+puni9869@users.noreply.github.com> Co-authored-by: delvh <dev.lh@web.de>
…abels for an issue (#27451) Followup of #27115 Finally closes #25237 ## Screenshots ### Issue Sidebar <img width="513" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9f7fda2f-5a03-4684-8619-fd3498a95b41"> ### PR sidebar <img width="367" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/53db9b64-faec-4a67-91d6-76945596a469"> ### PR sidebar with archived labels shown <img width="352" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9dc5050f-4e69-4f76-bb83-582480a2281e"> --------- Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: silverwind <me@silverwind.io>
…abels for an issue (go-gitea#27451) Followup of go-gitea#27115 Finally closes go-gitea#25237 ## Screenshots ### Issue Sidebar <img width="513" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9f7fda2f-5a03-4684-8619-fd3498a95b41"> ### PR sidebar <img width="367" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/53db9b64-faec-4a67-91d6-76945596a469"> ### PR sidebar with archived labels shown <img width="352" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9dc5050f-4e69-4f76-bb83-582480a2281e"> --------- Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: silverwind <me@silverwind.io>
…abels for an issue (#27451) (#27661) Backport #27451 by @puni9869 Followup of #27115 Finally closes #25237 ## Screenshots ### Issue Sidebar <img width="513" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9f7fda2f-5a03-4684-8619-fd3498a95b41"> ### PR sidebar <img width="367" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/53db9b64-faec-4a67-91d6-76945596a469"> ### PR sidebar with archived labels shown <img width="352" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9dc5050f-4e69-4f76-bb83-582480a2281e"> Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: puni9869 <80308335+puni9869@users.noreply.github.com> Co-authored-by: silverwind <me@silverwind.io>
…abels for an issue (go-gitea#27451) Followup of go-gitea#27115 Finally closes go-gitea#25237 ## Screenshots ### Issue Sidebar <img width="513" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9f7fda2f-5a03-4684-8619-fd3498a95b41"> ### PR sidebar <img width="367" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/53db9b64-faec-4a67-91d6-76945596a469"> ### PR sidebar with archived labels shown <img width="352" alt="image" src="https://github.com/go-gitea/gitea/assets/80308335/9dc5050f-4e69-4f76-bb83-582480a2281e"> --------- Signed-off-by: puni9869 <punitinani1@hotmail.com> Co-authored-by: silverwind <me@silverwind.io>
Feature Description
Sometimes, old labels should not be used anymore.
For Gitea, for example, those are the
backport/v*
labels.Currently, the only way to stop them from polluting the search results when trying to assign labels to an issue or PR is to delete them completely.
However, this has the drawback that any old issue/PR that had that label loses it, thus losing information.
Instead, it would probably be better to filter out archived labels from the search results and keep them for anything that already has these labels.
So, in a sense, what I propose is a sort of soft deletion for labels (except instead of a boolean we store a timestamp that means unarchived when
0
and displays when this label was archived).This also aligns with milestones and projects as you can close both already, which is their equivalent of archiving.
Labels are currently an outlier in their behavior among the "three scrum tools".
Proposed Approach
archive(d)
on theedit label
screen (and to thePATCH
API route/repos/{owner}/{repo}/labels/{id}
)ArchivedUnix timestamp(now)
inside the db0
include archived labels
inside the suggestion box that is de-selected by default, and re-triggers the search when changed. Needs a lot of UI changesThe text was updated successfully, but these errors were encountered: