Hi everyone! I can see the table block_document ge...
# prefect-ui
g
Hi everyone! I can see the table block_document getting bigger (almost 700 MB) and we have only 300 blocks and the table has 766722 records. I went deeper and I can see many block named
anonymous-<UUID>
. Why these blocks are created? Can I safely delete them? Data looks in base64, but if I try to decode I’m not able to see the content, I see strange chars
n
hi @Giacomo Chiarella - what version of prefect are you on? we've tried to reduce the number of these that are created, but you still might be hitting a case where you're implicitly creating many because of how you're using prefect for example if you use python scripts to create deployments where you dynamically create result storage blocks instead of referring to existing result storage blocks
g
Hi @Nate, I’m using Prefect 3.2.7. When I deploy a flow I do the following:
Copy code
flow.from_source(S3Bucket.load(storage), path) \
    .deploy(name=deployment_name, work_pool_name=work_pool_name, work_queue_name=work_queue_name, tags=tags,
            schedule=CronSchedule(cron=schedule, timezone="UTC") if schedule else None, parameters=parameters)
where flow is a function with @flow (from prefect import flow) decorator and storage is the block name containing bucket name, bucket path and credentials. Is it this creating all those anonymous blocks? Should I just this way
Copy code
flow.from_source(storage, path) \
    .deploy(name=deployment_name, work_pool_name=work_pool_name, work_queue_name=work_queue_name, tags=tags,
            schedule=CronSchedule(cron=schedule, timezone="UTC") if schedule else None, parameters=parameters)
to avoid anonymous blocks?
n
hmm that shouldn’t, i can look into this later
🙏 1
g
Thank you Nate! Please let me know if you find anything and if you need any further info from my side!
@Nate any luck?
n
hi @Giacomo Chiarella if you’re still seeing extra anon blocks it is would be helpful if you could create an issue for tracking, that’s the best way to make sure we take a look at something. sometimes i lose track of threads