(core) Two fixes to tests affected by changes that came from grist-core.

Summary:
- For python2, skip some tests of renaming which produce different results
  because of an un-upgradable astroid version.
- Fix test affected by pyCall() having changed to async; avoid hanging timeout
  callback in case of error.

Test Plan: All test cases should now pass (with 4 getting skipped)

Reviewers: paulfitz

Reviewed By: paulfitz

Differential Revision: https://phab.getgrist.com/D3819
This commit is contained in:
Dmitry S
2023-03-14 11:24:32 -04:00
parent 86681de595
commit efd92c6c2a
2 changed files with 12 additions and 4 deletions

View File

@@ -229,9 +229,11 @@ export class NSandbox implements ISandbox {
// (or just benign if the doc is big).
log.rawWarn('Slow pyCall', {...this._logMeta, funcName});
}, 10000);
const result = await this._pyCallWait(funcName, startTime);
clearTimeout(slowCallCheck);
return result;
try {
return await this._pyCallWait(funcName, startTime);
} finally {
clearTimeout(slowCallCheck);
}
}
/**