Skip to content

Treat bundle paths that are not valid URLs as local paths - #7851

Merged
ilyakuz-db merged 2 commits into
mainfrom
ilyakuz-db/notebook-path-with-colon
Nov 20, 2026
Merged

ilyakuz-db merged 2 commits into
mainfrom
ilyakuz-db/notebook-path-with-colon

Conversation

@ilyakuz-db

@ilyakuz-db ilyakuz-db commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

Changes

NormalizePaths and TranslatePaths call url.Parse only to skip paths that have a scheme, such as dbfs:/.... A path that does not parse as a URL is now treated as a local path instead of failing the command.

Why

New workspace notebooks get default names like New Notebook 2026-10-28 12:17:43.ipynb. When a job task refers to one by its bare name, every bundle command, including bundle config-remote-sync, fails with:

Error: parse "New Notebook 2026-10-28 12:17:43.ipynb": first path segment in URL cannot contain colon

Go's url.Parse rejects a relative reference whose first segment contains a colon. Such a path has no scheme, so it is local; isRemoteStorageScheme in bundle/libraries already treats a parse error the same way. ./New Notebook ... and src/New Notebook ... were never affected.

Names whose colon follows a scheme-like word, such as Notes:2026.ipynb, still parse as a URL with a scheme and are left as they are. That was already the case; telling them apart from Windows drive paths like C:\dir needs its own change.

Tests

New acceptance test bundle/paths/notebook_name_with_colon validates a bundle whose notebook task points at a bare name with colons; it fails without the fix. The script creates the notebook because Windows does not allow colons in file names, so the test is skipped there. go test ./bundle/..., the bundle/paths, config-remote-sync, validate, libraries and artifacts acceptance tests, lint-q and fmt-q pass locally.

Status Check Revision Comments
⚠️ Local review eebdc0d Codex: one P1 deferred (names like Notes:2026.ipynb, pre-existing, see Why); auto review: approve, its Codex reviewer produced no result
✅ Design review eebdc0d RIGHT-SIZED: turns the parse error into "no scheme" at the only two call sites
⚠️ E2E validation eebdc0d not run on a workspace; acceptance tests run locally
➖ Isaac review d122a47 (latest) n/a on CLI PRs
✅ Code owners review d122a47 (latest) approved by andrewnester
✅ CI / merge conflicts d122a47 (latest) 19 pass, 9 skipping; no conflicts

✅ success · ⏳ pending · ⚠️ warning · ❌ failed · ➖ n/a

This pull request and its description were written by Isaac.

@ilyakuz-db
ilyakuz-db requested review from a team as code owners November 20, 2026 17:22
@github-actions github-actions Bot added the DABs DABs related issues label Nov 20, 2026
@ilyakuz-db ilyakuz-db self-assigned this Nov 20, 2026
@ilyakuz-db ilyakuz-db added ai-auto Deprecated: use factory-generated instead. software-factory Deprecated. Use factory-generated instead. labels Nov 20, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Commit: d122a479b | Workflow run

Regression test report

Selected 1 changed tests (limit=20, 0 not selected)

2 tests: regression=2 unreleased=0 coverage=0 failing=0
test branch main (03bedcb) latest (v1.27.0)
TestAccept/bundle/paths/notebook_name_with_colon/DMS= ✅ ❌ ❌
TestAccept/bundle/paths/notebook_name_with_colon/DMS=true ✅ ❌ ❌
TestAccept/bundle/paths/notebook_name_with_colon/DMS=: branch ✅ | main (03bedcb) ❌ | latest (v1.27.0) ❌

main (03bedcb):

acceptance_test.go:1402: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1402
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1143
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:704
        	Error:      	Not equal: 
        	            	expected: "\n>>> [CLI] bundle validate -o json\n\"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43\"\n"
        	            	actual  : "\n>>> [CLI] bundle validate -o json\nError: failed to normalize paths: parse \"New Notebook 12:17:43.ipynb\": first path segment in URL cannot contain colon\n\n\"New Notebook 12:17:43.ipynb\"\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -2,3 +2,7 @@
        	            	 >>> [CLI] bundle validate -o json
        	            	-"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43"
        	            	+Error: failed to normalize paths: parse "New Notebook 12:17:43.ipynb": first path segment in URL cannot contain colon
        	            	 
        	            	+"New Notebook 12:17:43.ipynb"
        	            	+
        	            	+Exit code: 1
        	            	+
        	Test:       	TestAccept/bundle/paths/notebook_name_with_colon/DMS=
        	Messages:   	bundle/paths/notebook_name_with_colon/output.txt vs /tmp/TestAcceptbundlepathsnotebook_name_with_colonDMS=3536238022/002/output.txt
    acceptance_test.go:1192: Test produced unexpected files:
        New Notebook 12:17:43.ipynb
FAIL

latest (v1.27.0):

acceptance_test.go:1402: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1402
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1143
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:704
        	Error:      	Not equal: 
        	            	expected: "\n>>> [CLI] bundle validate -o json\n\"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43\"\n"
        	            	actual  : "\n>>> [CLI] bundle validate -o json\nError: failed to normalize paths: parse \"New Notebook 12:17:43.ipynb\": first path segment in URL cannot contain colon\n\n\"New Notebook 12:17:43.ipynb\"\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -2,3 +2,7 @@
        	            	 >>> [CLI] bundle validate -o json
        	            	-"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43"
        	            	+Error: failed to normalize paths: parse "New Notebook 12:17:43.ipynb": first path segment in URL cannot contain colon
        	            	 
        	            	+"New Notebook 12:17:43.ipynb"
        	            	+
        	            	+Exit code: 1
        	            	+
        	Test:       	TestAccept/bundle/paths/notebook_name_with_colon/DMS=
        	Messages:   	bundle/paths/notebook_name_with_colon/output.txt vs /tmp/TestAcceptbundlepathsnotebook_name_with_colonDMS=1305636409/002/output.txt
    acceptance_test.go:1192: Test produced unexpected files:
        New Notebook 12:17:43.ipynb
TestAccept/bundle/paths/notebook_name_with_colon/DMS=true: branch ✅ | main (03bedcb) ❌ | latest (v1.27.0) ❌

main (03bedcb):

acceptance_test.go:1402: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1402
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1143
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:704
        	Error:      	Not equal: 
        	            	expected: "\n>>> [CLI] bundle validate -o json\n\"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43\"\n"
        	            	actual  : "\n>>> [CLI] bundle validate -o json\nError: failed to normalize paths: parse \"New Notebook 12:17:43.ipynb\": first path segment in URL cannot contain colon\n\n\"New Notebook 12:17:43.ipynb\"\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -2,3 +2,7 @@
        	            	 >>> [CLI] bundle validate -o json
        	            	-"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43"
        	            	+Error: failed to normalize paths: parse "New Notebook 12:17:43.ipynb": first path segment in URL cannot contain colon
        	            	 
        	            	+"New Notebook 12:17:43.ipynb"
        	            	+
        	            	+Exit code: 1
        	            	+
        	Test:       	TestAccept/bundle/paths/notebook_name_with_colon/DMS=true
        	Messages:   	bundle/paths/notebook_name_with_colon/output.txt vs /tmp/TestAcceptbundlepathsnotebook_name_with_colonDMS=true2012160600/002/output.txt
    acceptance_test.go:1192: Test produced unexpected files:
        New Notebook 12:17:43.ipynb

latest (v1.27.0):

acceptance_test.go:1402: 
        	Error Trace:	/home/runner/work/cli/cli/libs/testdiff/testdiff.go:22
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1402
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:1143
        	            				/home/runner/work/cli/cli/acceptance/acceptance_test.go:704
        	Error:      	Not equal: 
        	            	expected: "\n>>> [CLI] bundle validate -o json\n\"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43\"\n"
        	            	actual  : "\n>>> [CLI] bundle validate -o json\nError: failed to normalize paths: parse \"New Notebook 12:17:43.ipynb\": first path segment in URL cannot contain colon\n\n\"New Notebook 12:17:43.ipynb\"\n\nExit code: 1\n"
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -2,3 +2,7 @@
        	            	 >>> [CLI] bundle validate -o json
        	            	-"/Workspace/Users/[USERNAME]/.bundle/notebook_name_with_colon/default/files/New Notebook 12:17:43"
        	            	+Error: failed to normalize paths: parse "New Notebook 12:17:43.ipynb": first path segment in URL cannot contain colon
        	            	 
        	            	+"New Notebook 12:17:43.ipynb"
        	            	+
        	            	+Exit code: 1
        	            	+
        	Test:       	TestAccept/bundle/paths/notebook_name_with_colon/DMS=true
        	Messages:   	bundle/paths/notebook_name_with_colon/output.txt vs /tmp/TestAcceptbundlepathsnotebook_name_with_colonDMS=true3470088848/002/output.txt
    acceptance_test.go:1192: Test produced unexpected files:
        New Notebook 12:17:43.ipynb
FAIL

@denik denik added factory-generated and removed software-factory Deprecated. Use factory-generated instead. ai-auto Deprecated: use factory-generated instead. labels Nov 20, 2026
@denik

denik commented Nov 20, 2026

Copy link
Copy Markdown
Contributor

The ai-auto and software-factory labels are deprecated in this repo; use factory-generated instead. I relabeled this PR. If an agent opened it, please update that agent's prompt or config to apply factory-generated instead of the deprecated labels.

AI agent (opus5.5, isaac_claude)

@eng-dev-ecosystem-bot

Copy link
Copy Markdown
Collaborator

✅ Integration test report

Commit: d122a47

Run: 44783066747

Env ✅​pass 🙈​skip Time
✅​ aws linux-2core-8gb 273 20 5:56
✅​ aws-windows-latest-4core-16gb 275 18 4:28
✅​ azure linux-2core-8gb 272 20 5:51
✅​ azure-windows-latest-4core-16gb 274 18 4:13
✅​ gcp linux-2core-8gb 273 20 7:51
✅​ gcp-windows-latest-4core-16gb 275 18 4:45
Top 5 slowest tests (at least 2 minutes):
duration env testname
4:12 azure-windows-latest-4core-16gb TestAccept
3:20 aws-windows-latest-4core-16gb TestAccept
3:11 gcp-windows-latest-4core-16gb TestAccept
2:02 aws linux-2core-8gb TestFilerWorkspaceFilesExtensionsReadDir
2:01 azure linux-2core-8gb TestAccept

@ilyakuz-db
ilyakuz-db added this pull request to the merge queue Nov 20, 2026
Merged via the queue into main with commit f0a5bec Nov 20, 2026
28 checks passed
@ilyakuz-db
ilyakuz-db deleted the ilyakuz-db/notebook-path-with-colon branch November 20, 2026 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

DABs DABs related issues factory-generated

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants