Skip to content
This repository has been archived by the owner on Oct 23, 2023. It is now read-only.

Commit

Permalink
Dont mutate RAVEN_CONFIG
Browse files Browse the repository at this point in the history
  • Loading branch information
dcramer committed Jan 9, 2015
1 parent e7e51cb commit 37779ee
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion raven/contrib/django/models.py
Expand Up @@ -10,6 +10,7 @@

from __future__ import absolute_import, unicode_literals

import copy
import logging
import sys
import warnings
Expand Down Expand Up @@ -120,7 +121,7 @@ def get_client(client=None):
module, class_name = client.rsplit('.', 1)

ga = lambda x, d=None: getattr(django_settings, 'SENTRY_%s' % x, d)
options = getattr(django_settings, 'RAVEN_CONFIG', {})
options = copy.deepcopy(getattr(django_settings, 'RAVEN_CONFIG', {}))
options.setdefault('servers', ga('SERVERS'))
options.setdefault('include_paths', ga('INCLUDE_PATHS', []))
options['include_paths'] = set(options['include_paths']) | get_installed_apps()
Expand Down

0 comments on commit 37779ee

Please sign in to comment.