django-session-timeout icon indicating copy to clipboard operation
django-session-timeout copied to clipboard

Add ability to ignore certain URL paths when determining whether there is website activity

Open ewoudenberg-kasisto opened this issue 4 years ago • 0 comments

Use Case

On some websites, regular "polling" accesses may be made by browser code to certain paths within the website. This will cause the session activity timer to incorrectly assume that there is still user activity when in fact the activity stems only from browser code. This change allows the session-timeout code to ignore user-specified paths.

The paths are configured as a single Regular Expression string in the SESSION_ACTIVITY_IGNORED_PATHS_REGEX variable in settings.py. Multiple paths are separated by the "|" (regex "or) character.

See the example in the Readme file.

ewoudenberg-kasisto avatar Aug 17 '21 19:08 ewoudenberg-kasisto