Python Package Changelog
Kolo consists of a python package and a VSCode extension. This is the changelog for the kolo
python package. To view the changelog of the VSCode Extension go here
We recommend using the latest version of the kolo python package and VSCode extension. That way you’ll run the most stable and feature-rich versions
Upcoming
Remove support for json traces (
use_msgpack=false
) that was deprecated in2.16.0
.Serialize
tuple
as a msgpack extension type to maintain hashability after deserializing.Serialize
set
andfrozenset
as msgpack extension types.Add support for custom field parsers for test generation.
Parse isoformat
date
strings in test generation.Support parsing negative
timedelta
strings in test generation.Convert non-string SQL Literal values to python values in test generation.
Improve generated asserts for delete queries in test generation.
Improve merging of generated asserts to simplify generated tests.
Remove the
list-traces
,dump-trace
,load-trace
anddelete-old-traces
commands deprecated in2.8.0
.Stop officially supporting Django 4.1.
2.17.0
2023-11-15
Add an early version of an editor agnostic kolo experience accessible via
localhost:8000/_kolo/
Fix some invalid timestamps in Kolo’s internal trace format when tracing a test that mocks time with
time_machine
.Improve parsing of
INSERT
queries in test generation.Support generating a test from a trace including multiple request/response sections. Previously we only used the first request/response pair.
Avoid duplicate arguments to
queryset.filter
in generated assert code for delete queries.Always include a request body when mocking outbound requests in generated tests. Previously we only supported json body data.
2.16.3
2023-11-01
Avoid crashing on unhashable query data in test generation.
2.16.2
2023-10-30
2.16.1
2023-10-26
Fix validation of a msgpack trace downloaded from the Kolo dashboard.
2.16.0
2023-10-26
Add support for using msgpack as an internal format for traces with the
use_msgpack
config option. This is on by default and requires version2.15.0
of the VSCode Extension. Support for json traces (use_msgpack=false
) is deprecated and will be removed in a future version.Add support for Python 3.12.
Remove the
wal_mode
config option.Log an error when a trace is too big to save to Kolo’s sqlite database.
Use timezone-aware datetimes in test generation.
Avoid generating code leading to a
MultipleObjectsReturned
exception in test generation.
2.15.1
2023-09-15
Hide
__builtins__
from module locals to save space and make raw traces more readable.Increase the default busy timeout for Kolo’s sqlite database to 60s (from 5s).
Allow setting
sqlite_busy_timeout
in.kolo/config.toml
.Add a lower bound (
3.6.0
) for the required version of asgiref.Fix handling of foreign key values in generated asserts for update queries.
Stop creating test model instances with
None
as a primary key in test generation.
2.15.0
2023-09-13
Remove unnecessary blank lines between asserts in generated tests.
Remove
refresh_from_db
calls from generated tests when there are no associated asserts.Merge generated asserts from insert, update and delete database queries together.
Improve support for generic foreign keys in test generation.
Make asgiref dependency explicit so Kolo can be used with older Django versions.
2.14.0
2023-09-04
Add support for generating tests using factory boy factories.
Change the behaviour of the
trace_processors
config value to append new processors instead of overriding the existing processors. This means you don’t need to copy the list of all Kolo’s default processors when adding your own custom processor.Prefer time machine over freezegun in generated tests. Freezegun will still be used if it is installed and time machine is not installed.
Add support for fields with custom column names in Kolo test generation.
Change test generation import style to a more human style.
Add extra hooks to Kolo’s default test generation templates to enable further customisation of generated tests.
Improve the quality of test asserts generated from database queries.
Handle traces including bulk creates better in test generation.
Add preliminary support for sharing traces via Kolo Dashboard.
Track Django checks to allow better filtering in VSCode.
Track Django test database creation to allow better filtering in VSCode.
Stop filtering out module creation frames from traces. This allows better visibility of import flow.
Fix file path resolution edge-case on Windows for Python 3.8 and 3.9.
Fix a deprecation warning for Content-Type header parsing.
2.13.2
2023-08-17
Turn off special handling of
namedtuple
insimplejson.dumps
since this was adding unexpected entries toMagicMock.mock_calls
in traced tests.
2.13.1
2023-08-09
Convert
NaN
and infinite float values tonull
when encoding json.
2.13.0
2023-07-26
Add
--count
and--reverse
options tokolo trace list
to allow customising the results.Add support for configuring Kolo in
pyproject.toml
in addition to.kolo/config.toml
. Fixes https://github.com/kolofordjango/kolo/issues/46.Track Django setup logic entrypoint to allow better filtering in VSCode.
Improve stability of experimental threading support.
2.12.4
2023-07-17
Really fix disabling of experimental threading support in the Rust extension.
2.12.3
2023-07-14
Fix disabling of experimental threading support in the Rust extension.
2.12.2
2023-07-12
Disable experimental threading support by default.
2.12.1
2023-07-06
Fix the rust extension’s handling of fake frame filenames. Fixes https://github.com/kolofordjango/kolo/issues/62.
2.12.0
2023-07-04
Replace a panic in the Rust extension when decoding json with a python exception for better debugging.
Add support for pypy 3.10.
Drop support for pypy 3.8 because the pypy project no longer support it.
2.11.0
2023-06-23
Add support for tracing httpx outbound requests.
Add
kolo dbshell
for advanced users to inspect or run queries against the Kolo database.Support json (de-)serialization of large numbers in the Rust extension.
2.10.0
2023-06-21
Update
KoloMiddleware
to handle async views as well as sync views. Fixes https://github.com/kolofordjango/kolo/issues/57.Allow customising the behaviour of test generation.
Improve sql query parsing for test generation.
Tweak the error message when test generation dependencies are missing. Fixes https://github.com/kolofordjango/kolo/issues/58.
Bump the minimum version of
sqlglot
to16.1.1
for better sqlite parsing in test generation.Drop support for Python 3.7.
2.9.4
2023-05-29
Omit json data from assert queries in test generation.
Fix variables in test generation.
2.9.3
2023-05-29
Improve support for json response bodies for httpretty in test generation.
Remove debug sql comments from generated tests.
2.9.2
2023-05-23
Try to autodetect the correct Django settings file from
manage.py
in test generation.Disable logging during test generation to avoid log messages in the generated test.
Handle Django’s
DurationField
better in test generation.Ensure string values in
get_or_create
defaults don’t getrepr
called twice in test generation.Add context to the top of the generated test file.
2.9.1
2023-05-19
Handle more edge-cases in test generation.
2.9.0
2023-05-12
Add support for Django ORM asserts to the experimental test generation feature.
2.8.1
2023-05-11
Turn a panic in the Rust extension into a Python exception for better debugging.
2.8.0
2023-05-03
Fix
IndexError
inExceptionFilter
when the exception doesn’t come from a recorded frame.Add
kolo trace
command withlist
,dump
,load
anddelete
subcommands.Deprecate the
list-traces
,dump-trace
,load-trace
anddelete-old-traces
commands.
2.7.0
2023-04-21
Store
date
anddatetime
values as timestamp strings in traces.Add the
kolo store-django-model-schema
command for use with the experimental test generation feature.
2.6.2
2023-04-18
Fix an
AttributeError
inRequestsFilter
when handling a bad response (for example in a timeout/retry).
2.6.1
2023-04-18
Raise a new
KoloWriteError
when Kolo fails to write to the.kolo
directory for some reason.
2.6.0
2023-03-17
Track which database each SQL query is for. Enables future work in the VSCode extension.
2.5.0
2023-03-15
Add the
kolo delete-old-traces
command.
2.4.4
2023-03-13
Fix a
KeyError
inUrllib3Filter
where a"response"
key could be missing (for example in a timeout/retry).
2.4.3
2023-03-13
Fix a
TypeError
in the Rust extension when trying to convertNone
to a string.Optimise how we process Django QuerySet objects in Python and Rust.
2.4.2
2023-02-15
Further improve the performance of the Rust extension by optimising string contains in a hot loop.
2.4.1
2023-01-30
Further improve the performance of the Rust extension by interning suitable strings.
2.4.0
2023-01-25
Use the Rust extension by default on CPython. To disable this set
use_rust = false
at the top of your.kolo/config.toml
.Improve the performance of the Rust extension by about 10%.
2.3.0
2022-12-01
Consolidate
kolo.enable
andkolo.enabled
into one combined context manager and decorator.Exclude library code from analysis properly on Windows for all supported python versions.
Exclude library code from analysis properly on PyPy 3.8 and 3.9.
Add an experimental Rust extension. To opt-in to this, set
use_rust = true
at the top of your.kolo/config.toml
.
2.2.1
2022-11-14
Fix a
TypeError
when serializing dictionary keys as json.
2.2.0
2022-11-01
Refactor Kolo’s internal serialization format to minimise runtime overhead. Requires version
2.2.0
of the VSCode extension.
2.1.0
2022-10-27
Add a
kolo list-traces
command to make it easier to share tracesOptimise Kolo’s hot profiling loop.
2.0.6
2022-10-18
Fix a
KeyError
in Kolo’s SQL query processing for empty queries.Stop json encoding errors breaking Kolo traces.
2.0.5
2022-10-13
Fix a
KeyError
in Kolo’s SQL query processing.Fix a
TypeError
in Kolo’s SQL query processing.
2.0.4
2022-10-10
Increase the log level of exceptions handled by Kolo from
debug
towarning
.Stop double-encoding data as json before saving it in the Kolo database. Requires version 2.1.1 or later of the VSCode extension.
2.0.3
2022-09-22
Stop autocreating an empty
.kolo/config.toml
file.
2.0.2
2022-09-15
2.0.1
2022-09-09
Don’t lose trace data when an object has a broken
__repr__
.
2.0.0
2022-09-09
Record when a background job ends when using eager mode for celery or huey.
Record data about Django template rendering.
Record the data loaded from the database by sql queries in Django.
Support tracing pytest tests with
kolo run
.Support user-defined includes and ignores when processing exceptions.
Add
--one-trace-per-test
option tokolo run
to better support analysing tests.Add
kolo load-trace
andkolo dump-trace
commands to support sharing interesting traces.Add experimental support for test generation with
kolo generate-test
.Add a timestamp to all trace items.
Ensure
.kolo/config.toml
exists so users don’t need to manually create it.Fix the
kolo.enable
decorator so it actually works as a decorator with theconfig
argument.Stop storing config data in Kolo’s database.
Remove the
kolo config
command.
1.8.0
2022-07-22
Fix threadsafety bug in
KoloMiddleware
causing traces to be lost when too many requests happen close together withmanage.py runserver
.Optimise the main profiling loop by 30-40%.
Drop support for setting
use_frame_boundaries
tofalse
.
1.7.0
2022-06-30
Change the default value of
use_frame_boundaries
totrue
.
1.6.1
2022-06-30
Fix a bug with 404 response handling when
use_frame_boundaries = true
.
1.6.0
2022-06-29
Make a new mode of collecting traces available via
use_frame_boundaries = true
in.kolo/config.toml
where each trace does not necessarily have to start with a served HTTP request and does not necessarily have to end with an HTTP responseAdd the
kolo.enable
decoratorAdd the
kolo.enabled
context managerUpgrade dependencies
Fix a bug with args serialization the logging filter
1.5.0
2022-06-15
Start using SQLite WAL-mode, which allows for both writing and reading to SQLite at the same time.
Kolo will now always store its db in the
.kolo
directory. The previously deprecated storage location using the operating system’s user data directory is no longer supported. TheKOLO_STORE_IN_PROJECT
andKOLO_PROJECT_NAME
settings are no longer supported –KOLO_STORE_IN_PROJECT
is now always true.Numerous performance improvements to speed up Kolo
Add support for a logging filter, so that Kolo can capture log output for later display
1.4.0
2022-04-18
Use repr as a fallback when serializing locals. Fixes https://github.com/kolofordjango/kolo/issues/15
Better support for outbound HTTP requests with binary request bodies
Make use of Django’s MiddlewareNotUsed when Kolo is disabled
Handle case where the actual charset in an HTTP response is different from the expected one. Fixes https://github.com/kolofordjango/kolo/issues/13
Drop support for Python 3.6 and Django 2.2, 3.0, 3.1 as all these versions have reached their end of life
Include qualname information in frame data
1.3.8
2022-03-14
Kolo will no longer crash if
git
isn’t available while recording a trace
1.3.7
2022-02-22
Fix bug where kolo would error when the request body included binary content. Thanks @abdulmuizzf for the report 🙌
1.3.6
2022-02-08
A whole host of performance improvements that should make using Kolo feel a lot snappier!
1.3.5
2022-02-07
Support for huey tasks (on the python side)
Re-create the kolo sqlite database if we detect it has been deleted while kolo is active
Include query template in recorded SQL data
Fix crash when kolo is processing a streaming HttpResponse
Further stability improvements
1.3.4
2022-01-12
Fix a regression in 1.3.3 where Kolo was throwing an error when it was disabled
1.3.3
2022-01-12
Fix a dependency incompatibility issue by moving our build process from poetry to pip + setup.cfg
Capture urls information for the request Django is processing
1.3.2
2021-12-12
Support for Django 4.0
1.3.1
2021-11-25
Support for standard library
urllib
Better support for when
urllib3
is used standalone (withoutrequests
)Decompress gzipped HttpRespones for display in Kolo (Fixes https://github.com/kolofordjango/kolo/issues/10)
1.3.0
2021-11-10
Default to storing the Kolo database in
.kolo/db.sqlite3
. The.kolo
directory is adjacent to yourmanage.py
file by default and can otherwise be customized using theKOLO_PATH
environment variableThis change is backwards compatible. Kolo will continue to read and write data to the previous database location if it detects an existing database present
Store milliseconds for
created_at
timestamps in the Kolo database
1.2.1
2021-10-26
Fix issue where Kolo would exhaust iterators as part of processing a frame: https://github.com/kolofordjango/kolo/issues/9
1.2.0
2021-10-25
Capture the call site for each captured frame
Store Kolo database in
.kolo
(alongside the user’s working directory) via theKOLO_STORE_IN_PROJECT=1
environment variable. (To be the default soon)Capture information about where in the user code SQL queries originate
1.1.3
2021-09-30
Collect
scheme
from the incoming HTTP request which assists the VSCode extension in reliably replaying requests
1.1.2
2021-09-21
Fix bug where Kolo would cause additional SQL queries when the evaluation of a third party
__repr__
would call__repr__
on a django queryset. Specifically this was the case with Django Rest Framework (as with the previous change log item, credit to @vhtkrk for reporting this https://github.com/kolofordjango/kolo/issues/4)
1.1.1
2021-09-20
Fix bug where Kolo would prematurely evaluate not-yet-evaluated Querysets (credit to @vhtkrk for reporting this bug!)
1.1.0
2021-09-16
Additional configuration options via .kolo/config.toml
You can now configure Kolo to exclude certain URL paths (like
/static/
) and also explicitly include and exclude frames based on filepath
Better support for capturing those exceptions that lead to a 500 error
Several bug fixes and stability improvements!
1.0.4
2021-08-19
Exclude attrs generated frames. The refactor of the 1.0.0 release resulted in these being included, but now they’re excluded again!
1.0.3
2021-08-11
Add changelog link pointing at this file on PyPI page: https://pypi.org/project/kolo/
1.0.2
2021-08-11
Fix classifiers from 1.0.1. Now they actually show up: https://pypi.org/project/kolo/
1.0.1
2021-08-11
Add relevant PyPI classifiers: https://pypi.org/classifiers/
1.0.0
2021-08-10
Support for Python 3.6
Refactored how we exclude library code. If you start seeing library code show up in Kolo, please open a new issue on this repo
Kolo now has better support for showing code that was executed as part of a custom middleware that you have in your Django project
Kolo will now disable itself if it detects another profiler present (a log message will be shown in this case)
A whole host of performance and stability improvements
Introduced more logging to show when Kolo is disabling itself
Bringing the major version number to 1, to ensure the
kolo
python package and VSCode extension always share the same major version number
0.0.5
2021-06-10
Support for Python 3.7
0.0.4
2021-06-04
Improve README shown on PyPI
0.0.3
2021-06-04
Use INSERT OR IGNORE to prevent bug where the same invocation would be inserted twice into sqlite leading to a confusing user-visible error message
0.0.2
2021-05-26
Capture timestamps as floats instead of ints, because we’re basically always operating at the sub-second level
0.0.1
2021-05-23
Initial release. New to Kolo? Check out our website and the announcement video