indicator timeout increased
This commit is contained in:
@@ -79,7 +79,7 @@ function evaluateIndicator(
|
||||
periodSeconds: number,
|
||||
pandasTaName: string,
|
||||
parameters: Record<string, any>,
|
||||
timeoutMs = 30_000,
|
||||
timeoutMs = 120_000,
|
||||
signal?: AbortSignal,
|
||||
): Promise<EvaluateResult> {
|
||||
const requestId = `cind_${Date.now()}_${Math.random().toString(36).substring(7)}`
|
||||
@@ -257,7 +257,7 @@ function makeStudyConstructor(nOutputs: number = MAX_PLOTS) {
|
||||
pendingEvaluations.set(entry.indicatorId, abortController)
|
||||
|
||||
evaluateIndicator(symbol, fromTime, toTime, periodSeconds, entry.pandasTaName,
|
||||
entry.parameters, 30_000, abortController.signal)
|
||||
entry.parameters, 120_000, abortController.signal)
|
||||
.then((result) => {
|
||||
pendingEvaluations.delete(entry.indicatorId)
|
||||
if (myGen !== _fetchGen) return
|
||||
@@ -753,7 +753,8 @@ export function useCustomIndicators(tvWidget: any) {
|
||||
lastParams.set(id, JSON.stringify(indicator.parameters))
|
||||
await registerCustomStudy(indicator)
|
||||
} else {
|
||||
const entry = registered.get(id)!
|
||||
const entry = registered.get(id)
|
||||
if (!entry) continue
|
||||
const currParams = JSON.stringify(indicator.parameters)
|
||||
const prevParams = lastParams.get(id)
|
||||
const currSymbol = indicator.symbol || chartStore.symbol
|
||||
|
||||
Reference in New Issue
Block a user