Show More
@@ -323,7 +323,7 b' def get_repo_changeset(request, apiuser,' | |||
|
323 | 323 | def get_repo_changesets(request, apiuser, repoid, start_rev, limit, |
|
324 | 324 | details=Optional('basic')): |
|
325 | 325 | """ |
|
326 |
Returns a set of c |
|
|
326 | Returns a set of commits limited by the number starting | |
|
327 | 327 | from the `start_rev` option. |
|
328 | 328 | |
|
329 | 329 | Additional parameters define the amount of details returned by this |
@@ -338,7 +338,7 b' def get_repo_changesets(request, apiuser' | |||
|
338 | 338 | :type repoid: str or int |
|
339 | 339 | :param start_rev: The starting revision from where to get changesets. |
|
340 | 340 | :type start_rev: str |
|
341 |
:param limit: Limit the number of c |
|
|
341 | :param limit: Limit the number of commits to this amount | |
|
342 | 342 | :type limit: str or int |
|
343 | 343 | :param details: Set the level of detail returned. Valid option are: |
|
344 | 344 | ``basic``, ``extended`` and ``full``. |
@@ -370,14 +370,17 b' def get_repo_changesets(request, apiuser' | |||
|
370 | 370 | |
|
371 | 371 | vcs_repo = repo.scm_instance() |
|
372 | 372 | # SVN needs a special case to distinguish its index and commit id |
|
373 | if vcs_repo.alias == 'svn' and (start_rev == '0'): | |
|
373 | if vcs_repo and vcs_repo.alias == 'svn' and (start_rev == '0'): | |
|
374 | 374 | start_rev = vcs_repo.commit_ids[0] |
|
375 | 375 | |
|
376 | 376 | try: |
|
377 |
commits = repo |
|
|
377 | commits = vcs_repo.get_commits( | |
|
378 | 378 | start_id=start_rev, pre_load=pre_load) |
|
379 | 379 | except TypeError as e: |
|
380 | 380 | raise JSONRPCError(e.message) |
|
381 | except Exception: | |
|
382 | log.exception('Fetching of commits failed') | |
|
383 | raise JSONRPCError('Error occurred during commit fetching') | |
|
381 | 384 | |
|
382 | 385 | ret = [] |
|
383 | 386 | for cnt, commit in enumerate(commits): |
General Comments 0
You need to be logged in to leave comments.
Login now