Skip to content
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

[BUG]: @octokit/types@8.2.0 incompatible with @octokit/plugin-paginate-rest@5.0.1 #498

Closed
1 task done
bcoe opened this issue Jan 20, 2023 · 6 comments · Fixed by #497
Closed
1 task done

[BUG]: @octokit/types@8.2.0 incompatible with @octokit/plugin-paginate-rest@5.0.1 #498

bcoe opened this issue Jan 20, 2023 · 6 comments · Fixed by #497
Labels
Type: Bug Something isn't working as documented
Projects

Comments

@bcoe
Copy link

bcoe commented Jan 20, 2023

What happened?

When upgrading to the latest version of @octokit/types, typescript throws compilation errors.

Versions

@octokit/types@8.2.0 incompatible with @octokit/plugin-paginate-rest@5.0.1

Relevant log output

node_modules/@octokit/plugin-rest-endpoint-methods/dist-types/generated/parameters-and-response-types.d.ts:848:33 - error TS2339: Property 'PUT /organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}' does not exist on type 'Endpoints'.

848             response: Endpoints["PUT /organizations/{org}/codespaces/secrets/{secret_name}/repositories/{repository_id}"]["response"];
                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

node_modules/@octokit/plugin-rest-endpoint-methods/dist-types/generated/parameters-and-response-types.d.ts:859:60 - error TS2339: Property 'PUT /organizations/{org}/codespaces/secrets/{secret_name}' does not exist on type 'Endpoints'.

859             parameters: RequestParameters & Omit<Endpoints["PUT /organizations/{org}/codespaces/secrets/{secret_name}"]["parameters"], "baseUrl" | "headers" | "mediaType">;
                             

Code of Conduct

  • I agree to follow this project's Code of Conduct
@bcoe bcoe added Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented labels Jan 20, 2023
@ghost ghost added this to Bugs in JS Jan 20, 2023
@wolfy1339
Copy link
Member

This is normal, as the packages all depend on each other and need to be kept in sync

A new release of this package needs to be released with the update to @octokit/types

@wolfy1339 wolfy1339 added Priority: Normal Type: Support Any questions, information, or general needs around the SDK or GitHub APIs and removed Status: Triage This is being looked at and prioritized Type: Bug Something isn't working as documented labels Jan 20, 2023
@ghost ghost moved this from Bugs to Support in JS Jan 20, 2023
@benjdlambert
Copy link

benjdlambert commented Jan 20, 2023

@wolfy1339 have you considered using semver for releases to the types? It looks like a lot of things were removed in the latest changes which obviously have impacts downstream for packages even under the @octokit org. New installs of these packages are currently broken and fail tsc when skipLibCheck=false

edit:
It looks like you do follow semver, but the last release that went out removed a lot of things from the public facing API and therefore is a breaking change, and it wasn't released as such.
https://github.com/octokit/types.ts/pull/499/files#diff-6e34f3ccc1fd41b44cec74317606475053c89f3ffe0133356443861f5e7f1150L1413-L1447

@wolfy1339
Copy link
Member

That can be arranged. A major version bump can be done. Sorry for the troubles!

However, even with a feature release, the different packages still need to be kept in sync, as they all cascade off one another

@benjdlambert
Copy link

@wolfy1339 thanks for the reply! Yeah, I think in order to fix it that 8.2.0 release will either need to be unpublished, or 8.2.1 to be released with the previous generated stuff before the PR, and then a followup release of 9.0.0 with the contents of the PR.

However, even with a feature release, the different packages still need to be kept in sync, as they all cascade off one another

Yep totally get that for new features etc!

@wolfy1339
Copy link
Member

I've started submitting PRs to remedy the situation
Starting off with: octokit/types.ts#501

@wolfy1339 wolfy1339 added Priority: High Type: Bug Something isn't working as documented and removed Type: Support Any questions, information, or general needs around the SDK or GitHub APIs Priority: Normal labels Jan 20, 2023
@ghost ghost moved this from Support to Bugs in JS Jan 20, 2023
@bcoe
Copy link
Author

bcoe commented Jan 20, 2023

Thank you @wolfy1339

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Something isn't working as documented
Projects
Archived in project
JS
  
Done
Development

Successfully merging a pull request may close this issue.

3 participants