Add get_file_content APIs for Perforce and improve revision range diffs.
Review Request #13593 — Created March 1, 2024 and submitted
This change makes two improvements to the Perforce client backend in
RBTools. First, this implements the new get_file_content and
get_file_size APIs for use with uploading binary files to diffs. Second,
this plumbs through the tip revision for each file to the diff method so
that we can include it in the file headers. This was important when
posting submitted changesets so that we would have revision information
for the modified file as well as the original.
- Posted a variety of submitted and pending changesets, including binary
files. - Verified that the revision information for modified files was present
in the diff headers when posting submitted changesets. - Ran unit tests.
Summary | ID |
---|---|
4fed98549a6a3a25826f2bc66273985fc44736f3 |
Description | From | Last Updated |
---|---|---|
I know it's internal, but can you add Version Added to these? I've often found them useful when trying to … |
chipx86 | |
This could be an f-string. |
chipx86 | |
local variable 'content' is assigned to but never used Column: 13 Error code: F841 |
reviewbot | |
local variable 'content' is assigned to but never used Column: 13 Error code: F841 |
reviewbot |
-
-
rbtools/clients/perforce.py (Diff revision 1) I know it's internal, but can you add
Version Added
to these? I've often found them useful when trying to backport code or diagnose things for customers. Gives me a starting point when trying to figure out where things originated. -
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+236) |
Checks run (2 succeeded)
Change Summary:
Add unit tests for new APIs
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 3 (+404 -2) |
Checks run (1 failed, 1 succeeded)
flake8
-
rbtools/clients/tests/test_p4.py (Diff revision 3) local variable 'content' is assigned to but never used Column: 13 Error code: F841
-
rbtools/clients/tests/test_p4.py (Diff revision 3) local variable 'content' is assigned to but never used Column: 13 Error code: F841
Commits: |
|
|||||||
---|---|---|---|---|---|---|---|---|
Diff: |
Revision 4 (+596 -2) |