-
Hi, I'm not sure if this is a bug or that I'm just new to Typescript and not sure how to use it well. I found when updating @octokit/rest Some code I had like this was failing to compile:
Is this something that is an actual bug or is there just some simple way to define the types so that it all works? |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 4 replies
-
I'm not aware of any problems here. I tried the folloiwng and didn't get any error
Using the latest
|
Beta Was this translation helpful? Give feedback.
-
Hi @gr2m , thanks for your reply and trying to repro the issue. I double checked and created this branch with only the update to that package and I'm still seeing the same issue: https://github.com/myyk/git-democracy/compare/update-deps-2 can be seen with
I checked that I'm using the same latest dependencies as you:
Everything seems to compile again if I use I just tried to reduce my project even further to just the code you shared: https://github.com/myyk/git-democracy/pull/new/min-project |
Beta Was this translation helpful? Give feedback.
-
The problem seems to be a conflict between What resolved the problem for me is to update the lock file
After that, the build succeeds. I wonder, why do you have both |
Beta Was this translation helpful? Give feedback.
The problem seems to be a conflict between
@octokit/types@5.5.0
and@octokit/types@5.4.1
, both versions are present in the dependency tree, see https://github.com/octokit/rest.js/discussions/#discussioncomment-79071What resolved the problem for me is to update the lock file
After that, the build succeeds.
I wonder, why do you have both
@actions/github
and@octokit/rest
in your dependencies? It should not be necessary. If you didn't, the problem would not have occurred.