ceys / django-tracking

Automatically exported from code.google.com/p/django-tracking
MIT License
0 stars 0 forks source link

Appending to NO_TRACKING_PREFIXES in middleware.py #13

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Using NO_TRACKING_PREFIXES list in settings 
2. printing prefixes from middleware to console

What is the expected output? What do you see instead?
I expect that prefixes will contain the same number of entries for every 
request.

It looks like prefixes appends to settings.NO_TRACKING_PREFIXES for every 
request. This means 
the prefixes list increases in length every time.

What version of the product are you using? On what operating system?
django-tracking 0.2.7, django 1.1.1

Please provide any additional information below.

To fix this, the list is copied to prefixes on line 52 or middleware.py:

        prefixes = utils.get_untracked_prefixes()[:]

Original issue reported on code.google.com by specialb...@gmail.com on 7 Dec 2009 at 5:44

GoogleCodeExporter commented 8 years ago
I've finally fixed this in 0.3.0.  I moved the NO_TRACKING_PREFIXES stuff out 
of the middleware so it doesn't add extra overhead on each request.

Thanks!

Original comment by wheaties...@gmail.com on 27 Dec 2010 at 5:07