I am using prefect 2.6.6 local server:I am using run_deployment() to trigger flow_run from deployment A and B. Second flow should start once the first is finished.
whenever I trigger the flow its failing with below error. Can someone please help me with this.Thanks.
Encountered exception during execution:
Traceback (most recent call last):
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/client/orion.py", line 1351, in read_deployment_by_name
response = await self._client.get(f"/deployments/name/{name}")
File "/home/x/anaconda3/lib/python3.9/site-packages/httpx/_client.py", line 1751, in get
return await self.request(
File "/home/x/anaconda3/lib/python3.9/site-packages/httpx/_client.py", line 1527, in request
return await self.send(request, auth=auth, follow_redirects=follow_redirects)
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/client/base.py", line 182, in send
response.raise_for_status()
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/client/base.py", line 125, in raise_for_status
raise PrefectHTTPStatusError.from_httpx_error(exc) from exc.
cause
prefect.exceptions.PrefectHTTPStatusError: Client error '404 Not Found' for url '
https://api.prefect.cloud/api/accounts/e25149ff-b6ff-4b7b-8d35-15fedaa1a20b/workspaces/fb6e8c45-2229-4aaf-8c98-9c03a6f2ae86/deployments/name/db2_replace'
Response: {'detail': 'Not Found'}
For more information check:
https://httpstatuses.com/404
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/engine.py", line 610, in orchestrate_flow_run
result = await run_sync(flow_call)
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/utilities/asyncutils.py", line 68, in run_sync_in_worker_thread
return await
anyio.to_thread.run_sync(call, cancellable=True)
File "/home/x/anaconda3/lib/python3.9/site-packages/anyio/to_thread.py", line 28, in run_sync
return await get_asynclib().run_sync_in_worker_thread(func, *args, cancellable=cancellable,
File "/home/x/anaconda3/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 818, in run_sync_in_worker_thread
return await future
File "/home/x/anaconda3/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 754, in run
result = context.run(func, *args)
File "/home/x/Desktop/mlp-prefect/mlp_prefect/flows/standard/pipeline/mainflow_db2_etl.py", line 13, in mainflow
db2_load_flow_run = run_deployment(name="db2_replace")
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/utilities/asyncutils.py", line 197, in coroutine_wrapper
return run_async_from_worker_thread(async_fn, *args, **kwargs)
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/utilities/asyncutils.py", line 148, in run_async_from_worker_thread
return anyio.from_thread.run(call)
File "/home/x/anaconda3/lib/python3.9/site-packages/anyio/from_thread.py", line 35, in run
return asynclib.run_async_from_thread(func, *args)
File "/home/x/anaconda3/lib/python3.9/site-packages/anyio/_backends/_asyncio.py", line 847, in run_async_from_thread
return f.result()
File "/home/x/anaconda3/lib/python3.9/concurrent/futures/_base.py", line 446, in result
return self.__get_result()
File "/home/x/anaconda3/lib/python3.9/concurrent/futures/_base.py", line 391, in __get_result
raise self._exception
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/client/utilities.py", line 47, in with_injected_client
return await fn(*args, **kwargs)
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/deployments.py", line 78, in run_deployment
deployment = await client.read_deployment_by_name(name)
File "/home/x/anaconda3/lib/python3.9/site-packages/prefect/client/orion.py", line 1354, in read_deployment_by_name
raise prefect.exceptions.ObjectNotFound(http_exc=e) from e
prefect.exceptions.ObjectNotFound