-
Notifications
You must be signed in to change notification settings - Fork 394
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
Would the argument for getThreadContext and saveThreadContext be unnecessary? #2319
Comments
Hello! I tried reproducing this issue and was unable to. Can you provide a sample that reproduces the issue? If it's a typescript issue, a sample project that reproduces this issue would be helpful that includes e.g. a |
@filmaj What I’d like to confirm is that there is a discrepancy between the implementation and the type definitions, causing an error on the caller’s side. typescript version is ^5.5.4 and my tsconfig.json is here. {
"compilerOptions": {
"target": "es2016",
"module": "commonjs",
"rootDir": "./src",
"outDir": "./dist",
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"strict": true,
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true,
"noUncheckedIndexedAccess": true,
"skipLibCheck": true
},
"include": [
"src/**/*"
],
"exclude": [
"node_modules",
"**/*.spec.ts"
]
} |
Thanks! I can reproduce the issue. Will investigate the issue. |
I've created a draft PR with a test that exhibits this issue: #2324 |
While we work through how to address this and what the proper fix is, a temporary workaround is to put a |
Thank you! |
@slack/bolt
version^4.1.0
Your
App
and Receiver Configuration...
Node.js runtime version
v20.16.0
Steps to reproduce:
When I use default thread context store functionalities.
following typescript error occures
Argument of type 'number' is not assignable to parameter of type 'AssistantConfig'.ts(2345)Expected result:
bolt-js/src/Assistant.ts
Lines 32 to 34 in 015a918
getThreadContext
has the same signature as the get method ofthreadContextStore
bolt-js/src/Assistant.ts
Lines 177 to 178 in 015a918
but the implementation of
getThreadContext
requires no arguments. Wouldn’t it be appropriate to remove the argument from type definition?(The same could be said for
saveThreadContext
.)The text was updated successfully, but these errors were encountered: