[click] allow downloads for published gratis apps without the user having to sign in to sca

Bug #1234872 reported by James Westby
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Software Center Agent
Fix Released
Critical
James Westby

Bug Description

  AttributeError: 'NoneType' object has no attribute 'has_perm'

      File "/srv/sc.ubuntu.com/production/software-center-agent/sourcecode/django/django/core/handlers/base.py", line 115, in get_response
    response = callback(request, *callback_args, **callback_kwargs)
  File "/srv/sc.ubuntu.com/production/software-center-agent/sourcecode/django/django/views/decorators/cache.py", line 89, in _wrapped_view_func
    response = view_func(request, *args, **kwargs)
  File "/srv/sc.ubuntu.com/production/software-center-agent/sourcecode/django/django/views/decorators/vary.py", line 19, in inner_func
    response = func(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/piston/resource.py", line 166, in __call__
    result = self.error_handler(e, request, meth, em_format)
  File "/usr/lib/python2.7/dist-packages/piston/resource.py", line 164, in __call__
    result = meth(request, *args, **kwargs)
  File "/srv/sc.ubuntu.com/production/software-center-agent/src/softwarecenteragent/api/handlers.py", line 267, in read
    is_reviewer = can_review(user, package)
  File "/srv/sc.ubuntu.com/production/software-center-agent/src/devportal/views.py", line 154, in can_review
    return user.has_perm('devportal.review_application')

This occurs if the user hasn't ever signed in to sca. We can still allow them to download published
gratis apps, but not anything that requires a user record (unpublished or paid).

James Westby (james-w)
Changed in software-center-agent:
status: New → In Progress
importance: Undecided → Critical
James Westby (james-w)
Changed in software-center-agent:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.