Skip to content

Commit

Permalink
BUG: fixed missing file polling
Browse files Browse the repository at this point in the history
  • Loading branch information
cpelley committed Aug 30, 2024
1 parent 1b07e24 commit 1fbf240
Showing 1 changed file with 9 additions and 11 deletions.
20 changes: 9 additions & 11 deletions dagrunner/plugin_framework.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,17 +203,15 @@ def __call__(

if host:
# bash equivalent to python glob (glob on remote host)
expanded_paths = (
subprocess.run(
f"ssh {host} \"printf '%s\n' {pattern} | grep -v '*'\" || true",
shell=True,
check=True,
text=True,
capture_output=True,
)
.stdout.strip()
.split("\n")
)
expanded_paths = subprocess.run(
f"ssh {host} \"printf '%s\n' {pattern} | grep -v '*'\" || true",
shell=True,
check=True,
text=True,
capture_output=True,
).stdout.strip()
if expanded_paths:
expanded_paths = expanded_paths.split("\n")
else:
expanded_paths = glob(pattern)
if expanded_paths:
Expand Down

0 comments on commit 1fbf240

Please sign in to comment.