- index: Fixed fetching
migration
operations.
- exceptions: Fixed incorrect formatting and broken links in help messages.
- index: Fixed crash when the only index in config is
head
. - index: Fixed fetching originations during initial sync.
- index: Fixed crash when no block with the same level arrived after a single-level rollback.
- index: Fixed setting initial index level when
IndexConfig.first_level
is set. - tzkt: Fixed delayed emitting of buffered realtime messages.
- tzkt: Fixed inconsistent behavior of
first_level
/last_level
arguments in different getter methods.
- context: Fixed reporting incorrect reindexing reason.
- exceptions: Fixed crash with
FrozenInstanceError
when an exception is raised from a callback. - jobs: Fixed graceful shutdown of daemon jobs.
- codegen: Refined
on_rollback
hook template. - exceptions: Updated help messages for known exceptions.
- tzkt: Do not request reindexing if missing subgroups have matched no handlers.
- cli: Fixed
schema init
command crash with SQLite databases. - index: Fixed spawning datasources in oneshot mode.
- tzkt: Fixed processing realtime messages.
This release contains no changes except for the version number.
- tzkt: Added ability to process realtime messages with lag.
- config: Fixed
jobs
config section validation. - hasura: Fixed metadata generation for v2.3.0 and above.
- tzkt: Fixed
get_originated_contracts
andget_similar_contracts
methods response.
- config: Added
custom
section to store arbitrary user data.
- config: Fixed default SQLite path (
:memory:
). - tzkt: Fixed pagination in several getter methods.
- tzkt: Fixed data loss when
skip_history
option is enabled.
- config: Removed dummy
advanced.oneshot
flag. - cli: Removed
docker init
command. - cli: Removed dummy
schema approve --hashes
flag.
- tzkt: Fixed crash in methods that do not support cursor pagination.
- prometheus: Fixed invalid metric labels.
- metadata: Added
metadata_interface
feature flag to expose metadata in TzKT format. - prometheus: Added ability to expose Prometheus metrics.
- tzkt: Added missing fields to the
HeadBlockData
model. - tzkt: Added
iter_...
methods to iterate over item batches.
- tzkt: Fixed possible OOM while calling methods that support pagination.
- tzkt: Fixed possible data loss in
get_originations
andget_quotes
methods.
- tzkt: Added
offset
andlimit
arguments to all methods that support pagination.
- bcd: Removed
bcd
datasource and config section.
- dipdup: Use fast
orjson
library instead of built-injson
where possible.
- database: Fixed generating table names from uppercase model names.
- http: Fixed bug that leads to caching invalid responses on the disk.
- tzkt: Fixed processing realtime messages with data from multiple levels.
- database: Do not add the
schema
argument to the PostgreSQL connection string when not needed. - hasura: Wait for Hasura to be configured before starting indexing.
- config: Added
http
datasource to making arbitrary http requests.
- context: Fixed crash when calling
fire_hook
method. - context: Fixed
HookConfig.atomic
flag, which was ignored infire_hook
method. - database: Create missing tables even if
Schema
model is present. - database: Fixed excess increasing of
decimal
context precision. - index: Fixed loading handler callbacks from nested packages (@veqtor).
- ci: Added GitHub Action to build and publish Docker images for each PR opened.
- ci: Removed
black 21.12b0
dependency since bug indatamodel-codegen-generator
is fixed. - cli: Fixed
config export
command crash whenadvanced.reindex
dictionary is present. - cli: Removed optionals from
config export
output so the result can be loaded again. - config: Verify
advanced.scheduler
config for the correctness and unsupported features. - context: Fixed ignored
wait
argument offire_hook
method. - hasura: Fixed processing relation fields with missing
related_name
. - jobs: Fixed default
apscheduler
config. - tzkt: Fixed crash occurring when reorg message is the first one received by the datasource.
- config: Fixed
ipfs
datasource config.
- ci: Added
black 21.12b0
dependency to avoid possible conflict withdatamodel-codegen-generator
.
- context: Added
wait
argument tofire_hook
method to escape current transaction context. - context: Added
ctx.get_<kind>_datasource
helpers to avoid type casting. - hooks: Added ability to configure
apscheduler
withAdvancedConfig.scheduler
field. - http: Added
request
method to send arbitrary requests (affects all datasources). - ipfs: Added
ipfs
datasource to download JSON and binary data from IPFS.
- http: Removed dangerous method
close_session
. - context: Fixed help message of
IndexAlreadyExistsError
exception.
- bcd: Added deprecation notice.
- dipdup: Removed unused internal methods.
- cli: Added
schema wipe --force
argument to skip confirmation prompt.
- cli: Show warning about deprecated
--hashes
argument - cli: Ignore
SIGINT
signal when shutdown is in progress. - sentry: Ignore exceptions when shutdown is in progress.
- cli: Fixed stacktraces missing on exception.
- cli: Fixed wrapping
OSError
withConfigurationError
during config loading. - hasura: Fixed printing help messages on
HasuraError
. - hasura: Preserve a list of sources in Hasura Cloud environments.
- hasura: Fixed
HasuraConfig.source
config option.
- cli: Unknown exceptions are no longer wrapped with
DipDupError
.
- hasura: Removed some useless requests.
- cli: Added
schema init
command to initialize database schema. - cli: Added
--force
flag tohasura configure
command. - codegen: Added support for subpackages inside callback directories.
- hasura: Added
dipdup_head_status
view and REST endpoint. - index: Added an ability to skip historical data while synchronizing
big_map
indexes. - metadata: Added
metadata
datasource. - tzkt: Added
get_big_map
andget_contract_big_maps
datasource methods.
- index: Fixed deserializing manually modified typeclasses.
- cli: Added
--keep-schemas
flag toinit
command to preserve JSONSchemas along with generated types.
- demos: Tezos Domains and Homebase DAO demos were updated from edo2net to mainnet contracts.
- hasura: Fixed missing relations for models with
ManyToManyField
fields. - tzkt: Fixed parsing storage with nested structures.
- dipdup: Minor overall performance improvements.
- ci: Cache virtual environment in GitHub Actions.
- ci: Detect CI environment and skip tests that fail in GitHub Actions.
- ci: Execute tests in parallel with
pytest-xdist
when possible. - ci: More strict linting rules of
flake8
.
- tzkt: Fixed parsing parameter with an optional value.
- tzkt: Added optional
delegate_address
anddelegate_alias
fields toOperationData
.
- tzkt: Fixed crash due to unprocessed pysignalr exception.
- tzkt: Fixed parsing
OperationData.amount
field. - tzkt: Fixed parsing storage with top-level boolean fields.
- codegen: Fixed generating storage typeclasses with
Union
fields. - codegen: Fixed preprocessing contract JSONSchema.
- index: Fixed processing reindexing reason saved in the database.
- tzkt: Fixed processing operations with default entrypoint and empty parameter.
- tzkt: Fixed crash while recursively applying bigmap diffs to the storage.
- tzkt: Increased speed of applying bigmap diffs to operation storage.
This release contains no changes except for the version number.
- cli: Fixed missing
schema approve --hashes
argument. - codegen: Fixed contract address used instead of an alias when typename is not set.
- tzkt: Fixed processing operations with entrypoint
default
. - tzkt: Fixed regression in processing migration originations.
- tzkt: Fixed filtering of big map diffs by the path.
- cli: Removed deprecated
run --oneshot
argument andclear-cache
command.
- Run
dipdup init
command to generateon_synchronized
hook stubs.
- hooks: Added
on_synchronized
hook, which fires each time all indexes reach realtime state.
- cli: Fixed config not being verified when invoking some commands.
- codegen: Fixed generating callback arguments for untyped operations.
- index: Fixed incorrect log messages, remove duplicate ones.
- index: Fixed crash while processing storage of some contracts.
- index: Fixed matching of untyped operations filtered by
source
field (@pravin-d).
- index: Checks performed on each iteration of the main DipDup loop are slightly faster now.
- Run
dipdup schema approve
command on every database you want to use with 4.0.0-rc1. Runningdipdup migrate
is not necessary sincespec_version
hasn't changed in this release.
- cli: Added
run --early-realtime
flag to establish a realtime connection before all indexes are synchronized. - cli: Added
run --merge-subscriptions
flag to subscribe to all operations/big map diffs during realtime indexing. - cli: Added
status
command to print the current status of indexes from the database. - cli: Added
config export [--unsafe]
command to print config after resolving all links and variables. - cli: Added
cache show
command to get information about file caches used by DipDup. - config: Added
first_level
andlast_level
optional fields toTemplateIndexConfig
. These limits are applied after ones from the template itself. - config: Added
daemon
boolean field toJobConfig
to run a single callback indefinitely. Conflicts withcrontab
andinterval
fields. - config: Added
advanced
top-level section.
- cli: Fixed crashes and output inconsistency when piping DipDup commands.
- cli: Fixed
schema wipe --immune
flag being ignored. - codegen: Fixed missing imports in handlers generated during init.
- coinbase: Fixed possible data inconsistency caused by caching enabled for method
get_candles
. - http: Fixed increasing sleep time between failed request attempts.
- index: Fixed invocation of head index callback.
- index: Fixed
CallbackError
raised instead ofReindexingRequiredError
in some cases. - tzkt: Fixed resubscribing when realtime connectivity is lost for a long time.
- tzkt: Fixed sending useless subscription requests when adding indexes in runtime.
- tzkt: Fixed
get_originated_contracts
andget_similar_contracts
methods whose output was limited toHTTPConfig.batch_size
field. - tzkt: Fixed lots of SignalR bugs by replacing
aiosignalrcore
library withpysignalr
.
- cli:
dipdup schema wipe
command now requires confirmation when invoked in the interactive shell. - cli:
dipdup schema approve
command now also causes a recalculation of schema and index config hashes. - index: DipDup will recalculate respective hashes if reindexing is triggered with
config_modified: ignore
orschema_modified: ignore
in advanced config.
- cli:
run --oneshot
option is deprecated and will be removed in the next major release. The oneshot mode applies automatically whenlast_level
field is set in the index config. - cli:
clear-cache
command is deprecated and will be removed in the next major release. Usecache clear
command instead.
- config: Configuration files are loaded 10x times faster.
- index: Number of operations processed by matcher reduced by 40%-95% depending on the number of addresses and entrypoints used.
- tzkt: Rate limit was increased. Try to set
connection_timeout
to a higher value if requests fail withConnectionTimeout
exception. - tzkt: Improved performance of response deserialization.
- codegen: Fixed missing imports in operation handlers.
- codegen: Fixed invalid imports and arguments in big_map handlers.
- Fixed crash occurred during synchronization of big map indexes.
- Fixed loss of realtime subscriptions occurred after TzKT API outage.
- Fixed updating schema hash in
schema approve
command. - Fixed possible crash occurred while Hasura is not ready.
- New index class
HeadIndex
(configuration:dipdup.config.HeadIndexConfig
). Use this index type to handle head (limited block header content) updates. This index type is realtime-only: historical data won't be indexed during the synchronization stage. - Added three new commands:
schema approve
,schema wipe
, andschema export
. Rundipdup schema --help
command for details.
- Triggering reindexing won't lead to dropping the database automatically anymore.
ReindexingRequiredError
is raised instead.--forbid-reindexing
option has become default. --reindex
option is removed. Usedipdup schema wipe
instead.- Values of
dipdup_schema.reindex
field updated to simplify querying database. Seedipdup.enums.ReindexingReason
class for possible values.
- Fixed
ReindexRequiredError
not being raised when running DipDup after reindexing was triggered. - Fixed index config hash calculation. Hashes of existing indexes in a database will be updated during the first run.
- Fixed issue in
BigMapIndex
causing the partial loss of big map diffs. - Fixed printing help for CLI commands.
- Fixed merging storage which contains specific nested structures.
- Raise
DatabaseConfigurationError
exception when project models are not compatible with GraphQL. - Another bunch of performance optimizations. Reduced DB pressure, speeded up parallel processing lots of indexes.
- Added initial set of performance benchmarks (run:
./scripts/run_benchmarks.sh
)
- A significant increase in indexing speed.
- Fixed unexpected reindexing caused by the bug in processing zero- and single-level rollbacks.
- Removed unnecessary file IO calls that could cause
PermissionError
exception in Docker environments. - Fixed possible violation of block-level atomicity during realtime indexing.
- Public methods of
TzktDatasource
now return immutable sequences.
- Fixed processing of single-level rollbacks emitted before rolled back head.
- Human-readable
CHANGELOG.md
🕺 - Two new options added to
dipdup run
command:--forbid-reindexing
– raiseReindexingRequiredError
instead of truncating database when reindexing is triggered for any reason. To continue indexing with existing database runUPDATE dipdup_schema SET reindex = NULL;
--postpone-jobs
– job scheduler won't start until all indexes are synchronized.
- Migration to this version requires reindexing.
dipdup_index.head_id
foreign key removed.dipdup_head
table still contains the latest blocks from Websocket received by each datasource.
- Removed unnecessary calls to TzKT API.
- Fixed removal of PostgreSQL extensions (
timescaledb
,pgcrypto
) by functiontruncate_database
triggered on reindex. - Fixed creation of missing project package on
init
. - Fixed invalid handler callbacks generated on
init
. - Fixed detection of existing types in the project.
- Fixed race condition caused by event emitter concurrency.
- Capture unknown exceptions with Sentry before wrapping to
DipDupError
. - Fixed job scheduler start delay.
- Fixed processing of reorg messages.
- Added
get_quote
andget_quotes
methods toTzKTDatasource
.
- Defer spawning index datasources until initial sync is complete. It helps to mitigate some WebSocket-related crashes, but initial sync is a bit slower now.
- Fixed possible race conditions in
TzKTDatasource
. - Start
jobs
scheduler after all indexes sync with a current head to speed up indexing.