Alex
02/06/2023, 9:42 AMfrom __prefect_loader__ import CustomBlockName
But I get an error: ModuleNotFoundError: No module named '__prefect_loader__'
How can I fix it?Jason Noxon
02/15/2023, 1:06 PMEric Sexton
02/20/2023, 10:18 PMEmil Christensen
02/21/2023, 2:16 PM__prefect_loader__
is just a placeholder there. The CustomBlockName
needs to be imported and available wherever you’re using it (i.e. in your flow code). You can also set PREFECT_EXTRA_ENTRYPOINTS
(doc) to force loading the block.Jason Noxon
02/21/2023, 2:23 PMimport MyCustomBlock
having the python file for that custom block handy. Prefect will store the parameters for the block, but not the block code.
SO - suggestion: as a default, this info should probably be on the block screen when a custom block is created...maybe?