Skip to content

Commit 38b361d

Browse files
committed
Fixing opencensus overflow during testing
1 parent 30d32f4 commit 38b361d

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

main/settings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@
368368

369369
APPLICATION_INSIGHTS_INSTRUMENTATION_KEY = env('APPLICATION_INSIGHTS_INSTRUMENTATION_KEY')
370370

371-
if APPLICATION_INSIGHTS_INSTRUMENTATION_KEY:
371+
if not TESTING and APPLICATION_INSIGHTS_INSTRUMENTATION_KEY:
372372
MIDDLEWARE.append('opencensus.ext.django.middleware.OpencensusMiddleware')
373373
OPENCENSUS = {
374374
'TRACE': {

main/urls.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
Including another URLconf
1313
1. Import the include() function: from django.conf.urls import url, include
1414
2. Add a URL to urlpatterns: url(r'^blog/', include('blog.urls'))
15+
If you are looking for an api endpoint, search also url_path in other files.
1516
"""
1617
from django.views.decorators.clickjacking import xframe_options_exempt
1718
from django.conf.urls import url, include

0 commit comments

Comments
 (0)