Skip to content

fix(jobs): allow null folder_key on Job model#1637

Merged
radu-mocanu merged 1 commit into
mainfrom
fix/job-folder-key-optional
May 18, 2026
Merged

fix(jobs): allow null folder_key on Job model#1637
radu-mocanu merged 1 commit into
mainfrom
fix/job-folder-key-optional

Conversation

@radu-mocanu
Copy link
Copy Markdown
Collaborator

@radu-mocanu radu-mocanu commented May 18, 2026

Summary

  • mark Job.folder_key as Optional[str] so sdk.jobs.list() no longer raises a pydantic ValidationError when orchestrator returns FolderKey: null

Why

orchestrator's odata /Jobs endpoint declares FolderKey as nullable

Copilot AI review requested due to automatic review settings May 18, 2026 13:39
@github-actions github-actions Bot added test:uipath-langchain Triggers tests in the uipath-langchain-python repository test:uipath-integrations labels May 18, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR aligns the Orchestrator Job model with the server contract by allowing FolderKey to be null, preventing sdk.jobs.list() from failing with a Pydantic ValidationError on cross-folder job listings.

Changes:

  • Make Job.folder_key nullable (Optional[str]) with a None default to match Orchestrator’s nullable: true schema behavior.
  • Bump uipath-platform version to 0.1.51.
  • Update uv.lock files to reflect the version bump.

Reviewed changes

Copilot reviewed 2 out of 4 changed files in this pull request and generated 1 comment.

File Description
packages/uipath/uv.lock Updates locked uipath-platform version to 0.1.51.
packages/uipath-platform/uv.lock Updates locked uipath-platform version to 0.1.51.
packages/uipath-platform/src/uipath/platform/orchestrator/job.py Allows FolderKey to be null by making folder_key optional.
packages/uipath-platform/pyproject.toml Bumps package version to 0.1.51.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 79 to 83
has_errors: Optional[bool] = Field(default=None, alias="HasErrors")
has_warnings: Optional[bool] = Field(default=None, alias="HasWarnings")
job_error: Optional[JobErrorInfo] = Field(default=None, alias="JobError")
folder_key: str = Field(alias="FolderKey")
folder_key: Optional[str] = Field(default=None, alias="FolderKey")
id: int = Field(alias="Id")
@sonarqubecloud
Copy link
Copy Markdown

@radu-mocanu radu-mocanu merged commit 2c3b923 into main May 18, 2026
91 checks passed
@radu-mocanu radu-mocanu deleted the fix/job-folder-key-optional branch May 18, 2026 13:43
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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants