Re: Selecting items in New Review Request for Committed Change drop box doesn't work and throws ERROR in server log file
Problem here seems to be that ReviewBoard doesn't handle the situation where there are revisions present that the repository user doesn't have access to. get_commits() fails because there is no commit['date'] for a given revision, when you have no access to the files that the revision affected. After putting in a workaround for that (by skipping over revisions with no date), noticed get_commits() seemed to be failing in the same way when running across revisions where commit['message'] was non-existent (I think if the user didn't put in a log message?) So, also needed to change a non-existent commit['message'] to be treated as an empty string. -BRF On Wednesday, September 3, 2014 4:39:31 PM UTC-5, Eugene wrote: My SVN repository (https://fs.company.com/svn-proj) has four directories. All of them show up in New Review Request for Committed Change drop-down box (on https://reviewboard.company.com/r/new/), but only selecting one of them works ok, i.e. loads recent commits. Selecting any other of the items results in empty list. Server log shows the info below. Pls advise what could be the reason for that and how to fix it? Thanks 21:22:02 INFO - Using reviewboard.scmtools.svn.pysvn backend for SVN 21:22:03 ERROR - Exception thrown for user eugene at https://reviewboard.company.com/api/repositories/1/commits/?branch=projapi_format=json u'date' Traceback (most recent call last): File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/core/handlers/base.py, line 112, in get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/cache.py, line 52, in _wrapped_view_func response = view_func(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/vary.py, line 19, in inner_func response = func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 494, in __call__ request, method, view, api_format=api_format, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 565, in call_method_view return view(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 110, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 33, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 287, in _validate return view_func(*args, **new_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/resources/repository_commits.py, line 84, in get items = repository.get_commits(branch=branch, start=start) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/models.py, line 328, in get_commits cache_period) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/cache/backend.py, line 118, in cache_memoize data = lookup_callable() File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/models.py, line 313, in lambda lambda: self.get_scmtool().get_commits(**commits_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/svn/__init__.py, line 182, in get_commits commit['date'].isoformat(), File /usr/local/python-2.7.8/lib/python2.7/UserDict.py, line 23, in __getitem__ raise KeyError(key) KeyError: u'date' -- Get the Review Board Power Pack at http://www.reviewboard.org/powerpack/ --- Sign up for Review Board hosting at RBCommons: https://rbcommons.com/ --- Happy user? Let us know at
Re: Selecting items in New Review Request for Committed Change drop box doesn't work and throws ERROR in server log file
We'd be happy to take patches for this. Currently, Review Board has no notion of commits that are blocked from being seen by the user. Would you be able to go into more detail on your repository setup? Christian -- Christian Hammond - christ...@beanbaginc.com Review Board - https://www.reviewboard.org Beanbag, Inc. - https://www.beanbaginc.com On September 12, 2014 at 8:26:52 PM, Bob Farmer (b...@bfarmer.net) wrote: Problem here seems to be that ReviewBoard doesn't handle the situation where there are revisions present that the repository user doesn't have access to. get_commits() fails because there is no commit['date'] for a given revision, when you have no access to the files that the revision affected. After putting in a workaround for that (by skipping over revisions with no date), noticed get_commits() seemed to be failing in the same way when running across revisions where commit['message'] was non-existent (I think if the user didn't put in a log message?) So, also needed to change a non-existent commit['message'] to be treated as an empty string. -BRF On Wednesday, September 3, 2014 4:39:31 PM UTC-5, Eugene wrote: My SVN repository (https://fs..com/svn-proj) has four directories. All of them show up in New Review Request for Committed Change drop-down box (on https://reviewboard..com/r/new/), but only selecting one of them works ok, i.e. loads recent commits. Selecting any other of the items results in empty list. Server log shows the info below. Pls advise what could be the reason for that and how to fix it? Thanks 21:22:02 INFO - Using reviewboard.scmtools.svn.pysvn backend for SVN 21:22:03 ERROR - Exception thrown for user eugene at https://reviewboard..com/api/repositories/1/commits/?branch=projapi_format=json u'date' Traceback (most recent call last): File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/core/handlers/base.py, line 112, in get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/cache.py, line 52, in _wrapped_view_func response = view_func(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/vary.py, line 19, in inner_func response = func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 494, in __call__ request, method, view, api_format=api_format, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 565, in call_method_view return view(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 110, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 33, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 287, in _validate return view_func(*args, **new_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/resources/repository_commits.py, line 84, in get items = repository.get_commits(branch=branch, start=start) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/models.py, line 328, in get_commits cache_period) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/cache/backend.py, line 118, in cache_memoize data = lookup_callable() File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/models.py, line 313, in lambda: self.get_scmtool().get_commits(**commits_kwargs) File
Re: Selecting items in New Review Request for Committed Change drop box doesn't work and throws ERROR in server log file
Nothing too out of the ordinary about our repository setup. There are simply directories that not everyone has access to (via SVN's authz file). If the user ReviewBoard is logging into the repo with doesn't have access to some things, then it chokes in a situation like this since it assumes it'll get full info on every revision. -BRF On Friday, September 12, 2014 10:32:00 PM UTC-5, Christian Hammond wrote: We'd be happy to take patches for this. Currently, Review Board has no notion of commits that are blocked from being seen by the user. Would you be able to go into more detail on your repository setup? Christian -- Christian Hammond - chri...@beanbaginc.com javascript: Review Board - https://www.reviewboard.org Beanbag, Inc. - https://www.beanbaginc.com On September 12, 2014 at 8:26:52 PM, Bob Farmer (bo...@bfarmer.net javascript:) wrote: Problem here seems to be that ReviewBoard doesn't handle the situation where there are revisions present that the repository user doesn't have access to. get_commits() fails because there is no commit['date'] for a given revision, when you have no access to the files that the revision affected. After putting in a workaround for that (by skipping over revisions with no date), noticed get_commits() seemed to be failing in the same way when running across revisions where commit['message'] was non-existent (I think if the user didn't put in a log message?) So, also needed to change a non-existent commit['message'] to be treated as an empty string. -BRF On Wednesday, September 3, 2014 4:39:31 PM UTC-5, Eugene wrote: My SVN repository (https://fs..com/svn-proj) has four directories. All of them show up in New Review Request for Committed Change drop-down box (on https://reviewboard..com/r/new/), but only selecting one of them works ok, i.e. loads recent commits. Selecting any other of the items results in empty list. Server log shows the info below. Pls advise what could be the reason for that and how to fix it? Thanks 21:22:02 INFO - Using reviewboard.scmtools.svn.pysvn backend for SVN 21:22:03 ERROR - Exception thrown for user eugene at https://reviewboard..com/api/repositories/1/commits/?branch=projapi_format=json u'date' Traceback (most recent call last): File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/core/handlers/base.py, line 112, in get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/cache.py, line 52, in _wrapped_view_func response = view_func(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/vary.py, line 19, in inner_func response = func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 494, in __call__ request, method, view, api_format=api_format, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 565, in call_method_view return view(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 110, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 33, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 287, in _validate return view_func(*args, **new_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/resources/repository_commits.py, line 84, in get items = repository.get_commits(branch=branch, start=start) File
Selecting items in New Review Request for Committed Change drop box doesn't work and throws ERROR in server log file
My SVN repository (https://fs.company.com/svn-proj) has four directories. All of them show up in New Review Request for Committed Change drop-down box (on https://reviewboard.company.com/r/new/), but only selecting one of them works ok, i.e. loads recent commits. Selecting any other of the items results in empty list. Server log shows the info below. Pls advise what could be the reason for that and how to fix it? Thanks 21:22:02 INFO - Using reviewboard.scmtools.svn.pysvn backend for SVN 21:22:03 ERROR - Exception thrown for user eugene at https://reviewboard.company.com/api/repositories/1/commits/?branch=projapi_format=json u'date' Traceback (most recent call last): File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/core/handlers/base.py, line 112, in get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/cache.py, line 52, in _wrapped_view_func response = view_func(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Django-1.6.6-py2.7.egg/django/views/decorators/vary.py, line 19, in inner_func response = func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 494, in __call__ request, method, view, api_format=api_format, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/resources.py, line 565, in call_method_view return view(request, *args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 110, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/decorators.py, line 33, in _check return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 117, in _call return view_func(*args, **kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/webapi/decorators.py, line 287, in _validate return view_func(*args, **new_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/webapi/resources/repository_commits.py, line 84, in get items = repository.get_commits(branch=branch, start=start) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/models.py, line 328, in get_commits cache_period) File /usr/local/python-2.7.8/lib/python2.7/site-packages/Djblets-0.8.9-py2.7.egg/djblets/cache/backend.py, line 118, in cache_memoize data = lookup_callable() File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/models.py, line 313, in lambda lambda: self.get_scmtool().get_commits(**commits_kwargs) File /usr/local/python-2.7.8/lib/python2.7/site-packages/ReviewBoard-2.0.6-py2.7.egg/reviewboard/scmtools/svn/__init__.py, line 182, in get_commits commit['date'].isoformat(), File /usr/local/python-2.7.8/lib/python2.7/UserDict.py, line 23, in __getitem__ raise KeyError(key) KeyError: u'date' -- Get the Review Board Power Pack at http://www.reviewboard.org/powerpack/ --- Sign up for Review Board hosting at RBCommons: https://rbcommons.com/ --- Happy user? Let us know at http://www.reviewboard.org/users/ --- You received this message because you are subscribed to the Google Groups reviewboard group. To unsubscribe from this group and stop receiving emails from it, send an email to reviewboard+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.