I’ve run into an issue with switching my backend d...
# prefect-community
I’ve run into an issue with switching my backend database from the default sqlite instance to a postgres instance. Most of the blocks (in particular for my use case the Azure block) are no longer available in the UI and they don’t show up in the postgres db. Do I need to register them specifically now that I’m using a different db?
I assume you are using Prefect Orion? Yes I believe so since your block instances are saved in the backend database
gotcha. Any idea how to specifically get the Azure block back? I am struggling to find the specific module i need
and yes, using orion!
I believe they should auto register when you switch to a different database. I just switched from SQLite to Postgres and saw the same thing. I had to clear out all my cached data by running
rm -rf ~/.prefect
After that, they appeared.
oh interesting--I’ll give that a shot, thanks Ryan!
@alex this appears to be an interesting side-effect of your memoization?
@Ryan Peden that did indeed work. Definitely not intuitive though!
Thanks for following up! As Michael mentioned, it looks like this happened as the result of a recent update, so we'll likely make another update soon (or at least update the docs) to ensure it's as easy as possible to switch databases.
👍 1
❤️ 1
Thanks for reporting this issue! I think that @Zanie is correct and this is related to a change that was made to mitigate the performance hit from block auto-registration. I’ve created an issue in GitHub for this and hope to have a fix in this release or the one after.
👍 3