sdefresne / gerrit-monitor Goto Github PK
View Code? Open in Web Editor NEWSource for Gerrit Monitor Chrome extension
License: Apache License 2.0
Source for Gerrit Monitor Chrome extension
License: Apache License 2.0
Gerrit-monitor sometimes shows new CLs in the middle or at the end of my list of "incoming CLs requiring your attention." This isn't ideal for me because I have some CLs in that list that I don't expect will be cleared any time soon (the authors probably won't pursue these CLs further, but that's aside from the point). It would work better for me if gerrit-monitor sorted by last-modified timestamp (more-recently modified CLs are at the top, stale CLs are at the bottom), so I could work from top to bottom (and stop when I get to the stale CLs).
I should also mention I use several gerrit instances. I'm not sure if this kind of sorting is already being applied within each gerrit instance, but I would prefer for it to be applied across all instances (ex. I don't want fresh chromium CLs to be sorted below stale Android CLs).
My use case is:
After this the CL doesn't really need my attention.
I get the error "Error "Unknown error. Try logging in." even though see some CLs listed in GerritMonitor. If I click on "Try logging in" I am taken to a repo's gerrit page that seems to login in just fine.
According to Manifest V2 support timeline, the extension will stop working in January 2023 unless it is converted to Manifest V3.
The guide Migrating to Manifest V3 gives information on what needs to be done to convert the extension to Manifest V3. The most intrusive is probably converting the background page to instead use Service workers.
I have multiple gerrit instances monitored. Every time I click on the extension icon, I have 2-5 second delay with "Loading" before I get the dashboard open.
Can we show cached results and allow more frequent "background" updates?
My Gerrit server is answering API requests to /changes/
with some changes which have the revisions
property empty:
)]}'
[
[
{
// The |current_revision| property is missing.
// And |revisions| contains an empty object:
"revisions": {},
// ...
}
]
]
This is due to an incomplete/incorrect index, since I just restarted my Gerrit instance and I guess I did it at the worst time. Running gerrit index changes {ID}
to reindex the changes affected by this fixed the issue.
When this error occurs, the popup doesn't show any CLs but instead shows the following error: TypeError: Cannot read properties of undefined (reading 'commit')
. The error occurs here:
Lines 337 to 346 in 5d72c67
Maybe we can consider returning null
if there aren't any revisions? And then in the CL widget, we could show the subject as a fallback if the description is null
.
Pretty often in the morning I open my queue, have 5-10 reviews, and would like to open them all.
If it helps, now I open the window, right click inspect and run this command in the console:
[...document.querySelectorAll('.incomingRequiringAttention .changelistheader')].forEach((e)=>{e.click()})
And that seems to work ok, but it'd a nice to have a button that does the same.
Thanks,
Hello,
I use your monitor on 3 different hosts. 1 of those hosts works consistently, and 2 of them fail to work consistently. The names might be sensitive, but the ones that work are in the format aaaaaaaa-review and the ones that dont are in the format aaaaaa-aaaaa-review.
Could there be an issue with hosts with names with multiple '-'?
If that's not making sense, how can I help debug this issue?
Thanks
I use the gerrit-monitor with chromium-review.googlesource.com
I would really like it if I got "Ready to submit" notifications even if the Verified label has no votes, since normally I will be the one adding that label, and it seems to get cleared frequently.
Likewise I would like to NOT get "ready to submit" notifications if the cl is already running in the commit queue.
Love the chrome extension.
Currently if "Only use Attention Set to judge required attention" is enabled, GerritMonitor still sends notifications for Approved commits.
I would expect those to be managed by attention set also. Gerrit will mark them as needing attention when they are approved. Using attention set allows the user to turn off attention in Gerrit if they want to wait to commit (for example if they are waiting on multiple approvals or something else to happen).
It took me 3 rounds of clicking the wrong button & having my permissions not be enabled before I realized that I was clicking the wrong button. I assumed the blue button was "Allow" and the white button was "Deny". I think this was due to both the colors and the order. I would have expected the left most button to be blue & "Allow" & the right side one to be white and "Deny". Would you consider swapping these around?
Gerrit's new attention set feature is quite useful: it helps ensure everyone communicates who they think needs to do some action on a CL. This can work quite well in conjunction with this monitor extension in that the extension could use this information to decide whether some CL is "important" to someone at any given moment.
I didn't see an issue tracking the adoption of this information in the list, but apologies if I simply missed it!
Suppose I have two gerrit instances registered (say A and B), and I am only logged into A. I should be able to use the extension without singing into B, maybe just have an error at the top that I need to sign into B.
When enough servers are added to cause a scrollbar to appear in the options window, the window constantly cycles between two sizes, one with a scrollbar and one without.
I added a bunch of gerrit instances which I no longer use. I'm aware I can uncheck the "Enabled?" checkbox, but is there any way to delete them from the list entirely to declutter the settings page? It would also be nice to remove some of the defaults (I don't work on Fuchsia).
It would be convenient to use gerrit-monitor as a shortcut to gerrit. This is would be useful since there are occasions when I want to visit gerrit even when I don't have a change requiring attention.
For instance, if I am monitoring https://chromium-review.googlesource.com, then there could be a link to https://chromium-review.googlesource.com in the gerrit-monitor drop down.
This is a great extension, but has some annoying qualities. A case I see a lot of is:
I see a few potential solutions. I've ordered them by estimated work to implement, simplest first:
I am not wedded to any of these suggestions, they're just ideas which are better than a blank page. I believe they are also in ascending order of how helpful they'd be, but the effort/helpfulness curve is not linear.
When there are no open issues the extension just opens a small window with the text "No CLs require your attention".
It would be useful to provide a way to open the gerrit instances instead (I can never remember their URL as I always use gerrit monitor to open the ones assigned to me).
Hello,
For Sylvain: This issue relates to an email thread with the subject: "Gerrit Monitor - Extension: Feature Request: Flag reviews with new patchsets".
For everyone else, a paraphrased version of that thread;
A few reviews have not been flagged as incoming in this extension, resulting in a failure to review in a timely manner.
Looking at these instances it seems that the reason is someone pushes a patchset and expects the review to continue from there, but the extension triggers the incoming state on a new comment. I've noticed the Gerrit dashboard considers a review incoming when it has a new patchset.
Working directly with my team(s) I could easily ask them to comment back, but I also work with outside teams who change regularly. Unfortunately, telling them to send these comments would not be applied universally.
I wouldn't want my review sent out just because I uploaded a patchset. Perhaps this feature could be configurable (ideally per host)?
It seems that the periodic updates that should make the extension icon show actionable CLs are not working for me. I have the impression that it is only updating when I actually press the extension icon and force a refresh.
Hi! Super useful. Ideally CLs that I have marked as reviewed would disappear from the extension's list.
When a connection is lost (perhaps due to SSO or equivalent ending), he gets a "Error fetching CL status" for every gerrit instance (I have seven). Perhaps an option to turn that off or just limit it to one?
I have CLs without me in the attention set being listed as "Needing Attention". They are newly uploaded CLs without any reviewers. I do have "Only use Attention Set to judge required attention" set.
Unfortunately the example commits I have are all in a Google internal repo. I email you them directly. Thx!
I sometimes want to open multiple changes in different tabs from the extension. However, after left-clicking on one change, the extension opens a new tab and closes itself.
Maybe a middle-mouse click (similar to html links) to open in a new tab but keep the current tab active + keep the extension ui visible?
Following #48, the permissions to access to URLs changed. Since this version, however, I am unable to get Gerrit Monitor to work, as it asks me for permissions without any possibility to grant them.
It might seem that the issue lies in https://github.com/sdefresne/gerrit-monitor/blob/main/src/options.js#L201, which should use https://developer.chrome.com/docs/extensions/reference/permissions/#step-3-request-optional-permissions to request read permission on the origins, and not just notifications.
Changed "Attention Set Only" to Enabled and saved, then did the same for "Notifications". At that point "Attention Set Only" was saved to "unspecified". This is a bug.
GerritMonitor is displaying https://chromium-review.googlesource.com/c/chromium/tools/build/+/3163431 as "Approved, ready to submit" despite being merged 5 days ago.
It can take a while for monitor to display the list when opened (I have 11 gerrit instances I have to monitor). To speed up initial display time, monitor could show cached results when initially opened. Since user is often responding to its icon color, what they act on is probably already known to the monitor. In the background the monitor would still get latest updates, and then updated the list once it gets them (assuming its still open).
It seems like, whenever I upload a change to gerrit and add a reviewer, gerrit-monitor immediately considers it to be stale. For example, it is currently showing that http://r.android.com/889173, http://r.android.com/889174, and http://r.android.com/889154 are stale, even though I uploaded them less than 20 minutes ago, and I am waiting for the reviewer's first response.
(There was a fourth change, http://r.android.com/889153, which I uploaded at the same time which is not showing as stale, presumably either because I 'said something nice' when I added the reviewers, or because I commented myself since. That's not the normal workflow, at least for me, though.)
When I get sent a review, I like to respond to it as quickly as possible to unblock the CL author. Currently, Gerrit Monitor will display a red badge when there is an incoming review, but I often don't see it for quite some time.
It would be nice if Gerrit Monitor could display a browser/desktop notification when an incoming review comes in. It probably also makes sense to show notifications when a CL requires attention, so that I can address reviewer feedback and get my CL unblocked as quickly as possible.
Different users will presumably have different workflows and preferences, so which notifications are sent (if any) should ideally be configurable.
I'm happy to attempt to contribute this, if such a feature is considered desirable.
Gerrit allows to "ignore" CLs:
I have over a hundred of them (it's old CLs and my team is not in the business of abandoning external contributions). It would be nice if the "ignored" state would be taken into account for what is displayed.
When I have multiple repos in gerrit-monitor and any of them is not signed in, I get a "Try loggin in" message with 4 links to click and I have to click all four of them, which is annoying.
Could we add a button that would click all the links?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.