-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: update indexer in local environment #2268
Conversation
✅ Deploy Preview for regen-website ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
Some simple testing demonstrating that the indexer starts up, uses graphile migrations and is able to index blocks after genesis. I'm still getting up to speed on things and not sure all the ways Before$ docker compose logs indexer
indexer_container | First start, running init script...
indexer_container | + psql -c '\i V1__init.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE TABLE
indexer_container | CREATE TABLE
indexer_container | CREATE TABLE
indexer_container | CREATE TABLE
indexer_container | CREATE INDEX
indexer_container | CREATE TABLE
indexer_container | CREATE TABLE
indexer_container | + psql -c '\i V1_1__fix_msg_attr.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | ALTER TABLE
indexer_container | CREATE EXTENSION
indexer_container | UPDATE 0
indexer_container | ALTER TABLE
indexer_container | ALTER TABLE
indexer_container | + psql -c '\i V1_2__add_retirements_table.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE TABLE
indexer_container | + psql -c '\i V1_3__add_msg_event_attr_type_idx.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE INDEX
indexer_container | + psql -c '\i V1_4__retirements_owner_idx.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE INDEX
indexer_container | + psql -c '\i V1_5__add_proposals_table.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE TABLE
indexer_container | + psql -c '\i V1_6__add_tx_hash.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | ALTER TABLE
indexer_container | + psql -c '\i V1_7__index_group_policy_address.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE INDEX
indexer_container | + psql -c '\i V1_8__index_proposal_id.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE INDEX
indexer_container | + psql -c '\i V1_9__all_ecocredit_txes.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | psql:V1_9__all_ecocredit_txes.sql:1: NOTICE: index "tx_data_tx_response_code_idx" does not exist, skipping
indexer_container | DROP INDEX
indexer_container | CREATE INDEX
indexer_container | CREATE INDEX
indexer_container | psql:V1_9__all_ecocredit_txes.sql:9: NOTICE: function all_ecocredit_txes() does not exist, skipping
indexer_container | DROP FUNCTION
indexer_container | CREATE FUNCTION
indexer_container | + psql -c '\i V1_10__class_issuers.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE TABLE
indexer_container | + psql -c '\i V1_11__class_issuers_indexes.sql' postgres://postgres:password@localhost:5432/indexer
indexer_container | CREATE INDEX
indexer_container | CREATE INDEX
indexer_container | CREATE INDEX
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | [INFO/PollingProcess-1] child process calling self.run()
indexer_container | [INFO/PollingProcess-2] child process calling self.run()
indexer_container | [INFO/PollingProcess-3] child process calling self.run()
indexer_container | [INFO/MainProcess] process shutting down
indexer_container | [INFO/MainProcess] calling join() for process PollingProcess-4
indexer_container | [INFO/PollingProcess-4] child process calling self.run()
indexer_container | 2024-01-23 23:39:26,943 - index_blocks - INFO - indexing regen-local block 1
indexer_container | 2024-01-23 23:39:26,949 - index_blocks - INFO - height=1 len(txs)=0
indexer_container | 2024-01-23 23:39:31,972 - index_blocks - INFO - indexing regen-local block 2
indexer_container | 2024-01-23 23:39:31,974 - index_blocks - INFO - height=2 len(txs)=0
indexer_container | 2024-01-23 23:39:36,999 - index_blocks - INFO - indexing regen-local block 3
indexer_container | 2024-01-23 23:39:37,004 - index_blocks - INFO - height=3 len(txs)=0
indexer_container | 2024-01-23 23:39:42,036 - index_blocks - INFO - indexing regen-local block 4
indexer_container | 2024-01-23 23:39:42,040 - index_blocks - INFO - height=4 len(txs)=0
indexer_container | 2024-01-23 23:39:47,075 - index_blocks - INFO - indexing regen-local block 5
indexer_container | 2024-01-23 23:39:47,081 - index_blocks - INFO - height=5 len(txs)=0
indexer_container | 2024-01-23 23:39:52,115 - index_blocks - INFO - indexing regen-local block 6 After$ docker compose logs indexer
indexer_container | First start, running init script...
indexer_container | yarn run v1.22.19
indexer_container | $ graphile-migrate reset --erase
indexer_container | graphile-migrate: dropped database 'indexer'
indexer_container | graphile-migrate: recreated database 'indexer'
indexer_container | graphile-migrate: Running migration '000001.sql'
indexer_container | graphile-migrate: Running migration '000002.sql'
indexer_container | graphile-migrate: 2 committed migrations executed
indexer_container | Done in 0.97s.
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | INSERT 0 1
indexer_container | [INFO/PollingProcess-1] child process calling self.run()
indexer_container | [INFO/PollingProcess-2] child process calling self.run()
indexer_container | [INFO/PollingProcess-3] child process calling self.run()
indexer_container | [INFO/PollingProcess-4] child process calling self.run()
indexer_container | [INFO/MainProcess] process shutting down
indexer_container | [INFO/MainProcess] calling join() for process PollingProcess-4
indexer_container | [INFO/PollingProcess-5] child process calling self.run()
indexer_container | 2024-01-24 00:25:06,498 - index_blocks - INFO - indexing regen-local block 1
indexer_container | 2024-01-24 00:25:06,500 - index_blocks - INFO - height=1 len(txs)=0
indexer_container | 2024-01-24 00:25:11,512 - index_blocks - INFO - indexing regen-local block 2
indexer_container | 2024-01-24 00:25:11,516 - index_blocks - INFO - height=2 len(txs)=0
indexer_container | 2024-01-24 00:25:16,533 - index_blocks - INFO - indexing regen-local block 3
indexer_container | 2024-01-24 00:25:16,537 - index_blocks - INFO - height=3 len(txs)=0
indexer_container | 2024-01-24 00:25:21,553 - index_blocks - INFO - indexing regen-local block 4
indexer_container | 2024-01-24 00:25:21,557 - index_blocks - INFO - height=4 len(txs)=0
indexer_container | 2024-01-24 00:25:26,573 - index_blocks - INFO - indexing regen-local block 5
indexer_container | 2024-01-24 00:25:26,576 - index_blocks - INFO - height=5 len(txs)=0
indexer_container | 2024-01-24 00:25:31,602 - index_blocks - INFO - indexing regen-local block 6
indexer_container | 2024-01-24 00:25:31,605 - index_blocks - INFO - height=6 len(txs)=0
indexer_container | 2024-01-24 00:25:36,630 - index_blocks - INFO - indexing regen-local block 7
indexer_container | 2024-01-24 00:25:36,631 - index_blocks - INFO - height=7 len(txs)=0 |
@@ -1,11 +1,11 @@ | |||
FROM python:3.9-slim |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we can revert back to python:3.9
. In a previous PR I made a change to use python:3.9-slim
: #2125
Today I ran into the same issue I initially reported. But doing another docker pull python:3.9
seems to have pulled a newer image that has fixed this issue. I believe this issue explains more why this was happening for me: docker-library/python#837
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
utACK, this LGTM at a glance!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tACK
Description
See regen-network/indexer#53
Updates to the latest indexer commit and refactors local docker
indexer
image to use the latestgraphile
migrations.Follows the existing patterns in the
indexer
Dockerindexer.Dockerfile
,indexer_start.sh
andindexer_init.sh
: https://github.com/regen-network/indexer/tree/main/dockerAuthor Checklist
All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.
I have...
How to test
Reviewers Checklist
All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.
I have...