Skip to content

fix(cli publish): fix namespace resolution and add Content-Type header #1521

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 28, 2025

Conversation

amirabbas-gh
Copy link
Collaborator

📚 Description

This PR addresses two improvements to the codemod publishing flow:

  • Fix: Corrects the way namespace is received and handled in the publish route. Previously, the namespace could be incorrectly extracted or missing, causing publishing issues.
  • Feat: Adds a Content-Type: application/json header for publish requests made from the CLI. This ensures better consistency with API expectations and improves reliability when handling request payloads.

These changes improve the stability and correctness of the publishing mechanism for codemods.

🧪 Test Plan

  • Verified publishing a codemod from the CLI with the updated header and confirmed a successful publish.
  • Tested scenarios with and without explicit namespace values to ensure correct behavior.

@amirabbas-gh amirabbas-gh added bug Something isn't working cli backend labels Apr 28, 2025
Copy link

vercel bot commented Apr 28, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
codemod ⬜️ Ignored (Inspect) Visit Preview Apr 28, 2025 3:18pm

Copy link

pkg-pr-new bot commented Apr 28, 2025

Open in StackBlitz

npm i https://pkg.pr.new/codemod@1521

commit: d80538c

@codemod-com-bot codemod-com-bot merged commit 0467787 into main Apr 28, 2025
12 checks passed
@codemod-com-bot codemod-com-bot deleted the fix/fix-publish-namespace branch April 28, 2025 15:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend bug Something isn't working cli
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants