Klaas van Schelven 53d4be8183 Fix 'different_runtime_limit' race conditions
This commit fixes 3 related issues with the way runtime_limit was administered;
which could lead to race conditions (and hence: the wrong runtime_limit
applying at some point in time). Post-fix, the folllowing holds:

1. We use thread_locals to store this info, since there are at least 2 sources of
    threaded code that touch this (snappea's workers and the django debugserver)

2. We distinguish between the "from connection settings" timeout and the
    "temporarily overridden" ones, since we cannot assume
    connection-initialization happens first (as per the comment in base.py)

3. We store runtime-limits per alias ('using'). Needed for [2] (each connection
    may have a different moment-of-initialization, clobbering CM-set values from
    the other connection) and also needed once you realize there may be
    different defaults for the timeouts.

General context: I've recently started introducing the 'different runtime'
helper quite a bit more; and across connections (snappea!), which created more
and more doubts as to it actually working as advertised.

Thoughts on "using" being required. I used to think "you can reason about a
global timeout value, and the current transaction makes clear what you're
actually doing", but as per the notes above that doesn't really work.

Thoughts on reproducing:
A few thoughts/notes on reproducing problems with race conditions. Basic note:
that's always hairy. So in the end I settled on a solution that's hopefully
easy to reason about, even if it's verbose.

When I started work on this commit, I focussed on thread-safety; "proving the
problem" consisted of F5/^R on a web page with 2 context managers with different
timeouts, hoping to show that the stack unrolling didn't work properly.
However, during those "tests" I noticed quite a few resets-to-5s (from the
connection defaults), which prompted fix [2] from above.
2025-04-22 22:08:53 +02:00
2025-04-17 22:03:23 +02:00
2025-01-29 13:37:31 +01:00
2025-04-14 11:49:41 +02:00
2024-12-18 09:20:50 +01:00
2025-04-06 15:00:54 +02:00
2025-04-17 22:03:23 +02:00
2025-04-17 22:03:23 +02:00
2025-04-11 11:24:50 +02:00
2025-04-14 11:48:00 +02:00
2025-04-04 17:32:01 +02:00
2025-01-30 15:23:23 +01:00
2025-02-26 16:34:47 +01:00

Bugsink: Self-hosted Error Tracking

Bugsink offers Error Tracking for your applications with full control through self-hosting.

Screenshot

This is what you'll get:

Screenshot

Installation & docs

The quickest way to evaluate Bugsink is to spin up a throw-away instance using Docker:

docker pull bugsink/bugsink:latest

docker run \
  -e SECRET_KEY={{ random_secret }} \
  -e CREATE_SUPERUSER=admin:admin \
  -e PORT=8000 \
  -p 8000:8000 \
  bugsink/bugsink

Visit http://localhost:8000/, where you'll see a login screen. The default username and password are admin.

Now, you can set up your first project and start tracking errors.

Detailed installation instructions are on the Bugsink website.

More information and documentation

Description
No description provided
Readme 6.2 MiB
Languages
Python 80.6%
HTML 17.5%
CSS 0.9%
JavaScript 0.6%
Shell 0.3%
Other 0.1%