Redo the "New Review Request" UI.
Review Request #4215 — Created June 7, 2013 and submitted
Redo the "New Review Request" UI. This is a mostly complete rewrite of our "New Review Request" page to support both pre- and post-commit reviews. For repositories which support it (currently SVN and GitHub), it shows two sections: "New Review Request for Pending Change" and "New Review Request for Committed Change". The pending change workflow is similar to what we had before in its functionality, but it's a bit more streamlined (in the simplest case, it's just "click on the repository name and then drop a diff file in the box"). It also tries a little bit harder to validate that the diffs that people create are valid before actually putting anything in the database, and shows some better error messages (especially in the case of git without --full-index). The one feature that the old forms had was parent diff support. I've decided that for now, it will just point people to using rbtools. The post-commit workflow is super easy--select a branch, and select a commit.
- Created a ton of review requests against various different repositories. Verified that I can do post-commit requests for GitHub and SVN, and that I can do pre-commit requests for any repo. - Checked that the "None" repo allows me to create an empty review request. - Ran js-tests and python unit tests - Ran jshint
Description | From | Last Updated |
---|---|---|
Maybe just get_branches? "heads" seems kind of Gitty. |
chipx86 | |
I feel this can too easily become inconsistent between hosting services. Maybe formalize with an object with fields, so we … |
chipx86 | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Since this is exposed, why not just make it its own file and top-level object? |
chipx86 | |
I assume this will become a BaseResource? |
chipx86 | |
If these are internal only, just make them var statements above. |
chipx86 | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (82 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 23 E127 continuation line over-indented for visual indent |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (112 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 23 E127 continuation line over-indented for visual indent |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (81 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Col: 80 E501 line too long (80 > 79 characters) |
reviewbot | |
Can you add the one-line summary while you're editing this code? |
chipx86 | |
Since we reference this in multiple places, there should be a constant defined in #new-review-request for this height. |
chipx86 | |
Missing a doc comment. |
chipx86 | |
Can you add doc comments to these objects as well? |
chipx86 | |
Should be able to use .height(...) |
chipx86 | |
Here too. |
chipx86 | |
Can you indent within the {% .. %} one space? |
chipx86 | |
Here too. |
chipx86 | |
Should use |escapejs |
chipx86 | |
|escapejs |
chipx86 |
-
I haven't looked at this in great detail. Just some initial thoughts as you work on it.
-
-
I feel this can too easily become inconsistent between hosting services. Maybe formalize with an object with fields, so we know what's available and can make decisions in one place as to what we're extending do. Same goes with branches above.
-
-
-
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service. 3. A temporary new new review request page to use as a development sandbox. 4. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property ~ back on the NewReviewRequest.PostCommitModel ~ back on the NewReviewRequest.PostCommitModel + - When the branch changes (including the initial population), it will fetch + the first page of commits from the server and display them on the page. ~ The next step is to create models and a collection for commits which can handle
~ Next step: spend some time playing with UI layout and design
- pagination and incremental fetch (for infinite scrolley-ness). I'll then listen - to change:branch on PostCommitModel and create the commit browser UI. - Diff:
-
Revision 2 (+579 -1)
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/urls.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py Ignored Files: reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
- Change Summary:
-
- Refactor to define sub-views and models in local vars. - Make NewReviewRequestView take a collection of repositories instead of an array. - Think outside the {% box %} - Memoize the commits fetch with hosting services to speed up the fetch and reduce usage of my API rate limit.
- Diff:
-
Revision 3 (+612 -1)
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/urls.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
- Change Summary:
-
Misc. refactoring.
- Diff:
-
Revision 4 (+677 -1)
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/urls.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service. 3. A temporary new new review request page to use as a development sandbox. 4. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch ~ the first page of commits from the server and display them on the page. ~ the first page of commits from the server and display them on the page. + 5. The start of a new UI layout for the "New Review Request" page. This has a + sidebar on the left with a list of repositories (and in the future, probably + other things like dropbox/google drive/etc). Clicking on a repository will + load the branches and commits on the right-hand side. ~ Next step: spend some time playing with UI layout and design
~ Next steps:
+ - Start investigating how to fetch a diff from github + - Prototype API to create review request for post-commit + - Add in infinite scroll for commits + - Continue playing with visual design - Diff:
-
Revision 5 (+761 -20)
- Added Files:
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/urls.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. ~ 2. Plumbing to implement those two API endpoints for the GitHub hosting service. ~ 2. Plumbing to implement those two API endpoints for the GitHub hosting service + and SVN. 3. A temporary new new review request page to use as a development sandbox. 4. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. 5. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will load the branches and commits on the right-hand side. + I've run into a little wrinkle, being that the GitHub commit API returns a patch
+ with partial index SHAs. I've contacted support to see if we can get them to + either add a full_index query parameter, or make the blobs API support partial + SHAs. + Next steps:
~ - Start investigating how to fetch a diff from github ~ - See if we can get GitHub to implement the API changes we need - Prototype API to create review request for post-commit + - Implement that API for SVN - Add in infinite scroll for commits - Continue playing with visual design
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/urls.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
-
- Change Summary:
-
Include changes that allow me to create a post-commit review through the web UI.
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service and SVN. ~ 3. A temporary new new review request page to use as a development sandbox. ~ 4. The beginnings of client-side javascript to implement a super amazing fancy ~ 3. API plumbing to handle a POST to the review-requests resource with a ~ (submitted) changenum and have it create with data fetched from the server. + 4. Some extra attributes to clarify the difference between "supporting change + numbers" and "supporting pending change numbers" + 5. A temporary new new review request page to use as a development sandbox. + 6. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. ~ 5. The start of a new UI layout for the "New Review Request" page. This has a ~ 7. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will load the branches and commits on the right-hand side. I've run into a little wrinkle, being that the GitHub commit API returns a patch
with partial index SHAs. I've contacted support to see if we can get them to either add a full_index query parameter, or make the blobs API support partial SHAs. Next steps:
+ - Refactor the UploadDiffForm stuff + - More heavily cache commit message data to avoid having to fetch it multiple + times. - See if we can get GitHub to implement the API changes we need - - Prototype API to create review request for post-commit - - Implement that API for SVN - Add in infinite scroll for commits ~ - Continue playing with visual design ~ - Continue playing with visual design + - Create a post-commit review request from the web UI
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/reviews/urls.py reviewboard/scmtools/core.py reviewboard/scmtools/perforce.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
-
-
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service and SVN. 3. API plumbing to handle a POST to the review-requests resource with a (submitted) changenum and have it create with data fetched from the server. 4. Some extra attributes to clarify the difference between "supporting change numbers" and "supporting pending change numbers" 5. A temporary new new review request page to use as a development sandbox. 6. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. 7. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will load the branches and commits on the right-hand side. - I've run into a little wrinkle, being that the GitHub commit API returns a patch
- with partial index SHAs. I've contacted support to see if we can get them to - either add a full_index query parameter, or make the blobs API support partial - SHAs. - Next steps:
- - Refactor the UploadDiffForm stuff - More heavily cache commit message data to avoid having to fetch it multiple times. ~ - See if we can get GitHub to implement the API changes we need ~ - Implement a workaround for get_commit for GitHub using the trees API to get + the blob IDs. - Add in infinite scroll for commits - Continue playing with visual design - Create a post-commit review request from the web UI
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/reviews/urls.py reviewboard/scmtools/core.py reviewboard/scmtools/perforce.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service and SVN. 3. API plumbing to handle a POST to the review-requests resource with a (submitted) changenum and have it create with data fetched from the server. 4. Some extra attributes to clarify the difference between "supporting change numbers" and "supporting pending change numbers" 5. A temporary new new review request page to use as a development sandbox. 6. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. 7. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will ~ load the branches and commits on the right-hand side. ~ load the branches and commits on the right-hand side. + 8. Some hinky code to handle the "Create" action on the client side, posting to + the review-requests resource to create a review request from the selected + commit, and redirect to it. Next steps:
+ - Make changenum plumbing work with arbitrary strings instead of just ints. - More heavily cache commit message data to avoid having to fetch it multiple times. - Implement a workaround for get_commit for GitHub using the trees API to get the blob IDs. - Add in infinite scroll for commits ~ - Continue playing with visual design ~ - Create a post-commit review request from the web UI ~ - Start writing some unit tests for pieces of this ~ - Continue playing with visual design
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/reviews/urls.py reviewboard/scmtools/core.py reviewboard/scmtools/perforce.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js
-
-
- Change Summary:
-
Update for the new version of the commit-id change, and support for github!
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service and SVN. 3. API plumbing to handle a POST to the review-requests resource with a (submitted) changenum and have it create with data fetched from the server. ~ 4. Some extra attributes to clarify the difference between "supporting change ~ 4. Implementation of the get_change call for GitHub and SVN. - numbers" and "supporting pending change numbers" 5. A temporary new new review request page to use as a development sandbox. 6. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. 7. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will load the branches and commits on the right-hand side. 8. Some hinky code to handle the "Create" action on the client side, posting to the review-requests resource to create a review request from the selected ~ commit, and redirect to it. ~ commit, and redirect to it. + 9. Unit tests for the SVNTool implementations Next steps:
~ - Make changenum plumbing work with arbitrary strings instead of just ints. ~ - More heavily cache commit message data to avoid having to fetch it multiple ~ times. ~ - Implement a workaround for get_commit for GitHub using the trees API to get ~ the blob IDs. ~ - Add in infinite scroll for commits ~ - Start writing some unit tests for pieces of this ~ - Continue playing with visual design ~ - More heavily cache commit data to avoid having to fetch it multiple times. ~ - Lots of unit tests. ~ - Error handling and general bullet-proofing. ~ - Add in infinite scroll for commits. ~ - Continue playing with visual design. ~ ~ Add a commit_id field to ReviewRequest
~ + This change adds a new field called 'commit_id' to the ReviewRequest model. This
+ field obsoletes the 'changenum' field. The actual database entry is called + _commit_id, and there's a property which will migrate old data from changenum to + commit_id. + + This new field is a 64-character string instead of an int, in order to handle
+ SCMs that don't use numeric revisions (like git). + + Testing done:
+ - Tested the migration with a database that had review requests with both null + and non-null changenums + - Ran unit tests + - Did some smoke testing of various pieces of UI that deal with changenums + + Reviewed at http://reviews.reviewboard.org/r/4237/
- Change Summary:
-
Screwed up the parent branch.
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
1. API endpoints for fetching a list of branches for a given repository and a list of commits given a HEAD. 2. Plumbing to implement those two API endpoints for the GitHub hosting service and SVN. 3. API plumbing to handle a POST to the review-requests resource with a (submitted) changenum and have it create with data fetched from the server. 4. Implementation of the get_change call for GitHub and SVN. 5. A temporary new new review request page to use as a development sandbox. 6. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. 7. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will load the branches and commits on the right-hand side. 8. Some hinky code to handle the "Create" action on the client side, posting to the review-requests resource to create a review request from the selected commit, and redirect to it. 9. Unit tests for the SVNTool implementations Next steps:
- More heavily cache commit data to avoid having to fetch it multiple times. - Lots of unit tests. - Error handling and general bullet-proofing. - Add in infinite scroll for commits. - Continue playing with visual design. - - Add a commit_id field to ReviewRequest
- - This change adds a new field called 'commit_id' to the ReviewRequest model. This
- field obsoletes the 'changenum' field. The actual database entry is called - _commit_id, and there's a property which will migrate old data from changenum to - commit_id. - - This new field is a 64-character string instead of an int, in order to handle
- SCMs that don't use numeric revisions (like git). - - Testing done:
- - Tested the migration with a database that had review requests with both null - and non-null changenums - - Ran unit tests - - Did some smoke testing of various pieces of UI that deal with changenums - - Reviewed at http://reviews.reviewboard.org/r/4237/
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/webapi/resources.py reviewboard/webapi/encoder.py reviewboard/reviews/tests.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/reviews/evolutions/__init__.py reviewboard/reviews/managers.py reviewboard/reviews/evolutions/commit_id.py reviewboard/scmtools/core.py reviewboard/reviews/admin.py reviewboard/reviews/forms.py reviewboard/webapi/tests.py reviewboard/reviews/urls.py reviewboard/hostingsvcs/service.py reviewboard/scmtools/tests.py reviewboard/hostingsvcs/github.py reviewboard/scmtools/perforce.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/scmtools/testdata/svn_repo/db/current reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/scmtools/testdata/svn_repo/db/revprops/7 reviewboard/scmtools/testdata/svn_repo/db/revprops/6 reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/templates/reviews/review_request_box.html reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js reviewboard/scmtools/testdata/svn_repo/db/revs/6 reviewboard/scmtools/testdata/svn_repo/db/revs/7
-
-
-
-
-
-
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/scmtools/tests.py reviewboard/reviews/urls.py reviewboard/scmtools/core.py reviewboard/scmtools/perforce.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/webapi/resources.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/scmtools/testdata/svn_repo/db/current reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/css/reviews.less reviewboard/static/rb/js/newReviewRequest/models/repositoryBranchModel.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/scmtools/testdata/svn_repo/db/revprops/7 reviewboard/scmtools/testdata/svn_repo/db/revprops/6 reviewboard/static/rb/js/newReviewRequest/models/repositoryModel.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryBranchesCollection.js reviewboard/static/rb/js/newReviewRequest/collections/repositoryCommitsCollection.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/css/defs.less reviewboard/static/rb/js/newReviewRequest/models/repositoryCommitModel.js reviewboard/scmtools/testdata/svn_repo/db/revs/6 reviewboard/scmtools/testdata/svn_repo/db/revs/7
-
-
-
-
-
- Description:
-
WIP post-commit review
This is a (very) work-in-progress change to implement one of our most requested
features, post-commit reviews from the web UI. So far, what this has is:
~ 1. API endpoints for fetching a list of branches for a given repository and a ~ 1. API plumbing to handle a POST to the review-requests resource with a - list of commits given a HEAD. - 2. Plumbing to implement those two API endpoints for the GitHub hosting service - and SVN. - 3. API plumbing to handle a POST to the review-requests resource with a (submitted) changenum and have it create with data fetched from the server. ~ 4. Implementation of the get_change call for GitHub and SVN. ~ 5. A temporary new new review request page to use as a development sandbox. ~ 6. The beginnings of client-side javascript to implement a super amazing fancy ~ 2. Implementation of the get_change call for GitHub and SVN. ~ 3. A temporary new new review request page to use as a development sandbox. ~ 4. The beginnings of client-side javascript to implement a super amazing fancy UI for creating review requests. Right now, this includes: - A drop-down box to select the repository. - When the user selects a repository that supports post-commit review, it will create and show more UI to select a branch (which is populated on-demand from the server). - When the user selects a branch, it's plumbed through to update a property back on the NewReviewRequest.PostCommitModel - When the branch changes (including the initial population), it will fetch the first page of commits from the server and display them on the page. ~ 7. The start of a new UI layout for the "New Review Request" page. This has a ~ 5. The start of a new UI layout for the "New Review Request" page. This has a sidebar on the left with a list of repositories (and in the future, probably other things like dropbox/google drive/etc). Clicking on a repository will load the branches and commits on the right-hand side. ~ 8. Some hinky code to handle the "Create" action on the client side, posting to ~ 6. Some hinky code to handle the "Create" action on the client side, posting to the review-requests resource to create a review request from the selected commit, and redirect to it. ~ 9. Unit tests for the SVNTool implementations ~ 7. Unit tests for the SVNTool implementations + 8. The beginnings of a new pre-commit review workflow, which will be able to do + fancy things like validate that the diff file parses correctly and that the + source revisions are available in the repository. Next steps:
- - More heavily cache commit data to avoid having to fetch it multiple times. - Lots of unit tests. - Error handling and general bullet-proofing. - Add in infinite scroll for commits. ~ - Continue playing with visual design. ~ - Continue playing with visual design. + - Figure out what to do in the case where someone creates a review request for + a change but never publishes it, and later someone else wants to review that + same commit. + - Make pre-commit review work - Diff:
-
Revision 12 (+1243 -26)
- Removed Files:
- Added Files:
- Description:
-
WIP post-commit review
~ This is a (very) work-in-progress change to implement one of our most requested
~ features, post-commit reviews from the web UI. ~ This is a mostly complete rewrite of our "New Review Request" page to support
~ both pre- and post-commit reviews. ~ So far, what this has is:
~ 1. API plumbing to handle a POST to the review-requests resource with a ~ (submitted) changenum and have it create with data fetched from the server. ~ 2. Implementation of the get_change call for GitHub and SVN. ~ 3. A temporary new new review request page to use as a development sandbox. ~ 4. The beginnings of client-side javascript to implement a super amazing fancy ~ UI for creating review requests. Right now, this includes: ~ - A drop-down box to select the repository. ~ - When the user selects a repository that supports post-commit review, it ~ will create and show more UI to select a branch (which is populated ~ on-demand from the server). ~ - When the user selects a branch, it's plumbed through to update a property ~ back on the NewReviewRequest.PostCommitModel ~ - When the branch changes (including the initial population), it will fetch ~ the first page of commits from the server and display them on the page. ~ For repositories which support it (currently SVN and GitHub), it shows two
~ sections: "New Review Request for Pending Change" and "New Review Request for ~ Committed Change". ~ ~ The pending change workflow is similar to what we had before in its
~ functionality, but it's a bit more streamlined (in the simplest case, it's just ~ "click on the repository name and then drop a diff file in the box"). It also ~ tries a little bit harder to validate that the diffs that people create are ~ valid before actually putting anything in the database, and shows some better ~ error messages (especially in the case of git without --full-index). ~ ~ The one feature that the old forms had was parent diff support. I've decided
~ that for now, it will just point people to using rbtools. ~ ~ The post-commit workflow is super easy--select a branch, and select a commit.
- 5. The start of a new UI layout for the "New Review Request" page. This has a - sidebar on the left with a list of repositories (and in the future, probably - other things like dropbox/google drive/etc). Clicking on a repository will - load the branches and commits on the right-hand side. - 6. Some hinky code to handle the "Create" action on the client side, posting to - the review-requests resource to create a review request from the selected - commit, and redirect to it. - 7. Unit tests for the SVNTool implementations - 8. The beginnings of a new pre-commit review workflow, which will be able to do - fancy things like validate that the diff file parses correctly and that the - source revisions are available in the repository. Next steps:
- Lots of unit tests. - Error handling and general bullet-proofing. - Add in infinite scroll for commits. ~ - Continue playing with visual design. ~ - Continue playing with visual design. In particular, things look a little funky + for repositories that don't support post-commit, and there's not visual + indication for post-commit revisions which already have a review request. - Figure out what to do in the case where someone creates a review request for a change but never publishes it, and later someone else wants to review that same commit. ~ - Make pre-commit review work ~ - Figure out a UI for the "File attachments only" creation mode. - Diff:
-
Revision 13 (+1148 -11)
- Added Files:
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/reviews/urls.py reviewboard/scmtools/core.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/static/rb/js/newReviewRequest/views/repositoryView.js reviewboard/static/rb/css/newReviewRequest.less reviewboard/templates/base.html reviewboard/static/rb/js/newReviewRequest/models/preCommitModel.js reviewboard/static/rb/js/newReviewRequest/views/postCommitView.js reviewboard/static/rb/js/resources/models/tests/validateDiffModelTests.js reviewboard/static/rb/js/newReviewRequest/models/postCommitModel.js reviewboard/static/rb/js/newReviewRequest/views/branchView.js reviewboard/static/rb/js/resources/models/validateDiffModel.js reviewboard/static/rb/js/newReviewRequest/views/preCommitView.js reviewboard/static/rb/js/newReviewRequest/views/commitsView.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/views/branchesView.js reviewboard/static/rb/js/newReviewRequest/views/commitView.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/resources/models/repositoryModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/views/repositorySelectionView.js
-
-
This is a review from Review Bot. Tool: Pyflakes Processed Files: reviewboard/reviews/views.py reviewboard/settings.py reviewboard/scmtools/models.py reviewboard/reviews/models.py reviewboard/reviews/urls.py reviewboard/scmtools/core.py reviewboard/hostingsvcs/service.py reviewboard/hostingsvcs/github.py reviewboard/scmtools/svn.py Ignored Files: reviewboard/static/rb/js/newReviewRequest/views/repositoryView.js reviewboard/static/rb/css/newReviewRequest.less reviewboard/templates/base.html reviewboard/static/rb/js/newReviewRequest/models/preCommitModel.js reviewboard/static/rb/js/newReviewRequest/views/postCommitView.js reviewboard/static/rb/js/resources/models/tests/validateDiffModelTests.js reviewboard/static/rb/js/newReviewRequest/models/postCommitModel.js reviewboard/static/rb/js/newReviewRequest/views/branchView.js reviewboard/static/rb/js/resources/models/validateDiffModel.js reviewboard/static/rb/js/newReviewRequest/views/preCommitView.js reviewboard/static/rb/js/newReviewRequest/views/commitsView.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/js/newReviewRequest/views/branchesView.js reviewboard/static/rb/js/newReviewRequest/views/commitView.js reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/resources/models/repositoryModel.js reviewboard/templates/reviews/new_review_request2.html reviewboard/static/rb/js/newReviewRequest/views/repositorySelectionView.js
- Change Summary:
-
Ready for real review. The screenshots are a teeny bit out of date (the UI now scales to fit inside the window), but they're pretty close.
- Summary:
-
WIP post-commit reviewRedo the "New Review Request" UI.
- Description:
-
~ WIP post-commit review
~ Redo the "New Review Request" UI.
This is a mostly complete rewrite of our "New Review Request" page to support
both pre- and post-commit reviews. For repositories which support it (currently SVN and GitHub), it shows two
sections: "New Review Request for Pending Change" and "New Review Request for Committed Change". The pending change workflow is similar to what we had before in its
functionality, but it's a bit more streamlined (in the simplest case, it's just "click on the repository name and then drop a diff file in the box"). It also tries a little bit harder to validate that the diffs that people create are valid before actually putting anything in the database, and shows some better error messages (especially in the case of git without --full-index). The one feature that the old forms had was parent diff support. I've decided
that for now, it will just point people to using rbtools. The post-commit workflow is super easy--select a branch, and select a commit.
- - Next steps:
- - Lots of unit tests. - - Error handling and general bullet-proofing. - - Add in infinite scroll for commits. - - Continue playing with visual design. In particular, things look a little funky - for repositories that don't support post-commit, and there's not visual - indication for post-commit revisions which already have a review request. - - Figure out what to do in the case where someone creates a review request for - a change but never publishes it, and later someone else wants to review that - same commit. - - Figure out a UI for the "File attachments only" creation mode. - Testing Done:
-
+ - Created a ton of review requests against various different repositories.
Verified that I can do post-commit requests for GitHub and SVN, and that I
can do pre-commit requests for any repo.
+ - Checked that the "None" repo allows me to create an empty review request.
+ - Ran js-tests and python unit tests
+ - Ran jshint
- Created a ton of review requests against various different repositories.
- Bugs:
-
- Diff:
Revision 14 (+467 -312)
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/reviews/forms.py reviewboard/settings.py Ignored Files: reviewboard/templates/reviews/new_review_request.html reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/js/resources/models/repositoryModel.js
-
This is a review from Review Bot. Tool: Pyflakes Processed Files: reviewboard/reviews/views.py reviewboard/reviews/forms.py reviewboard/settings.py Ignored Files: reviewboard/templates/reviews/new_review_request.html reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/js/resources/models/repositoryModel.js
- Diff:
-
Revision 15 (+487 -315)
-
This is a review from Review Bot. Tool: PEP8 Style Checker Processed Files: reviewboard/reviews/views.py reviewboard/reviews/forms.py reviewboard/settings.py Ignored Files: reviewboard/templates/reviews/new_review_request.html reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/js/resources/models/repositoryModel.js
-
This is a review from Review Bot. Tool: Pyflakes Processed Files: reviewboard/reviews/views.py reviewboard/reviews/forms.py reviewboard/settings.py Ignored Files: reviewboard/templates/reviews/new_review_request.html reviewboard/static/rb/js/newReviewRequest/views/newReviewRequestView.js reviewboard/static/rb/js/newReviewRequest/models/newReviewRequestModel.js reviewboard/static/rb/css/newReviewRequest.less reviewboard/static/rb/js/resources/models/repositoryModel.js