1. Mentioned PR was merged > 8 years ago.
2. Issue with widget focusing on keypress is invalid:
arrow keys should point on widgets as it positioned
(if button at the next row - "right" button is ignored).
Change-Id: I6fecae34576196b63074a4b0db438aab3da3fd65
In order to avoid having urwid warp the cursor to a non-selectable
widget when moving to a new ChangeView, set focus to the first item
we know will be selectable at the top of the screen, the Change-Id.
Change-Id: Ibd502eb18496eec37383370bb15a4f4cd8b3e5d7
The default for _selectable in the Pile class was switched to False
with https://github.com/urwid/urwid/pull/367 commit 018509d, so
explicitly declare change entries are selectable in order to allow
them to be navigated by keyboard with urwid 2.1.0 and later.
Change-Id: I31f3d62475ec2e8a10e7a553426412ad6aa43f8f
Rather than display the /PATCHSET_LEVEL and /COMMIT_MSG fake
filenames, translate those to nice strings like the web ui does.
Change-Id: I225c8e2ea9763f9dadbefc4a23329efe0f97d899
Also for setting hashtags in change lists using the process mark.
Editing hashtags on individual change screens was already supported.
Selecting hashtags on a change screen will now perform a search for
that tag.
Change-Id: Icc23e10bbf22fbe9b1d958758ec6ceb3286e795b
The change view did not display comments from previous patchsets,
only comments associated with the patchset of the current message.
This displays them from all patchsets, annotating them with the
patchset number when it is different.
Note, the line comments were correctly displayed in the diff view.
Change-Id: Ieda0de0bb24800b9c3f577f339ca1338f2f1cc38
This is necessary on systems where the username may not be present
(e.g., gerrit-review.googlesource.com).
Change-Id: Ia91b1e9b0fb0f98728dca46a488a92a97a301274
File comments were causing an exception when displayed on the
change view because python3 does not allow comparing None to int,
and file comments have a line number of None.
To correct this, use 0 as the line number for file comments whin
sorting and displaying them in the change view; there is no line
0 so this minor aliasing shouldn't cause any collisions.
Also, add a newline to the end of file comments, just as regular
inline comments (otherwise if a file comment was followed by a
line comment, they would appear on the same line).
Change-Id: Iedf88cdfd83adbc405e26cb013c9f57481d50c90
- Add a config option to enable closing a change after a review
is saved, and going back to the change list.
- Enable reviewKeys from the change page to also work on the
diff view.
Change-Id: I37d907132a012d074d38345f15ef83ec7d9f3e6c
The gerrit ui shows the inline comments on the change overview without
having to open the diff screen. This is useful for following
discussions on changes so add this to gertty as well.
Change-Id: I976ec5584e978ce4aee7075bc45394193c104889
Add 'message' optional parameter to reviewkeys which can be use to have
a shortcut to leave recheck in reviews (example of use case).
reviewkeys:
- key: 'meta 4'
approvals: []
message: 'recheck'
It updates the doc and also the openstack-gertty.yaml since it can be
useful for all OpenStack reviewers.
Change-Id: I81f3cc8374fe1872efb71d4b2bc1c647b118d43f
If a change has many revisions, loading the change screen may be
slow because we verify the presence of each commit and its parent
individually.
Instead, do that in a batch to speed things up.
Change-Id: Ib4b1c34500b98b8bb7307a5aaca86802a15e635d
Gertty currently handles change owners or review comments from
folks with missing account information (or even missing accounts).
This adds similar logic for approvals.
Change-Id: I368807eac131cdfddb9eaf97efdf217af10ea33b
Hitting 'page down' on a change with a long review message might
produce an error like:
urwid.listbox.ListBoxError: Invalid offset_inset: -7, only 2 rows in target!
Setting the initial focus of the listbox to the grid rather than
the divider seems to help with that. It also seems to make more
sense.
Change-Id: Ie8038583250a994851f2570d889112153d2906a3
To display a change screen, we need to access all of the revisions,
files, and comments for the change. Tell SQLAlchemy in that case
to go ahead and load everything in one query. In local testing,
this made https://review.openstack.org/223333 load in about 1
second rather than 9 seconds.
Change-Id: I5eb53e2a1ee853f4489e92c4ca719cfb96b4a563
The OrderedDict type returned by `commentlink.getTestResults()` was
lost when being passed to `_updateTestResults()`.
This commit restores the order as it is supposed to be.
Change-Id: Ie7fc7afd54a0243e4fe956b32061e98d743f7245
This commit adds the email addresses for the patch owner and the
current reviewers to the change view.
Change-Id: I9c6835746d50d6907c490bc62323a07cd8eff789
When leaving a message on a review, default the approval values
to those previously left by the user if they exist. This way
if the user leaves a follow-up comment or reply, they are less
likely to accidentally clear their vote.
Change-Id: Iab9203e35aef9756057a62fed161fe818dd1d680
Urwid encodes the input field according to the encoding of the
label, so setting the label to be u'unicode' causes the text
to be returned as unicode.
Change-Id: Id862bd78e5d505ae071e11a2b0cdf5c174a6efcc
When entering multi-key commands, display potential completions
in the status bar as a reminder to the user.
Change-Id: I498781576a60789b0f810f08cbc9c8c74d52784f
This corrects the following error:
urwid.listbox.ListBoxError: Widget <Pile selectable box/flow widget>
at position 2 within listbox calculated X rows but rendered Y!
This happened when related changes links were winder than the screen.
They were rendered as FixedButtons, but there is no reason for them
to be. This changes them to regular urwid Buttons which are flow
widgets and will line-wrap if needed.
Change-Id: Ia91beaffadbb7a3e5341b11c49bb2d6d74df4782
Gertty uses WidgetWraps around the LineBox widget for popup widgets. Add
LineBoxTitlePropertyMixin which adds property and setter for title attribute,
accessing the underlying title_widget on the wrapped LineBox widget.
We use the popup method in the controller to display these dialogs. It uses an
Overlay widget to display our dialog widget on top of the current view. If the
widget to be displayed by the Overlay widget has title attribute, copy it to
the Overlay widget.
Change-Id: I4c6ecbc7ed87867cd67cd93c1125384dd5d4b9af
Display [ABANDONED] if the parent is abandoned, and do not display
children if they are abandoned.
Change-Id: I8384cd9df2f3a9310874e62f227963a5f1a9476a
In environments without py27, gertty was unable to run. This patch
addresses all the Py3K issues discovered when getting gertty running in
a py34-only environment.
Change-Id: I32a06f9768bdeaf8e95ddf9a9e54c79059fbaa2f
So that the project list page is more responsive, cache counts of
open and unreviewed changes for projects.
Change-Id: I270f4009d6c7cca9d9868a181db94f779662b643
Create a global app kill ring and a custom edit widget that can
kill and yank from it. Also, add Emacs beginning/end of line
keys to the default keymap.
Change-Id: I18d8d47694c89ede4dcec7eaf5d3fb2210ef4438
This change allows a user to click the permalink on the review screen
and have it open up in a web browser.
Change-Id: I4c0fe35f062043a47368d68fecbbcdbf8d955267
The getRepo method really doesn't have much to do with the application
object. Since it's really a utiltiy method for dealing with git repos
I've moved it to gertty.gitrepo.
Change-Id: Ic3349430c456ee184bbf57b6e5b7de4f940b4cc1
Add a process mark to the change list so that multiple changes may
be selected at once for further operations. Allow multiple changes
to be reviwed at once by selecting them with the process mark and
then pressing the usual review command key. The categories are
simply taken from the first change in the list for simplicity.
This should be fine most of the time, but if the changes have
different categories available to them, or the user has different
access levels, this may not behave as intended.
Change-Id: I04a790d91b27b270cf1269c7bcb39c12d857ab32
Since each revision now has files, associate comments with the
file relation rather than revisions so that the path is not stored
twice in the database.
Also correct a problem where comments could be left on empty files
or lines that are not in a file in the unified view.
The SQLAlchemy constraints API seems to have changed between
0.9.9 and 1.0.4. Support both behaviors to be user-friendly even
though we now specify 1.0.4.
Change-Id: If6593d279a432ea8a48f4bd74a157e4978e69eaa
In order to support searching for changes by file modified, keep
a local table of files modified in each revision. In order to
populate the table without needing to re-sync every change, run
a diffstat on every revision during the migration.
Once established, the table will be populated during the normal
change sync.
Add support for the "file:" operator in searching.
Change-Id: Idbd44944405bdbc93af8bc3c513498e4425ba75b
This commit fixes the following flake8 issues:
F401 'foo' imported but unused
F403 'from foo import *' used; unable to detect undefined names
Change-Id: I163224c65f54a2e495d6469c1c26a115ad192e23
This commit fixes the following flake8 issues:
F821 undefined name 'name'
F841 local variable 'name' is assigned to but never used
It also silences the false-positives caused by parser.py and
tokenizer.py.
Change-Id: Icdc42f47f5f1f383054d8dfdeed6509fc478637b
When on the change screen, if navigating to a change missing
commits, display the error in a dialog rather than crash.
Change-Id: I560e17241bcb43a91093c13fafd18aa54d215e13
Highlight the user's name in the review box and messages so that
when revisiting a review, it is easy to see one's own vote or any
messages that the user has previously left, or in case the user
forgets their own name.
Change-Id: Idf08e98b3d287376b0e2c8a3f0a1c38b3c30f698