Closed helaili closed 3 years ago
What's your setup? Is your code open source? Do you see any deprecation warnings when you run your app with 10.19.0?
The code is here and yes, I do have some warnings such as this one 👇
Deprecation: [probot] "id" option is deprecated. Use "appId" instead
In terms of setup, it's just a simple probot app that I'm deploying as an AWS lambda with the serverless command line. It's configured with .env.{stage}
files and the environment is properly populated in AWS.
The deprecation warning is why it fails with the new version, this line here is the problem
I'm currently working on creating an example app with deployment to AWS Lambda with Serverless. Once that's done I'll update the adapter. But the current app is not working, I don't know why, I'm not very familiar with Lambda/Serverless, could you have a look?
https://github.com/probot/example-aws-lambda-serverless/pull/1
See also the discussion at https://github.com/probot/probot/pull/1467#issuecomment-766306947
In addition, Probot v11 incompatibilities concerns a custom GitHub URL endpoint (sample: GitHub Enterprise).
Switching a probot app v10 (which is working) into v11, the GitHub Enterprise URL is not taken into account (default GitHub.com is used):
HttpError: request to https://api.github.com/app/installations/42/access_tokens failed, reason: getaddrinfo ENOTFOUND api.github.com api.github.com:443
// Details:
request: {
method: "POST"
url: "https://api.github.com/app/installations/42/access_tokens"
headers: {
"accept": "application/vnd.github.machine-man-preview+json",
"user-agent": "probot/11.0.5 octokit-core.js/3.2.5 Node.js/10.23.1 (linux; x64)",
"authorization": "bearer [REDACTED]",
"content-length": 0
}
The GHE_HOST
sysenv seems not used.
It could perhaps be linked to new Probot constructor usage or new GHE_BASEURL
prop (1415):
But was introduced in 10.17 and downgrade v11 to v10.19.0 is working fine for me 🤔.
I've a pull request which will update this adapter to Probot v11, it also changes its APIs. Could you have a look? https://github.com/probot/adapter-aws-lambda-serverless/pull/59
I'm not very familiar with the serverless framework. If you could check instructions in the README I'd appreciate it
:tada: This issue has been resolved in version 2.0.0 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
Got this error with probot
11.0.1
and11.0.5
. Downgrading to10.19.0
solved it.