https://prefect.io logo
Title
f

frojo

08/05/2022, 2:33 PM
Hi Everyone! I am starting some migration to prefect 2.0 and I'm facing some issues with blocks registering. Working on: - prefect 2.0.2 Steps: ## Server side - prefect orion start --host HOST --port PORT - prefect config set PREFECT_API_URL=http:HOST:PORT - prefect config set PREFECT_ORION_UI_API_URL=http:HOST:PORT (this taken from another thread here, otherwise the UI was showing blank pages for every option) ## User side - prefect config set PREFECT_API_URL=http:HOST:PORT At this point all semmed OK. If I try to register (from the user side) a block for using the CLI - prefect block register --file blocks/docker-block.py The messages are: - RuntimeWarning: coroutine 'Block.save' was never awaited - Successfully registered 1 block And the UI does not reflect the block. (docker-block.py)
from prefect.infrastructure.docker import DockerContainer, ImagePullPolicy

docker_block = DockerContainer(image="some-image",
image_pull_policy=ImagePullPolicy.ALWAYS,env=dict(PREFECT_LOGGING_LEVEL="DEBUG"))
docker_block.save("docker-image")
However if I add the block from the UI the change is reflected and shown. Any advice?
βž• 1
m

Mike Kovetsky

08/05/2022, 3:20 PM
The same for me!
j

Josh Furlin

08/05/2022, 3:33 PM
Thank you for bringing this to our attention! We've found the cause of this issue, and are currently working on a fix. It should be working again soon!
πŸ‘ 1
❀️ 1
f

frojo

08/05/2022, 3:44 PM
Thank you @Josh Furlin for the comment. I'll wait for the fix. In the mean time, any workaround for a docker pull issue? We have some gitlab registry for docker images: β€’ my-registryπŸ˜›ORT/image-name:tag-image when i try to run a flow in that image , its OK if the image is already downloaded, however if i try to run on a remote server (so an image pulling is required) an error is returned: β€’ docker.errors.APIError: 400 Client Error for http+docker (other things) Bad Request ("invalid tag format") After checking it seems related to the double semicolon scheme.
j

Josh Furlin

08/05/2022, 5:15 PM
This issue is known, and will be fixed in the next version, which should be our within the next few days.
πŸ‘ 1
f

frojo

08/08/2022, 1:40 PM
Hi @Josh Furlin! I am testing prefect 2.0.3 and the block registering issue seems to be solved! thanks!
j

Josh Furlin

08/08/2022, 2:49 PM
No problem!