Repository navigation
fix(config): don't strip workspace-member includes from deploy config - #34788
Merged
Merged
Conversation
`to_deploy_config` ran `exclude_includes_with_member_for_base_for_root`, the member-include strip shared with fmt/lint/test/bench/publish. For deploy that is wrong: deploy resolves a single application's file set from the workspace root, so a root `deploy.include` pointing at a workspace member (e.g. `./packages/backend/**`) is an explicit instruction to ship those files. The strip dropped them, leaving `deno deploy` from a workspace root with an empty upload set. Remove the strip for deploy only and add regression tests.
crowlKats
approved these changes
Jun 25, 2026
piscisaureus
added a commit
to denoland/deploy-cli
that referenced
this pull request
Jul 2, 2026
deno deploy from a workspace root whose deploy.include points at a workspace member collected no member files (#90): deno_config < 0.102 stripped member-targeting includes from the deploy config in to_deploy_config. Fixed upstream in denoland/deno#34788; bump deno_config 0.97.0 -> 0.103.0 (no rs_lib API changes) and add regression tests for glob and explicit-file member includes. The tests fail on 0.97.0 and pass on 0.103.0; no workaround code needed.
piscisaureus
pushed a commit
to denoland/deploy-cli
that referenced
this pull request
Jul 2, 2026
deno deploy from a workspace root whose deploy.include points at a workspace member collected no member files (#90): deno_config < 0.102 stripped member-targeting includes from the deploy config. Fixed upstream in denoland/deno#34788; bump deno_config 0.97.0 -> 0.103.0 (no rs_lib API changes) and add regression tests for glob and explicit-file member includes. The tests fail on 0.97.0 and pass on 0.103.0; no workaround code needed.
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.
When
deno deployis run from a Deno workspace root, a root-leveldeploy.includethat points at a workspace member resolves to an empty include set, so the file collector uploads nothing.Cause
WorkspaceDirectory::to_deploy_configranexclude_includes_with_member_for_base_for_root— the member-include strip it shares withto_fmt_config/to_lint_config/to_test_config/to_bench_config/to_publish_config. That strip removes, from the root config, anyincludewhose base path falls inside a workspace member, on the assumption that the member contributes its own files.That assumption is correct for fmt/lint/test/bench/publish (which recurse into members and apply each member's own config), but wrong for deploy: deploy resolves a single application's file set from the workspace root and never recurses into per-member deploy configs. A root
deploy.includesuch as./packages/backend/**is an explicit instruction to ship those member files. Stripping it leavesdeno deploywith nothing to upload.Fix
Don't call the strip in
to_deploy_config. This only affects the deploy-from-root-with-include case:dir_url != root_dir), so removing it is a no-op there.include, so the strip was already a no-op for them — they keep passing.The function is still used by the other five config kinds, so there's no dead code.
Tests
Adds
test_deploy_config_root_include_targeting_member_globandtest_deploy_config_root_include_targeting_member_filecovering the previously-uncovered case (glob and explicit-file includes targeting a member).Reported against the
@deno/deployCLI (denoland/deploy-cli#90), which depends on this crate to resolvedeploy.include.