Repository navigation
Fix cross-project deploy and add --remove-unmapped to project deploy - #1588
Open
midigofrank wants to merge 1 commit into
Open
midigofrank wants to merge 1 commit into
midigofrank wants to merge 1 commit into
Conversation
josephjclark
force-pushed
the
release/next
branch
from
October 15, 2026 15:30
4597116 to
5b42eff
Compare
Deploying a workspace to a different project now treats every local workflow as a merge candidate, instead of only those changed since the workspace's own last sync. --remove-unmapped sends delete entries for target workflows that don't exist locally.
josephjclark
force-pushed
the
ofn-4761-cross-project-deploy
branch
from
October 16, 2026 14:27
c41f26d to
54032a0
Compare
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.
Short Description
Deploying a workspace to a different project sent none of its workflows. Cross-project deploys now send every local workflow, and a new
--remove-unmappedflag deletes target workflows that don't exist locally.Fixes OFN-4761, OFN-4762
Implementation Details
findLocallyChangedWorkflows, which compares the workspace with its ownforked_from. An unchanged workspace of A had no candidates, so deploying it to B sent B's workflows back unchanged (only a channel diff got past "Nothing to deploy"). This broke Lightning's GitHub -> OpenFn setup: green run, nothing deployed.skipLocallyChangedCheckpath: every local workflow is a candidate.--remove-unmapped(off by default): target workflows whose id isn't in the local project are sent asdelete: true, and count as a change. Done in deploy rather than viaProject.merge'sremoveUnmapped, which only omits workflows (Lightning rejects that) and would delete unchanged workflows underonlyUpdated.--forceis still required in that case.@openfn/projectnow exportsWorkflow.QA Notes
--remove-unmappedB ends with only A's; same-project--remove-unmappeddeletes a remote-only workflow; cross-project divergence message and--force. All fail before the fix.--remove-unmappedon a same-project deploy also deletes workflows created in Lightning since the last sync, without a divergence warning. That's what the flag means, but worth documenting.--remove-unmappeddeletes (it diffs workspace vs remote, not the payload);--json-diffdoes.deploy.ts.avaruns segfault locally (also on the base commit); every test file passes individually.AI Usage