Sébastien Corbin
Sébastien Corbin
Had the same problem with `pdfjs-dist` including canvas as optional, `npm i --no-optional` did the work for me
`SILKY_ANALYZE_QUERIES` is only removing `EXPLAIN ANALYZE` not all `EXPLAIN` queries. This would a be a feature request
In the meantime, I suggest you to try [subclassing your database backend](https://docs.djangoproject.com/en/3.2/ref/databases/#subclassing-the-built-in-database-backends) and set `supports_explaining_query_execution = False` in it
Activating the middleware means you add the mechanic of intercepting SQL queries, you can paste the whole exception to get more info.
I would advise you to only add silk's middleware when `DEBUG = True` so that it does not interfere with your tests
Then your tests should not be run with `DEBUG = True` as per https://docs.djangoproject.com/en/4.1/topics/testing/overview/#other-test-conditions so please double check you test configuration
This can happen with [atomic requests](https://docs.djangoproject.com/en/5.0/topics/db/transactions/#tying-transactions-to-http-requests) or any transaction started, overall it's just a question of your code having raised an exception, and after the debug view is being rendered,...
@albertyw sure, is there something blocking this one https://github.com/jazzband/django-silk/pull/439 ?
I suggest to release a `5.0.3` with #594 and then a major one `5.1.0` (maybe with beta) with #631, #619 and more later
@ulgens yes, see the related issue and last comment https://github.com/jazzband/django-silk/issues/214#issuecomment-1321204137