You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
No overload matches this call.
Overload 1 of 2, '(event: "pull_request.opened" | "pull_request.opened"[], callback: HandlerFunction<"pull_request.opened", { octokit: Octokit & { paginate: PaginateInterface; } & paginateGraphQLInterface & Api & { ...; }; }>): void', gave the following error.
Argument of type '({ payload }: HandlePullRequestOpenedOptions) => Promise<void>' is not assignable to parameter of type 'HandlerFunction<"pull_request.opened", { octokit: Octokit & { paginate: PaginateInterface; } & paginateGraphQLInterface & Api & { ...; }; }>'.
Types of parameters '__0' and 'event' are incompatible.
Type 'BaseWebhookEvent<"pull_request"> & { payload: { action: "opened"; }; } & { octokit: Octokit & { paginate: PaginateInterface; } & paginateGraphQLInterface & Api & { ...; }; }' is not assignable to type 'HandlePullRequestOpenedOptions'.
The types of 'payload.pull_request' are incompatible between these types.
Type '{ url: string; id: number; node_id: string; html_url: string; diff_url: string; patch_url: string; issue_url: string; commits_url: string; review_comments_url: string; review_comment_url: string; ... 37 more ...; changed_files: number; } & { ...; }' is not assignable to type 'PullRequest & { state: "open"; closed_at: null; merged_at: null; active_lock_reason: null; merged_by: null; }'.
Type '{ url: string; id: number; node_id: string; html_url: string; diff_url: string; patch_url: string; issue_url: string; commits_url: string; review_comments_url: string; review_comment_url: string; ... 37 more ...; changed_files: number; } & { ...; }' is not assignable to type 'PullRequest'.
The types of 'user.name' are incompatible between these types.
Type 'string | null | undefined' is not assignable to type 'string | undefined'.
Type 'null' is not assignable to type 'string | undefined'.
Overload 2 of 2, '(event: "pull_request.opened" | "pull_request.opened"[], callback: HandlerFunction<"pull_request.opened", { octokit: Octokit; }>): void', gave the following error.
Argument of type '({ payload }: HandlePullRequestOpenedOptions) => Promise<void>' is not assignable to parameter of type 'HandlerFunction<"pull_request.opened", { octokit: Octokit; }>'.
Types of parameters '__0' and 'event' are incompatible.
Type 'BaseWebhookEvent<"pull_request"> & { payload: { action: "opened"; }; } & { octokit: Octokit; }' is not assignable to type 'HandlePullRequestOpenedOptions'.
Types of property 'octokit' are incompatible.
Type 'Octokit' is not assignable to type 'Octokit & { paginate: PaginateInterface; } & paginateGraphQLInterface & Api & { retry: { retryRequest: (error: RequestError, retries: number, retryAfter: number) => RequestError; }; }'.
Property 'paginate' is missing in type 'Octokit' but required in type '{ paginate: PaginateInterface; }'.ts(2769)
octokit.d.ts(5, 5): 'paginate' is declared here.
Code of Conduct
I agree to follow this project's Code of Conduct
The text was updated successfully, but these errors were encountered:
👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labeled with Status: Up for grabs. You & others like you are the reason all of this works! So thank you & happy coding! 🚀
wolfy1339
added
Type: Support
Any questions, information, or general needs around the SDK or GitHub APIs
and removed
Type: Bug
Something isn't working as documented, or is being fixed
Status: Triage
This is being looked at and prioritized
labels
Sep 26, 2024
wolfy1339
changed the title
[BUG]: How to provide typing foe webhook handlers
[SUPPORT]: How to provide typing foe webhook handlers
Sep 26, 2024
What happened?
After upgrading
octokit
tov4.0.2
and@octokit/core
tov6.1.2
, my previous typing no longer works. How should I fix them here?Versions
Octokit v4.0.2
Relevant log output
Code of Conduct
The text was updated successfully, but these errors were encountered: