Skip to content

fix(cli): stop uipath push from deleting the remote project.uiproj - #1980

Open
vldcmp-uipath wants to merge 3 commits into
mainfrom
fix/push-preserve-project-uiproj
Open

vldcmp-uipath wants to merge 3 commits into
mainfrom
fix/push-preserve-project-uiproj

Conversation

@vldcmp-uipath

@vldcmp-uipath vldcmp-uipath commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator

Details

uipath push deleted project.uiproj from the Studio Web project on every run. Studio Web creates that file with every project and its packagers read it, so each push left the project without it.

Cause. The upload set comes from files_to_include, which picks files by extension or an explicit include list. .uiproj is in neither, so project.uiproj is never uploaded. The deletion pass then saw a remote file with no local match and removed it.

Fix. project.uiproj is now on the deletion ignore list in SwFileHandler, next to studio_metadata.json. Genuinely orphaned remote files are still deleted.

🤖 Generated with Claude Code

https://claude.ai/code/session_014t9fy5hvBnH5DbBSbfoMBR

Studio Web creates project.uiproj with every project. `uipath push` never
includes it in the local upload set (the .uiproj extension is not a packed
extension), so the deletion pass treated the remote copy as an orphan and
removed it on every push. Add it to the deletion ignore list next to
studio_metadata.json and cover the behaviour with a regression test.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014t9fy5hvBnH5DbBSbfoMBR
Copilot AI balanced review requested due to automatic review settings November 6, 2026 16:09
@github-actions github-actions Bot added test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-integrations labels Nov 6, 2026
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014t9fy5hvBnH5DbBSbfoMBR

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The negative test uses a Function fixture that validation explicitly accepts without package.json, so the expected rejection never occurs and the test fails; keep the fixture as Agent.

1 open issue
What changed in this PR

This PR protects Studio Web’s project.uiproj during uipath push, while preserving deletion of genuinely orphaned remote files.

Changes:

  • Adds project.uiproj to the deletion ignore list without changing upload or packaging behavior.
  • Adds a regression test verifying that push preserves the project file while deleting a stale remote file.
  • Changes the mocked project type in an existing validation test.
File Description
packages/​uipath/​tests/​cli/​test_push.py Adds preservation coverage and modifies an existing validation fixture.
packages/​uipath/​src/​uipath/​_cli/​_push/​sw_file_handler.py Excludes project.uiproj from remote-file deletion.

Review effort: Balanced

Comment thread packages/uipath/tests/cli/test_push.py Resolved
…ject

A search-and-replace meant for the new project.uiproj test also rewrote
this test's project type to Function, which ensure_coded_project accepts,
so the negative test no longer exercised rejection.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014t9fy5hvBnH5DbBSbfoMBR
@sonarqubecloud

sonarqubecloud Bot commented Nov 6, 2026

Copy link
Copy Markdown

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test:uipath-integrations test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-runtime

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants