Repository navigation
fix: syft-bg services run only the job they should - #9612
Open
koenvanderveen wants to merge 1 commit into
Open
koenvanderveen wants to merge 1 commit into
koenvanderveen wants to merge 1 commit into
Conversation
The approve service runs only api calls; jobs approved by hand wait for the data owner. An email approval runs and shares only the job replied to. Adds run_job to SyftJobRunner and SyftRDSClient to run a single approved job.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two syft-bg services shared a job's output before the data owner could check it (Asana).
Changes
SyftJobRunner.run_job(job_name, ds_email, ...)runs one approved job; raises if it isn't approved.process_approved_jobsloops over the same code.SyftRDSClient.run_job(job, ..., sync=False)checks the submitter's version first (raises on a mismatch) and syncs only withsync=True.approval_method == "api") and syncs once after. Jobs approved by hand wait for the data owner. A version mismatch skips that call, not the rest.Not in this PR
Whether an email approval should hold the output for review instead of sharing it (the ticket's open question).
Test plan
run_job, approve service skipping hand-approved jobs, email service callingrun_job.just test-unit-fast(751 passed), syft-rds / syft-job / syft-bg suites (501 passed), pre-commit clean.