Skip to content

fix(cli): leave adapter directory untouched on intrinsic upload - #1857

Merged
planetf1 merged 1 commit into
generative-computing:mainfrom
Seyamalam:fix/1812-intrinsic-upload-leaves-source-unmodified
Nov 23, 2026
Merged

planetf1 merged 1 commit into
generative-computing:mainfrom
Seyamalam:fix/1812-intrinsic-upload-leaves-source-unmodified

Conversation

@Seyamalam

@Seyamalam Seyamalam commented Nov 19, 2026 •

Copy link
Copy Markdown
Contributor

Pull Request

Thanks for sending a pull request! Please make sure you read the contributing guidelines.

Issue

Fixes #1812

Description

m alora upload --intrinsic staged its upload by editing the user's adapter directory in place: it copied io.yaml into the weight directory and deleted its README.md before running copytree into the staging directory. The upload succeeded silently, so a hand-written model card was destroyed with no warning.

Staging now leaves the source untouched: copytree ignores README.md when populating the staging directory and io.yaml is copied into the staged copy — the same layout as before, without mutating the source.

Testing

  • Tests added to the respective file if code was changed
  • New code has 100% coverage if code was added
  • Ensure existing tests and github automation passes (a maintainer will kick off the github automation when the rest of the PR is populated)

Attribution

  • AI coding assistants used

Adding a new component, requirement, sampling strategy, or tool?

If your PR adds or modifies one of the types below, check the matching box. A checklist of type-specific review items will be posted as a comment.

  • Component
  • Requirement
  • Sampling Strategy
  • Tool

NOTE: Please ensure you have an issue that has been acknowledged by a core contributor and routed you to open a pull request against this repository. Otherwise, please open an issue before continuing with this pull request.

`m alora upload --intrinsic` staged by editing the source directory in
place: io.yaml was copied into it and its README.md was deleted before
copying to the staging directory. A user-written model card was
silently destroyed by the upload.

Stage without modifying the source instead: copytree the weight
directory while ignoring README.md, then copy io.yaml into the staged
copy.

Fixes generative-computing#1812

Assisted-by: Devin
Signed-off-by: Seyamalam <[email protected]>
@Seyamalam
Seyamalam requested a review from a team as a code owner November 19, 2026 22:01
@github-actions github-actions Bot added the bug Something isn't working label Nov 19, 2026

@spzala spzala 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.

Thanks @Seyamalam
I have verified the output (that README was not removed as desired) with the fix and it lgtm but will wait for review from @planetf1

@planetf1

planetf1 commented Nov 23, 2026 •

Copy link
Copy Markdown
Contributor

@Seyamalam thanks, and one thing we should have caught earlier. #1814 fixes the same issue and was opened a week before this; I reviewed yours without noticing the overlap. Our error.

The two fixes are equivalent, so I'd like to merge this one for the code change: your base is current main and spzala has already verified the output. #1814 has a few extra tests (contents, a local io.yaml overridden in staging only, the no-README.md case), and I'm asking its author to rebase so that arrives as a small tests-only PR.

@planetf1 planetf1 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.

Thanks @Seyamalam. Staging now leaves the source directory untouched, and the new test checks both the staged contents and that the original README.md survives. CI is green on this head.

@planetf1
planetf1 added this pull request to the merge queue Nov 23, 2026
Merged via the queue into generative-computing:main with commit 7cb4fa1 Nov 23, 2026
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: m alora upload --intrinsic modifies the local adapter directory

3 participants