Skip to content

Commit 37e272d

Browse files
committed
update pr
1 parent 17c7fab commit 37e272d

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

src/prefect/_sdk/fetcher.py

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,16 @@
88
from __future__ import annotations
99

1010
import asyncio
11+
import logging
1112
from dataclasses import dataclass, field
1213
from datetime import datetime, timezone
1314
from typing import TYPE_CHECKING, Any
1415
from uuid import UUID
1516

1617
import prefect
18+
19+
# Logger for SDK fetcher operations
20+
logger = logging.getLogger(__name__)
1721
from prefect._sdk.models import (
1822
DeploymentInfo,
1923
FlowInfo,
@@ -175,9 +179,7 @@ async def _fetch_work_pool(
175179
job_vars_schema: dict[str, Any] = {}
176180
base_job_template = work_pool.base_job_template
177181
if base_job_template and "variables" in base_job_template:
178-
variables = base_job_template["variables"]
179-
if isinstance(variables, dict):
180-
job_vars_schema = variables
182+
job_vars_schema = base_job_template["variables"]
181183

182184
return WorkPoolInfo(
183185
name=work_pool.name,
@@ -215,7 +217,7 @@ async def _fetch_work_pools_parallel(
215217
results = await asyncio.gather(*tasks, return_exceptions=True)
216218

217219
work_pools: dict[str, WorkPoolInfo] = {}
218-
for name, result in zip(pool_names_list, results, strict=True):
220+
for name, result in zip(pool_names_list, results):
219221
if isinstance(result, BaseException):
220222
warnings.append(
221223
f"Could not fetch work pool '{name}' - `with_infra()` will not be "
@@ -316,6 +318,7 @@ async def fetch_sdk_data(
316318
errors: list[str] = []
317319

318320
# Check authentication first
321+
logger.debug("Checking authentication with Prefect API")
319322
await _check_authentication(client)
320323

321324
# Build filters
@@ -391,7 +394,7 @@ async def fetch_sdk_data(
391394

392395
# If filtering by deployment name, check the full name matches
393396
full_name = f"{flow_name}/{dep.name}"
394-
if deployment_names and full_name not in deployment_names:
397+
if deployment_names and dep.name not in deployment_names:
395398
# Only include if the full name matches (filter was by name parts)
396399
# Skip if user specified full names and this doesn't match
397400
found_match = False

0 commit comments

Comments
 (0)