analyseether/ether_sql

AttributeError: 'Session' object has no attribute 'block_filter'

Opened this issue · 6 comments

Describe the bug
AttributeError: 'Session' object has no attribute 'block_filter'

To Reproduce
run ether_sql --settings='PersonalInfuraSettings' celery start -c2 -B -Q celery_filters -n worker1@%h, we get the error, but, it still push blocks in queque:

[2018-09-10 12:41:17,224][PID:8589][ERROR][ForkPoolWorker-3] Task ether_sql.tasks.filters.new_blocks[fb253629-be89-4c58-aee5-0c6ece03d65d] raised unexpected: AttributeError("'Session' object has no attribute 'block_filter'",)
Traceback (most recent call last):
  File "/home/ubuntu/ether_sql/envname/lib/python3.6/site-packages/celery/app/trace.py", line 375, in trace_task
    R = retval = fun(*args, **kwargs)
  File "/home/ubuntu/ether_sql/envname/lib/python3.6/site-packages/celery/app/trace.py", line 632, in __protected_call__
    return self.run(*args, **kwargs)
  File "/home/ubuntu/ether_sql/ether_sql/tasks/filters.py", line 22, in new_blocks
    block_hashes = current_session.block_filter.get_new_entries()
AttributeError: 'Session' object has no attribute 'block_filter'
AttributeError: 'Session' object has no attribute 'block_filter'
[2018-09-10 12:41:51,134][PID:8588][INFO][ForkPoolWorker-2] Task ether_sql.tasks.filters.push_blocks_in_queue[7c3b666a-6363-4a50-9a66-64978708e897] succeeded in 33.95213927699933s: None
[2018-09-10 12:41:17,224][PID:8589][ERROR][ForkPoolWorker-3] Task ether_sql.tasks.filters.new_blocks[fb253629-be89-4c58-aee5-0c6ece03d65d] raised unexpected: AttributeError("'Session' object has no attribute 'block_filter'",)

it's there any problem if missing attribute block_filter?

Desktop (please complete the following information):

  • OS: ubuntu 16.04
  • Node Infura

it keep pushing blocks in queue,:
image

but, when i run ether_sql --settings='PersonalInfuraSettings' celery start -c1 -n worker3@%h, to push data into database it stay as in next image and nothing happens, but it still keep push blocks in queue

image

it might be cause of my memory? if i add many workers, system cannot allocate memory, it just has 500 mb ram.. it might be also why i get killed when i try to push blocks into database with geth/infura?

Adding new blocks using an Infura node is not enabled yet with the library:
#54, it is in the pipeline.

The image says that the function push_blocks_in_queue ran but not necessarily the blocks have been pushed in the database (this command is not yet enabled with infura).

Can you try this with a parity node?

trying to sync parity light node, but there are no peers, around 200k blocks left
2018-09-10 22:30:10 UTC Syncing #6117108 0xa7a6…8562 0 hdr/s 0+ 0 Qed #6117108 1/50 peers 664 bytes cache 0 bytes queue RPC: 0 conn, 0 req/s, 0 µs

some crazy stuff here or i'm blind/dumb/tired :)))

running ether_sql --settings='PersonalParitySettings' scrape_block_range --start_block_number 6308685 --no-fill_gaps

(envname) [23:14 ubuntu@ip-172-26-15-152 ether_sql] > ether_sql --settings='PersonalParitySettings' scrape_block_range --start_block_number 6308685 --no-fill_gaps
Usage: ether_sql [OPTIONS] COMMAND [ARGS]...

Error: Invalid value for "--settings": invalid choice: PersonalParitySettings. (choose from DefaultSettings, ParityTestSettings, PerrsonalParitySettings, PersonalGethSettings, PersonalInfuraSettings, TestSettings)

idk from where comes that dot after PersonalParitySettings lol

@dirmansebastian were you able to resolve the mast bug?
I retried and everything works fine ...

no luck, same problem :)))