diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 10c8ca0fa..ab52a9ed8 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -46,7 +46,7 @@ jobs: with: images: | dipdup/dipdup - ${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_IMAGE_NAME }}/dipdup + ${{ env.DOCKER_REGISTRY }}/${{ env.DOCKER_IMAGE_NAME }} flavor: | latest=false tags: | @@ -79,6 +79,7 @@ jobs: - name: Publish package on PyPi run: pdm publish --password ${{secrets.PYPI_TOKEN}} + # FIXME: Fails on prereleases; https://github.com/mindsers/changelog-reader-action/pull/39 - name: Parse changelog id: changelog uses: mindsers/changelog-reader-action@v2 @@ -97,7 +98,7 @@ jobs: ## ${{ steps.changelog.outputs.version }} - ${{ steps.changelog.outputs.date }} ${{ steps.changelog.outputs.changes }} - draft: true + draft: false prerelease: ${{ steps.changelog.outputs.status == 'prereleased' }} - name: Create Sentry release diff --git a/.gitignore b/.gitignore index d2942494b..fa06b16cc 100644 --- a/.gitignore +++ b/.gitignore @@ -29,4 +29,6 @@ # Docs !docs/** -docs/_build \ No newline at end of file +docs/_build + +dipdup_indexer \ No newline at end of file diff --git a/CHANGELOG.md b/CHANGELOG.md index 330c905e7..428897af8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog], and this project adheres to [Semantic Versioning]. -## [Unreleased] +## [7.0.0rc4] - 2023-08-23 ### Added @@ -17,9 +17,9 @@ The format is based on [Keep a Changelog], and this project adheres to [Semantic - cli: Fixed `schema wipe` command crash due to `dipdup_meta` table being always immune. - config: Don't create empty SentryConfig if DSN is not set. - context: Share internal state between context instances. +- evm.node: Fixed keepalive loop for websocket connection. +- evm.node: Fixed parsing empty realtime message payloads. - jobs: Don't add jobs before scheduler is started. -- node: Fixed keepalive loop for websocket connection. -- node: Fixed parsing empty realtime message payloads. - package: Fixed package detection for poetry managed projects. - package: Fixed mypy command in default template. - package: Create package symlink only when needed. @@ -1141,7 +1141,8 @@ This release contains no changes except for the version number. [semantic versioning]: https://semver.org/spec/v2.0.0.html -[Unreleased]: https://github.com/dipdup-io/dipdup/compare/7.0.0rc3...HEAD +[Unreleased]: https://github.com/dipdup-io/dipdup/compare/7.0.0rc4...HEAD +[7.0.0rc4]: https://github.com/dipdup-io/dipdup/compare/7.0.0rc3...7.0.0rc4 [7.0.0rc3]: https://github.com/dipdup-io/dipdup/compare/7.0.0rc2...7.0.0rc3 [6.5.10]: https://github.com/dipdup-io/dipdup/compare/6.5.9...6.5.10 [7.0.0rc2]: https://github.com/dipdup-io/dipdup/compare/7.0.0rc1...7.0.0rc2 diff --git a/docs/0.quickstart-evm.md b/docs/0.quickstart-evm.md new file mode 100644 index 000000000..9b9f93314 --- /dev/null +++ b/docs/0.quickstart-evm.md @@ -0,0 +1,187 @@ +--- +title: "Quickstart on EVM" +description: "This page will guide you through the steps to get your first selective indexer up and running in a few minutes without getting too deep into the details." +navigation.icon: "stars" +network: "ethereum" +--- + +# Quickstart + +This page will guide you through the steps to get your first selective indexer up and running in a few minutes without getting too deep into the details. + +Let's create an indexer for the [USDt token contract](https://etherscan.io/address/0xdac17f958d2ee523a2206206994597c13d831ec7). Our goal is to save all token transfers to the database and then calculate some statistics of its holders' activity. + +## Install DipDup + +A modern Linux/macOS distribution with Python 3.11 installed is required to run DipDup. + +We have a [convenient installer](https://dipdup.io/install.py) that will install DipDup and all the required dependencies for you. It uses pipx to install DipDup as a CLI application and make it available everywhere for the current user. Run the following command in your terminal: + +```shell [Terminal] +curl -Lsf https://dipdup.io/install.py | python3 +``` + +If you don't want to use our script, install DipDup manually using commands from the snippet below. You can use any Python package manager you like, but we recommend [PDM](https://pdm.fming.dev/latest/) and provide some useful scripts for it. Here are some spells to get you started: + +```shell [Terminal] +# pipx +pipx install dipdup datamodel-code-generator + +# PDM +pdm init --python 3.11 --lib # use "">=3.11,<3.12" for requires-python +pdm venv create +pdm add "dipdup>=7.0.0rc4,<8" --venv +$(pdm venv activate) + +# Poetry +poetry init --python ">=3.11,<3.12" +poetry add "dipdup>=7.0.0rc4,<8" +poetry shell + +# pip + venv +python -m venv .venv +. .venv/bin/activate +echo "dipdup>=7.0.0rc4,<8" > requirements.txt +pip install -r requirements.txt -e . +``` + +## Create a project + +DipDup CLI has a built-in project generator. Run the following command in your terminal: + +```shell [Terminal] +dipdup new +``` + +For educational purposes, we'll create a project from scratch, so choose `[none]` network and `demo_blank` template. + +::banner{type="note"} +Want to skip a tutorial? Choose `EVM-compatible` and `demo_evm_events` instead! +:: + +Follow the instructions; the project will be created in the new directory. + +## Write a configuration file + +In the project root, you'll find a file named `dipdup.yaml`. It's the main configuration file of your indexer. We will discuss it in detail in the [Config](1.getting_started/3.config.md) section; for now just replace its content with the following: + +```yaml [dipdup.yaml] +{{ #include ../src/demo_evm_events/dipdup.yaml }} +``` + +## Generate types and stubs + +Now it's time to generate typeclasses and callback stubs based on definitions from config. Examples below use `demo_evm_events` as a package name; yours may differ. + +Run the following command: + +```shell [Terminal] +dipdup init +``` + +DipDup will create a Python package `demo_evm_events` with everything you need to start writing your indexer. Use `package tree` command to see the generated structure: + +```shell [Terminal] +$ dipdup package tree +demo_evm_events [.] +├── abi +│ ├── eth_usdt/abi.json +│ └── eth_usdt/events.json +├── configs +│ ├── dipdup.compose.yaml +│ ├── dipdup.sqlite.yaml +│ ├── dipdup.swarm.yaml +│ └── replay.yaml +├── deploy +│ ├── .env.default +│ ├── Dockerfile +│ ├── compose.sqlite.yaml +│ ├── compose.swarm.yaml +│ ├── compose.yaml +│ ├── sqlite.env.default +│ └── swarm.env.default +├── graphql +├── handlers +│ └── on_transfer.py +├── hasura +├── hooks +│ ├── on_index_rollback.py +│ ├── on_reindex.py +│ ├── on_restart.py +│ └── on_synchronized.py +├── models +│ └── __init__.py +├── sql +├── types +│ └── eth_usdt/evm_events/transfer.py +└── py.typed +``` + +That's a lot of files and directories! But don't worry, we will need only `models` and `handlers` sections in this guide. + +## Define data models + +DipDup supports storing data in SQLite, PostgreSQL and TimescaleDB databases. We use custom ORM based on Tortoise ORM as an abstraction layer. + +First, you need to define a model class. Our schema will consist of a single model `Holder` with the following fields: + +| | | +| ----------- | ----------------------------------- | +| `address` | account address | +| `balance` | token amount held by the account | +| `turnover` | total amount of transfer/mint calls | +| `tx_count` | number of transfers/mints | +| `last_seen` | time of the last transfer/mint | + +Here's how to implement this model in DipDup: + +```python [models/__init__.py] +{{ #include ../src/demo_evm_events/models/__init__.py }} +``` + +## Implement handlers + +Everything's ready to implement an actual indexer logic. + +Our task is to index all the balance updates. Put some code to the `on_transfer` handler callback to process matched logs: + +```python [handlers/on_transfer.py] +{{ #include ../src/demo_evm_events/handlers/on_transfer.py }} +``` + +And that's all! We can run the indexer now. + +## Next steps + +Run the indexer in-memory: + +```bash +dipdup run +``` + +Store data in SQLite database: + +```bash +dipdup -c . -c configs/dipdup.sqlite.yaml run +``` + +Or spawn a docker-compose stack: + +```bash +cd deploy +cp .env.default .env +# Edit .env before running +docker-compose up +``` + +DipDup will fetch all the historical data and then switch to realtime updates. You can check the progress in the logs. + +If you use SQLite, run a query to check the data: + +```bash +sqlite3 demo_evm_events.sqlite 'SELECT * FROM holder LIMIT 10' +``` + +If you run a Compose stack, check open `http://127.0.0.1:8080` in your browser to see the Hasura console (exposed port may differ). You can use it to explore the database and build GraphQL queries. + +Congratulations! You've just created your first DipDup indexer. Proceed to the Getting Started section to learn more about DipDup configuration and features. diff --git a/docs/0.quickstart.md b/docs/0.quickstart-tezos.md similarity index 96% rename from docs/0.quickstart.md rename to docs/0.quickstart-tezos.md index 94a1e4597..c51cde02d 100644 --- a/docs/0.quickstart.md +++ b/docs/0.quickstart-tezos.md @@ -1,7 +1,8 @@ --- -title: "Quickstart" +title: "Quickstart on Tezos" description: "This page will guide you through the steps to get your first selective indexer up and running in a few minutes without getting too deep into the details." navigation.icon: "stars" +network: "tezos" --- # Quickstart @@ -29,18 +30,18 @@ pipx install dipdup datamodel-code-generator # PDM pdm init --python 3.11 --lib # use "">=3.11,<3.12" for requires-python pdm venv create -pdm add "dipdup>=7.0.0rc3,<8" --venv +pdm add "dipdup>=7.0.0rc4,<8" --venv $(pdm venv activate) # Poetry poetry init --python ">=3.11,<3.12" -poetry add "dipdup>=7.0.0rc3,<8" +poetry add "dipdup>=7.0.0rc4,<8" poetry shell # pip + venv python -m venv .venv . .venv/bin/activate -echo "dipdup>=7.0.0rc3,<8" > requirements.txt +echo "dipdup>=7.0.0rc4,<8" > requirements.txt pip install -r requirements.txt -e . ``` @@ -195,4 +196,4 @@ sqlite3 demo_token.sqlite 'SELECT * FROM holder LIMIT 10' If you run a Compose stack, check open `http://127.0.0.1:8080` in your browser to see the Hasura console (exposed port may differ). You can use it to explore the database and build GraphQL queries. -Congratulations! You've just created your first DipDup indexer. Proceed to the Getting Started section to learn in-depth about DipDup configuration and features. +Congratulations! You've just created your first DipDup indexer. Proceed to the Getting Started section to learn more about DipDup configuration and features. diff --git a/docs/1.getting-started/1.installation.md b/docs/1.getting-started/1.installation.md index 89ba32794..89624eb90 100644 --- a/docs/1.getting-started/1.installation.md +++ b/docs/1.getting-started/1.installation.md @@ -48,7 +48,7 @@ PDM is a very powerful package manager with a lot of features. Also, it can run ```shell [Terminal] pdm init --python 3.11 --lib # use "">=3.11,<3.12" for requires-python pdm venv create -pdm add "dipdup>=7.0.0rc3,<8" --venv +pdm add "dipdup>=7.0.0rc4,<8" --venv $(pdm venv activate) ``` @@ -58,7 +58,7 @@ Poetry is another popular tool to manage Python projects. It doesn't support scr ```shell [Terminal] poetry init --python ">=3.11,<3.12" -poetry add "dipdup>=7.0.0rc3,<8" +poetry add "dipdup>=7.0.0rc4,<8" poetry shell ``` @@ -69,7 +69,7 @@ Finally, if you prefer to do everything manually, you can use pip. It's the most ```shell [Terminal] python -m venv .venv . .venv/bin/activate -echo "dipdup>=7.0.0rc3,<8" >> requirements.txt +echo "dipdup>=7.0.0rc4,<8" >> requirements.txt pip install -r requirements.txt -e . ``` diff --git a/docs/2.indexes/2.tezos_tzkt_big_maps.md b/docs/2.indexes/2.tezos_tzkt_big_maps.md index de9135e41..14d8cfae9 100644 --- a/docs/2.indexes/2.tezos_tzkt_big_maps.md +++ b/docs/2.indexes/2.tezos_tzkt_big_maps.md @@ -13,7 +13,7 @@ Big maps are lazy structures allowing to access and update only exact keys. Gas ```yaml [dipdup.yaml] indexes: token_big_map_index: - kind: tezos.tzkt.big_map + kind: tezos.tzkt.big_maps datasource: tzkt skip_history: never handlers: diff --git a/docs/9.release-notes/1.v7.0.md b/docs/9.release-notes/1.v7.0.md index c0f6dc941..0876af846 100644 --- a/docs/9.release-notes/1.v7.0.md +++ b/docs/9.release-notes/1.v7.0.md @@ -1,15 +1,15 @@ --- -title: 7.0.0rc3 -description: DipDup 7.0.0rc3 release notes +title: 7.0.0rc4 +description: DipDup 7.0.0rc4 release notes --- -# Release Notes: 7.0.0rc3 +# Release Notes: 7.0.0rc4 ::banner{type="warning"} -7.0rc3 is a release candidate; this guide may change before the final release. +This page describes a release candidate and may change before the final release. :: -Welcome, developers! Today we introduce the next major release DipDup 7.0. After half a year of active development, the amount of new features is huge, but we hope that updated docs and lots of examples won't let you get lost. +Welcome, developers! Today we introduce 7.0, the most significant major release for DipDup in terms of both changes and developer hours. The new framework architecture allows to easily integrate new blockchains and data sources. EVM support is the first step in this direction; more to come soon. Also we have focused on improving developer experience, so you can initialize, extend and maintain DipDup projects with minimal effort. Finally, updated docs and new demo projects won't let you get lost. Key highlights: @@ -25,19 +25,19 @@ Join our socials to discuss this release and ask any questions! ## EVM support -Now DipDup supports EVM-compatible blockchains in addition to Tezos. The new index allows you to process contract events from Ethereum, Binance Smart Chain, Polygon, and other EVM-compatible networks. DipDup fetches historical data from [Subsquid Archives](https://www.subsquid.io/), real-time data from RPC nodes, and ABIs from [Etherscan](https://etherscan.io/). All you need is to define an index in your config and implement handlers for each event. +Now DipDup supports EVM-compatible blockchains in addition to Tezos. The new index allows you to process contract events from Ethereum and other EVM-compatible networks. DipDup uses historical data from [Subsquid Archives](https://www.subsquid.io/), real-time data from RPC nodes, and ABIs from [Etherscan](https://etherscan.io/). All you need is to define an index in your config and implement handlers for each event. -We have two demo projects for EVM: a very basic USDt price indexer and a more complex one for Uniswap V3. Run the `dipdup new` command, select "EVM" on the first step, and choose a template to use. +We have two demo projects for EVM: a very basic USDt price indexer and a more complex one for Uniswap V3 protocol. Run the `dipdup new` command, choose "EVM" on the first page, then a template to use. ## Project package -The project package structure was significantly updated and is now easier to extend. All sections are created on init and pre-filled with stubs. Also, it's flat now, meaning that the package is also a project root directory. +The project package structure was updated become more consistent and easier to extend. Every package now have a fixed structure with directories for code, configs, SQL, etc. It allows discovery of package contents and increases the overall readability. The DipDup package now includes three new sections: - `models` section replaces `models.py` module as a source of DipDup ORM models. You can use any structure inside; models will be discovered automatically. -- `configs` directory contains env-specific configs to combine with the root config. Use them to define different settings for different environments and make your config more readable and declarative. -- `deploy` directory contains Dockerfile, Compose stacks and other deployment recipes. Also, there are `.env.default` files for each config in the `configs` directory. So you'll never miss a variable again! +- `configs` directory contains files to extend the root config with environment-specific settings like database connection or logging. Keep these settings separated from the root config to make it more readable and declarative. +- `deploy` directory contains Dockerfiles, Compose stack definitions and other deployment recipes. Also, there are `.env.default` files for each config in the `configs` directory. Use them as a template to never miss or commit an environment variable again. The new `dipdup package tree` command allows inspecting the package structure and ensuring that everything is in place. @@ -45,9 +45,9 @@ See the [Package](../1.getting-started/4.package.md) page in the docs. ## DipDup ORM -We continue to improve our storage layer based on Tortoise ORM, which we refer to as DipDup ORM. Currently, it's not a separate library, but a huge patchset. 7.0 release brings improved query performance, better schema uniformity between database engines, and new field types. +We continue to improve our storage layer based on Tortoise ORM. Currently, it's a patchset, not a separate library, but we refer to it as DipDup ORM. 7.0 release brings improved query performance, better schema uniformity between database engines, and new field types. -Since the 7.0 release project models must be defined like this (note the changed imports): +DipDup models must use classes from `dipdup.fields` and `dipdup.models`. Here's a shortened typical definition: ```python from dipdup import fields @@ -81,21 +81,21 @@ dipdup -c . -c configs/dipdup.sqlite.yaml config export Installer commands were moved to the `dipdup self` command group. There you can switch the release channel or uninstall DipDup at any time: ```shell -dipdup self install --version 7.0.0rc3 +dipdup self install --version 7.0.0rc4 dipdup self update dipdup self install --force --ref next dipdup self uninstall ``` -Starting 7.0 we use [PDM](https://pdm.fming.dev/) as a default package manager. It's a swiss-knife to deal with Python's packaging pain with great PEP compatibility and a lot of features. Also, it can run scripts from pyproject.toml as npm does. Scaffolded scripts were updated from Poetry + GNU Make combo to PDM metadata. +Starting 7.0 we use [PDM](https://pdm.fming.dev/) as a default package manager. It's a swiss-knife to deal with Python's packaging pain with great PEP compatibility and a lot of features. Also, it can run scripts from pyproject.toml as npm does. We have updated the default template to use PDM instead of Poetry and GNU Make and included some scripts. See the [Installation](../1.getting-started/1.installation.md) page in the docs. ## Environment and performance -DipDup projects now run on Python 3.11. This release introduces significant performance improvements, and that thing is crucial for indexers. Also make sure to have fun with the latest syntax like structural pattern matching. +DipDup projects now run on Python 3.11. Performance improvements introduced in this release are crucial for indexers. Also, you can have fun with the latest syntax like pattern matching and union types. -We have improved pre-fetching and caching data during indexing to increase the indexing speed. Our ORM was updated to for better query performance and schema uniformity between database engine (details below). +We have improved pre-fetching and caching data during indexing to increase the indexing speed. Docker images are now based on Debian 12. They are simple, secure and easy to extend - just run pip as a default user. Alpine images are no longer published, but migration should be seamless. @@ -105,38 +105,47 @@ See the [Docker](../6.deployment/2.docker.md) page in the docs. Here are some other notable changes not covered above: -- `dipdup_meta` internal table was added to the schema. You can store arbitrary JSON there and use it in your code. Survives reindexing. See the [Internal tables](../1.getting-started/6.internal-tables.md) page. -- Multiple feature flags were added for experimental and rarely used features. See the [Feature flags](../5.advanced/2.feature-flags.md) page. -- Saved crash- and performance reports in the home directory can be viewed with new `report` and `report show` commands. Also, the `crash_reporting` flag (disabled by default) was removed from the config. If you want to report an issue and share the report, just drop us a message on GitHub or Discord. -- You can customize logging with both short and long syntaxes. See the [Logging](../6.deployment/5.logging.md) page. -- YAML files in templates and examples use `.yaml` extension instead of `.yml` as recommended by the YAML spec, but you can use both. +- `dipdup_meta` internal table was added to the schema. You can store arbitrary JSON there and use it in your code, but don't touch records with `dipdup_` prefix. Survives reindexing. See the [Internal tables](../1.getting-started/6.internal-tables.md) page. +- Multiple feature flags were added for experimental and rarely used features. `metadata_interface` and `crash_reporting` flags (both disabled by default) were removed from the config. See the [Feature flags](../5.advanced/2.feature-flags.md) page. +- Saved crash- and performance reports in the home directory can be viewed with new `report ls` and `report show` commands. If you want to report an issue and share the report, just drop us a message on GitHub or Discord. +- You can use long syntax to configure logging, a mapping of logger name and loglevel. See the [Logging](../6.deployment/5.logging.md) page. +- YAML files in templates and examples use `.yaml` extension instead of `.yml` as recommended by the YAML spec, but you can use any. - `report` command has been renamed to `report ls` for consistency with other command groups. -## Migration from 6.5 +## Future of DipDup 6.5 -Perform the following steps to migrate your project to 7.0: +The previous version of the framework is powering dozens of APIs in production. We want to give those projects enough time for migration or to just wait a bit while the current branch is being ironed out. Given that, _DipDup 6.5 will be supported until Mar 2024_. We will continue to release bugfixes and security updates until that date. You can find the old documentation [here](https://docs.dipdup.io/), but some pages may be outdated. If you've found such page or other issue, please drop us a message. -1. Update your environment to Python 3.11. Install DipDup 7.0.0rc3 using our installer or manually. -2. Run `dipdup new` command, choose empty template `demo_blank`. -3. Move your old config to the new project. Update it using the guide below. -4. Run `dipdup init` command. It will generate a new package structure. Commit the changes. -5. Move your code from existing hooks and handlers to the freshly generated stubs. Keep an eye on imports and model attributes. -6. Move SQL scripts, GraphQL queries and other metadata. -7. Run `pdm all` to run linters and formatters. See pyproject.toml for scripts. +Of course, we encourage you migrating to 7.0 soon to explore all the cool stuff in this release. + +## Migration guide + +Migration from 6.5 requires several manual actions described further. First, make sure that your project is running the latest release, currently 6.5.10. Then, perform the steps below. + +1. Install Python 3.11 with pyenv or your favorite tool. Make sure that `python3.11` is available in your shell. Install DipDup 7.0 with our script or manually. +2. Run the `dipdup new` command. Choose `[none]` at the first page, then `demo_blank` template (also used as package name in examples below). Answer the rest of the questions as you like. +3. Move your old root config to the `demo_blank/dipdup.yaml` path. Update its contents according to the [Config changes](#config-changes) section below. +4. Enter the package directory and run the `dipdup init` command. It will generate a bunch of typeclasses and callback stubs following the structure of the old package. Now is a good time to commit your changes. +5. Move function bodies of every callback in `hooks` and `handlers` directories to the corresponding stubs. If necessary, update type annotations to match with autogenerated imports. +6. Move model definitions from the `models.py` module to the freshly created `models/__init__.py` file preserving imports. +7. Move SQL scripts, GraphQL queries and Hasura metadata to the new package. +8. Ensure that everything is in place running the `dipdup package tree` command. Then, run `pdm all` script or commands from `pyproject.toml` to check that everything is working as expected. + +If you have any questions or issues with migration, please open a ticket on GitHub or reach us on Discord. ### Config changes -1. Set `spec_version` to `2.0`. -2. Add `kind: tezos` or `kind: evm` to contract definitions. -3. Update `kind` field of index and datasource configs according to the table below. -4. Remove `advanced.crash_reporting` and `advanced.metadata_interface` feature flags from your config if presented. - -| | 6.5 | 7.0 | -| ------------------- | ---------------- | ---------------------------- | -| datasources' `kind` | `tzkt` | `tezos.tzkt` | -| | `metadata` | `tzip_metadata` | -| indexes' `kind` | `operation` | `tezos.tzkt.operations` | -| | `big_map` | `tezos.tzkt.big_maps` | -| | `event` | `tezos.tzkt.events` | -| | `token_transfer` | `tezos.tzkt.token_transfers` | -| | `metadata` | `tzip_metadata` | +1. Update the `spec_version` field from `1.2` to `2.0`. +2. Update `kind` fields of contract, datasource and index definitions using the table below. + +| | 6.5 | 7.0 | +| ----------------- | ---------------------- | ---------------------------------- | +| contract `kind` | — | `tezos` | +| datasource `kind` | `tzkt` | `tezos.tzkt` | +| | `metadata` | `tzip_metadata` | +| index `kind` | `operation` | `tezos.tzkt.operations` | +| | `operation_unfiltered` | `tezos.tzkt.operations_unfiltered` | +| | `big_map` | `tezos.tzkt.big_maps` | +| | `event` | `tezos.tzkt.events` | +| | `head` | `tezos.tzkt.head` | +| | `token_transfer` | `tezos.tzkt.token_transfers` | diff --git a/pyproject.toml b/pyproject.toml index 5e361c28f..57f3127fb 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,7 +1,7 @@ [project] name = "dipdup" description = "Modular framework for creating selective indexers and featureful backends for dapps" -version = "7.0.0rc3" +version = "7.0.0rc4" license = { text = "MIT" } authors = [ { name = "Lev Gorodetskii", email = "dipdup@drsr.io" }, diff --git a/src/demo_auction/configs/replay.yaml b/src/demo_auction/configs/replay.yaml index a2ecb20e6..bd09ff10f 100644 --- a/src/demo_auction/configs/replay.yaml +++ b/src/demo_auction/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_auction/deploy/compose.swarm.yaml b/src/demo_auction/deploy/compose.swarm.yaml index 5630517bc..a8c61b8c6 100644 --- a/src/demo_auction/deploy/compose.swarm.yaml +++ b/src/demo_auction/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_auction/deploy/compose.yaml b/src/demo_auction/deploy/compose.yaml index 14d075c4a..60f66dd07 100644 --- a/src/demo_auction/deploy/compose.yaml +++ b/src/demo_auction/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_auction/pyproject.toml b/src/demo_auction/pyproject.toml index 849151dd9..7b618febd 100644 --- a/src/demo_auction/pyproject.toml +++ b/src/demo_auction/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_big_maps/configs/replay.yaml b/src/demo_big_maps/configs/replay.yaml index b2a54f226..5d910116e 100644 --- a/src/demo_big_maps/configs/replay.yaml +++ b/src/demo_big_maps/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_big_maps/deploy/compose.swarm.yaml b/src/demo_big_maps/deploy/compose.swarm.yaml index c407bb7b2..5592a980a 100644 --- a/src/demo_big_maps/deploy/compose.swarm.yaml +++ b/src/demo_big_maps/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_big_maps/deploy/compose.yaml b/src/demo_big_maps/deploy/compose.yaml index e717eae1e..21f13215f 100644 --- a/src/demo_big_maps/deploy/compose.yaml +++ b/src/demo_big_maps/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_big_maps/pyproject.toml b/src/demo_big_maps/pyproject.toml index 257a9a272..13a105f06 100644 --- a/src/demo_big_maps/pyproject.toml +++ b/src/demo_big_maps/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_blank/configs/replay.yaml b/src/demo_blank/configs/replay.yaml index bac83a567..d3dc63aaf 100644 --- a/src/demo_blank/configs/replay.yaml +++ b/src/demo_blank/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_blank/deploy/compose.swarm.yaml b/src/demo_blank/deploy/compose.swarm.yaml index fff814d5a..185d2558a 100644 --- a/src/demo_blank/deploy/compose.swarm.yaml +++ b/src/demo_blank/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_blank/deploy/compose.yaml b/src/demo_blank/deploy/compose.yaml index 0d8c99194..4ee2d75e6 100644 --- a/src/demo_blank/deploy/compose.yaml +++ b/src/demo_blank/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_blank/pyproject.toml b/src/demo_blank/pyproject.toml index 61ec52238..68c80e256 100644 --- a/src/demo_blank/pyproject.toml +++ b/src/demo_blank/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_dao/configs/replay.yaml b/src/demo_dao/configs/replay.yaml index c2d10ff38..561e5f560 100644 --- a/src/demo_dao/configs/replay.yaml +++ b/src/demo_dao/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_dao/deploy/compose.swarm.yaml b/src/demo_dao/deploy/compose.swarm.yaml index 64ac34e23..41f3a5d86 100644 --- a/src/demo_dao/deploy/compose.swarm.yaml +++ b/src/demo_dao/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_dao/deploy/compose.yaml b/src/demo_dao/deploy/compose.yaml index 0c1eab4c4..fd15f4863 100644 --- a/src/demo_dao/deploy/compose.yaml +++ b/src/demo_dao/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_dao/pyproject.toml b/src/demo_dao/pyproject.toml index 23e4c071e..9dde68c04 100644 --- a/src/demo_dao/pyproject.toml +++ b/src/demo_dao/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_dex/configs/replay.yaml b/src/demo_dex/configs/replay.yaml index 8fe4786d0..365cc8a47 100644 --- a/src/demo_dex/configs/replay.yaml +++ b/src/demo_dex/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_dex/deploy/compose.swarm.yaml b/src/demo_dex/deploy/compose.swarm.yaml index afbd2a94d..e9e2f4fb4 100644 --- a/src/demo_dex/deploy/compose.swarm.yaml +++ b/src/demo_dex/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_dex/deploy/compose.yaml b/src/demo_dex/deploy/compose.yaml index ae8f7001d..51df0dc58 100644 --- a/src/demo_dex/deploy/compose.yaml +++ b/src/demo_dex/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_dex/pyproject.toml b/src/demo_dex/pyproject.toml index 2526ae381..702b523fa 100644 --- a/src/demo_dex/pyproject.toml +++ b/src/demo_dex/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_domains/configs/replay.yaml b/src/demo_domains/configs/replay.yaml index 3f72c8fc7..24e7411a6 100644 --- a/src/demo_domains/configs/replay.yaml +++ b/src/demo_domains/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_domains/deploy/compose.swarm.yaml b/src/demo_domains/deploy/compose.swarm.yaml index 1b99cecb0..66c908ac3 100644 --- a/src/demo_domains/deploy/compose.swarm.yaml +++ b/src/demo_domains/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_domains/deploy/compose.yaml b/src/demo_domains/deploy/compose.yaml index 71d48ecbd..07a1e46d6 100644 --- a/src/demo_domains/deploy/compose.yaml +++ b/src/demo_domains/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_domains/pyproject.toml b/src/demo_domains/pyproject.toml index 6a699c43e..087a008a7 100644 --- a/src/demo_domains/pyproject.toml +++ b/src/demo_domains/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_events/configs/replay.yaml b/src/demo_events/configs/replay.yaml index 26568e5ff..8d04da8a0 100644 --- a/src/demo_events/configs/replay.yaml +++ b/src/demo_events/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_events/deploy/compose.swarm.yaml b/src/demo_events/deploy/compose.swarm.yaml index 7b2ca4147..67afccdde 100644 --- a/src/demo_events/deploy/compose.swarm.yaml +++ b/src/demo_events/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_events/deploy/compose.yaml b/src/demo_events/deploy/compose.yaml index 6d7038cf1..6e4963faa 100644 --- a/src/demo_events/deploy/compose.yaml +++ b/src/demo_events/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_events/pyproject.toml b/src/demo_events/pyproject.toml index 58b2e1844..ba28cea7f 100644 --- a/src/demo_events/pyproject.toml +++ b/src/demo_events/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_evm_events/configs/replay.yaml b/src/demo_evm_events/configs/replay.yaml index b304e0a21..6f60876a6 100644 --- a/src/demo_evm_events/configs/replay.yaml +++ b/src/demo_evm_events/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_evm_events/deploy/compose.swarm.yaml b/src/demo_evm_events/deploy/compose.swarm.yaml index 3007bec9c..1b328df5e 100644 --- a/src/demo_evm_events/deploy/compose.swarm.yaml +++ b/src/demo_evm_events/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_evm_events/deploy/compose.yaml b/src/demo_evm_events/deploy/compose.yaml index 51eab31ac..24ac46b28 100644 --- a/src/demo_evm_events/deploy/compose.yaml +++ b/src/demo_evm_events/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_evm_events/pyproject.toml b/src/demo_evm_events/pyproject.toml index 0ab16435d..43e0dc86b 100644 --- a/src/demo_evm_events/pyproject.toml +++ b/src/demo_evm_events/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_factories/configs/replay.yaml b/src/demo_factories/configs/replay.yaml index 6dbd0fd96..90d7049ec 100644 --- a/src/demo_factories/configs/replay.yaml +++ b/src/demo_factories/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_factories/deploy/compose.swarm.yaml b/src/demo_factories/deploy/compose.swarm.yaml index 69fec5627..e7396c58a 100644 --- a/src/demo_factories/deploy/compose.swarm.yaml +++ b/src/demo_factories/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_factories/deploy/compose.yaml b/src/demo_factories/deploy/compose.yaml index 35b6a218a..c7d319f76 100644 --- a/src/demo_factories/deploy/compose.yaml +++ b/src/demo_factories/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_factories/pyproject.toml b/src/demo_factories/pyproject.toml index b86bc5dca..f794074a0 100644 --- a/src/demo_factories/pyproject.toml +++ b/src/demo_factories/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_head/configs/replay.yaml b/src/demo_head/configs/replay.yaml index 2942acab9..2ae1e3d2f 100644 --- a/src/demo_head/configs/replay.yaml +++ b/src/demo_head/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_head/deploy/compose.swarm.yaml b/src/demo_head/deploy/compose.swarm.yaml index c0095f69d..d18367722 100644 --- a/src/demo_head/deploy/compose.swarm.yaml +++ b/src/demo_head/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_head/deploy/compose.yaml b/src/demo_head/deploy/compose.yaml index 429b7cc45..71b3a2c95 100644 --- a/src/demo_head/deploy/compose.yaml +++ b/src/demo_head/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_head/pyproject.toml b/src/demo_head/pyproject.toml index 091ba9d7d..213d62713 100644 --- a/src/demo_head/pyproject.toml +++ b/src/demo_head/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_nft_marketplace/configs/replay.yaml b/src/demo_nft_marketplace/configs/replay.yaml index 05bfab6a3..87028d24c 100644 --- a/src/demo_nft_marketplace/configs/replay.yaml +++ b/src/demo_nft_marketplace/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_nft_marketplace/deploy/compose.swarm.yaml b/src/demo_nft_marketplace/deploy/compose.swarm.yaml index 4b97bd02d..74d867993 100644 --- a/src/demo_nft_marketplace/deploy/compose.swarm.yaml +++ b/src/demo_nft_marketplace/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_nft_marketplace/deploy/compose.yaml b/src/demo_nft_marketplace/deploy/compose.yaml index b45c85493..5417cce78 100644 --- a/src/demo_nft_marketplace/deploy/compose.yaml +++ b/src/demo_nft_marketplace/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_nft_marketplace/pyproject.toml b/src/demo_nft_marketplace/pyproject.toml index c729e9ace..6bf6c1414 100644 --- a/src/demo_nft_marketplace/pyproject.toml +++ b/src/demo_nft_marketplace/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_raw/configs/replay.yaml b/src/demo_raw/configs/replay.yaml index 441f3959c..dcbcdc803 100644 --- a/src/demo_raw/configs/replay.yaml +++ b/src/demo_raw/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_raw/deploy/compose.swarm.yaml b/src/demo_raw/deploy/compose.swarm.yaml index 04860bef0..3a55325db 100644 --- a/src/demo_raw/deploy/compose.swarm.yaml +++ b/src/demo_raw/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_raw/deploy/compose.yaml b/src/demo_raw/deploy/compose.yaml index 0216a7b5c..eacd44689 100644 --- a/src/demo_raw/deploy/compose.yaml +++ b/src/demo_raw/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_raw/pyproject.toml b/src/demo_raw/pyproject.toml index 156084b94..3dcf5df20 100644 --- a/src/demo_raw/pyproject.toml +++ b/src/demo_raw/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_token/configs/replay.yaml b/src/demo_token/configs/replay.yaml index e407efa0d..6c0db40b0 100644 --- a/src/demo_token/configs/replay.yaml +++ b/src/demo_token/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_token/deploy/compose.swarm.yaml b/src/demo_token/deploy/compose.swarm.yaml index 5b7338a84..0facaae16 100644 --- a/src/demo_token/deploy/compose.swarm.yaml +++ b/src/demo_token/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_token/deploy/compose.yaml b/src/demo_token/deploy/compose.yaml index c9b448cc7..b33821db3 100644 --- a/src/demo_token/deploy/compose.yaml +++ b/src/demo_token/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_token/pyproject.toml b/src/demo_token/pyproject.toml index e72add966..fcb90a65a 100644 --- a/src/demo_token/pyproject.toml +++ b/src/demo_token/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_token_transfers/configs/replay.yaml b/src/demo_token_transfers/configs/replay.yaml index 012af30da..be3e5b4f0 100644 --- a/src/demo_token_transfers/configs/replay.yaml +++ b/src/demo_token_transfers/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_token_transfers/deploy/compose.swarm.yaml b/src/demo_token_transfers/deploy/compose.swarm.yaml index 7a81f760d..6db3cd095 100644 --- a/src/demo_token_transfers/deploy/compose.swarm.yaml +++ b/src/demo_token_transfers/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_token_transfers/deploy/compose.yaml b/src/demo_token_transfers/deploy/compose.yaml index 2a4b16997..f0767ba5d 100644 --- a/src/demo_token_transfers/deploy/compose.yaml +++ b/src/demo_token_transfers/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_token_transfers/pyproject.toml b/src/demo_token_transfers/pyproject.toml index c396321ba..29468f948 100644 --- a/src/demo_token_transfers/pyproject.toml +++ b/src/demo_token_transfers/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/demo_uniswap/abi/erc20/ERC20.json b/src/demo_uniswap/abi/erc20/ERC20.json new file mode 100644 index 000000000..405d6b364 --- /dev/null +++ b/src/demo_uniswap/abi/erc20/ERC20.json @@ -0,0 +1,222 @@ +[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_spender", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "balance", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + }, + { + "name": "_spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + } +] diff --git a/src/demo_uniswap/abi/erc20/ERC20NameBytes.json b/src/demo_uniswap/abi/erc20/ERC20NameBytes.json new file mode 100644 index 000000000..2d3c877a8 --- /dev/null +++ b/src/demo_uniswap/abi/erc20/ERC20NameBytes.json @@ -0,0 +1,17 @@ +[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/src/demo_uniswap/abi/erc20/ERC20SymbolBytes.json b/src/demo_uniswap/abi/erc20/ERC20SymbolBytes.json new file mode 100644 index 000000000..a76d61636 --- /dev/null +++ b/src/demo_uniswap/abi/erc20/ERC20SymbolBytes.json @@ -0,0 +1,17 @@ +[ + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/src/demo_uniswap/configs/replay.yaml b/src/demo_uniswap/configs/replay.yaml index fd2a9bb4b..f84d5e8b5 100644 --- a/src/demo_uniswap/configs/replay.yaml +++ b/src/demo_uniswap/configs/replay.yaml @@ -10,5 +10,5 @@ replay: name: John Doe email: john_doe@example.com postgresql_image: postgres:15 - hasura_image: hasura/graphql-engine:v2.30.1 + hasura_image: hasura/graphql-engine:latest line_length: 120 diff --git a/src/demo_uniswap/deploy/compose.swarm.yaml b/src/demo_uniswap/deploy/compose.swarm.yaml index f9bd16c97..0af0c4193 100644 --- a/src/demo_uniswap/deploy/compose.swarm.yaml +++ b/src/demo_uniswap/deploy/compose.swarm.yaml @@ -50,7 +50,7 @@ services: logging: *logging hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest depends_on: - db environment: diff --git a/src/demo_uniswap/deploy/compose.yaml b/src/demo_uniswap/deploy/compose.yaml index 8c65e517d..10388745d 100644 --- a/src/demo_uniswap/deploy/compose.yaml +++ b/src/demo_uniswap/deploy/compose.yaml @@ -34,7 +34,7 @@ services: retries: 5 hasura: - image: hasura/graphql-engine:v2.30.1 + image: hasura/graphql-engine:latest ports: - 8080 depends_on: diff --git a/src/demo_uniswap/pyproject.toml b/src/demo_uniswap/pyproject.toml index 0536fbb9f..027263b12 100644 --- a/src/demo_uniswap/pyproject.toml +++ b/src/demo_uniswap/pyproject.toml @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>=7.0.0rc3,<8" + "dipdup>=7.0.0rc4,<8" ] [tool.pdm.dev-dependencies] diff --git a/src/dipdup/cli.py b/src/dipdup/cli.py index 00f1604e4..2dbf36620 100644 --- a/src/dipdup/cli.py +++ b/src/dipdup/cli.py @@ -634,7 +634,7 @@ async def new( await ctx.invoke(init, base=True, force=force) green_echo('Project created successfully!') - green_echo(f'Enter `{package.name}` directory and see README.md for the next steps.') + green_echo(f"Enter `{answers['package']}` directory and see README.md for the next steps.") @cli.group() diff --git a/src/dipdup/config/evm_subsquid_events.py b/src/dipdup/config/evm_subsquid_events.py index 96adc8564..e7c2de459 100644 --- a/src/dipdup/config/evm_subsquid_events.py +++ b/src/dipdup/config/evm_subsquid_events.py @@ -75,6 +75,8 @@ def get_subscriptions(self) -> set[Subscription]: for handler in self.handlers: if address := handler.contract.address: subs.add(EvmNodeLogsSubscription(address=address)) + elif abi := handler.contract.abi: + subs.add(EvmNodeLogsSubscription(topics=((abi,),))) else: raise NotImplementedError return subs diff --git a/src/dipdup/install.py b/src/dipdup/install.py index 56ee0eb46..a607b5e6d 100755 --- a/src/dipdup/install.py +++ b/src/dipdup/install.py @@ -164,7 +164,7 @@ def install( if not any((version, ref, path)): # FIXME: Temporary, remove when 7.0.0 is released - version = '7.0.0rc3' + version = '7.0.0rc4' env = DipDupEnvironment() env.prepare() diff --git a/src/dipdup/package.py b/src/dipdup/package.py index 0cd62b8c3..f991d8766 100644 --- a/src/dipdup/package.py +++ b/src/dipdup/package.py @@ -41,9 +41,9 @@ def _get_pointers(content_length: int) -> tuple[str, ...]: def draw_package_tree(root: Path, project_tree: dict[str, tuple[Path, ...]]) -> tuple[str, ...]: lines: deque[str] = deque() pointers = _get_pointers(len(project_tree) - 1) - for pointer, (section, paths) in zip(pointers, project_tree.items(), strict=True): + for pointer, (section, paths) in zip(pointers, project_tree.items(), strict=False): lines.append(pointer + section) - for inner_pointer, path in zip(_get_pointers(len(paths)), sorted(paths), strict=True): + for inner_pointer, path in zip(_get_pointers(len(paths)), sorted(paths), strict=False): relative_path = path.relative_to(root / section) lines.append(_branch + inner_pointer + relative_path.as_posix()) diff --git a/src/dipdup/project.py b/src/dipdup/project.py index 3b386fcca..a31f53adc 100644 --- a/src/dipdup/project.py +++ b/src/dipdup/project.py @@ -78,7 +78,7 @@ def get_default_answers() -> Answers: email='john_doe@example.com', postgresql_image='postgres:15', # TODO: fetch latest from GH - hasura_image='hasura/graphql-engine:v2.30.1', + hasura_image='hasura/graphql-engine:latest', line_length='120', ) diff --git a/src/dipdup/projects/base/pyproject.toml.j2 b/src/dipdup/projects/base/pyproject.toml.j2 index fd532a133..aa382ea5a 100644 --- a/src/dipdup/projects/base/pyproject.toml.j2 +++ b/src/dipdup/projects/base/pyproject.toml.j2 @@ -9,7 +9,7 @@ authors = [ readme = "README.md" requires-python = ">=3.11,<3.12" dependencies = [ - "dipdup>={{ project.dipdup_version }}.0.0rc3,<{{ project.dipdup_version | int + 1 }}" + "dipdup>={{ project.dipdup_version }}.0.0rc4,<{{ project.dipdup_version | int + 1 }}" ] [tool.pdm.dev-dependencies] diff --git a/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20.json.j2 b/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20.json.j2 new file mode 100644 index 000000000..405d6b364 --- /dev/null +++ b/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20.json.j2 @@ -0,0 +1,222 @@ +[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_spender", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_from", + "type": "address" + }, + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "decimals", + "outputs": [ + { + "name": "", + "type": "uint8" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "name": "balance", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "name": "", + "type": "string" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "constant": false, + "inputs": [ + { + "name": "_to", + "type": "address" + }, + { + "name": "_value", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "name": "", + "type": "bool" + } + ], + "payable": false, + "stateMutability": "nonpayable", + "type": "function" + }, + { + "constant": true, + "inputs": [ + { + "name": "_owner", + "type": "address" + }, + { + "name": "_spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "name": "", + "type": "uint256" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + }, + { + "payable": true, + "stateMutability": "payable", + "type": "fallback" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "name": "from", + "type": "address" + }, + { + "indexed": true, + "name": "to", + "type": "address" + }, + { + "indexed": false, + "name": "value", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + } +] diff --git a/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20NameBytes.json.j2 b/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20NameBytes.json.j2 new file mode 100644 index 000000000..2d3c877a8 --- /dev/null +++ b/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20NameBytes.json.j2 @@ -0,0 +1,17 @@ +[ + { + "constant": true, + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +] diff --git a/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20SymbolBytes.json.j2 b/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20SymbolBytes.json.j2 new file mode 100644 index 000000000..a76d61636 --- /dev/null +++ b/src/dipdup/projects/demo_uniswap/abi/erc20/ERC20SymbolBytes.json.j2 @@ -0,0 +1,17 @@ +[ + { + "constant": true, + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "payable": false, + "stateMutability": "view", + "type": "function" + } +]