MozillaSecurity / MozillaSecurity/FuzzManager

[CrashManager] Handle exceptions from BugProvider

Open
#170 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug bugzilla crashmanager help wanted
Dominant language
Python
Stars
208
Forks
48
Avg merge
23h 5m
Merged PRs (30d)
2

Description

Environment:

Request Method: POST
Request URL: https://[snip]/crashmanager/crashes/204081/createbug/

Django Version: 1.7.1
Python Version: 2.7.6
Installed Applications:
('django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'ec2spotmanager',
'crashmanager',
'rest_framework',
'rest_framework.authtoken',
'chartjs')
Installed Middleware:
('django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.auth.middleware.RemoteUserMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'server.settings.ExceptionLoggingMiddleware')

Traceback:
File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py" in get_response

  1.                 response = wrapped_callback(request, _callback_args, *_callback_kwargs)
    
    File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/decorators.py" in _wrapped_view
  2.             return view_func(request, _args, *_kwargs)
    
    File "[snip]/FuzzManager/server/crashmanager/views.py" in createExternalBug
  3.     extBugId = provider.getInstance().handlePOSTCreate(request, entry)
    
    File "[snip]/FuzzManager/server/crashmanager/Bugtracker/BugzillaProvider.py" in handlePOSTCreate
  4.         raise RuntimeError("Failed to create bug: %s", ret)
    

Exception Type: RuntimeError at /crashmanager/crashes/204081/createbug/
Exception Value: ('Failed to create bug: %s', {u'code': 410, u'message': u'You must log in before using this part of Bugzilla.', u'documentation': u'http://www.bugzilla.org/docs/tip/en/html/api/', u'error': True})

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at crashmanager/views.py:createExternalBug and follow the BugProvider call into crashmanager/Bugtracker/BugzillaProvider.py:handlePOSTCreate. Review how exceptions from the provider currently reach Django, then inspect nearby tests or error-handling patterns. Done means provider failures are handled according to the intended issue behavior instead of producing the shown unhandled RuntimeError.

Written by the indexing model from the issue text.

Assessment

Tech stack
django, python
Domain
backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.