-
Type:
Bug
-
Resolution: Invalid
-
Priority:
Low
-
Component/s: Repository - Commit List
-
None
-
Severity 3 - Minor
Issue Summary
Pulling commits from pull requests through API using pagination throws an error {"type": "error", "error":
{"message": "Invalid page"}Steps to Reproduce
- Create a repository that contains a Pull Request with over 10 commits
- Run below command:
curl -X GET -u username:password https://api.bitbucket.org/2.0/repositories/username/reposlug/pullrequests/PullRequestId/commits?page=1
- Note that it throws that error. If you exclude ?page=1, the command executes using as default pagelen=10 and at the end of the json it says "next......?page=8xhd".
Expected Results
Running https://api.bitbucket.org/2.0/repositories/username/reposlug/pullrequests/PullRequestId/commits?page=1 would not throw errors and would display the first page of the commits from the pull request.
Actual Results
The below exception is thrown:
{"type": "error", "error": {"message": "Invalid page"}
Workaround
Use pagelen instead such as commits?pagelen=10.