h-REA / hREA

A ValueFlows / REA economic network coordination system implemented on Holochain and with supplied Javascript GraphQL libraries
https://docs.hrea.io
Other
143 stars 15 forks source link

useful stack trace shim for outdated tryorama #276

Closed Connoropolous closed 2 years ago

Connoropolous commented 2 years ago

fixes #271

after applying this, I now get, which includes the useful stack trace:

x

  ---
    operator: fail
    at: <anonymous> (/Users/connor/code/hrea/node_modules/.pnpm/@holochain+tryorama@0.4.10/node_modules/@holochain/tryorama/src/middleware.ts:137:13)
    stack: |-
           Error: TypeError: Cannot read properties of null (reading 'satisfies')
             at /Users/connor/code/hrea/test/flows/flow_records_graphql.js:352:25
             at processTicksAndRejections (node:internal/process/task_queues:96:5)
             at p (/Users/connor/code/hrea/node_modules/.pnpm/@holochain+tryorama@0.4.10/node_modules/@holochain/tryorama/src/middleware.ts:126:29)
             at Test.assert [as _assert] (/Users/connor/code/hrea/node_modules/.pnpm/tape@4.15.0/node_modules/tape/lib/test.js:275:54)
             at Test.bound [as _assert] (/Users/connor/code/hrea/node_modules/.pnpm/tape@4.15.0/node_modules/tape/lib/test.js:89:32)
             at Test.fail (/Users/connor/code/hrea/node_modules/.pnpm/tape@4.15.0/node_modules/tape/lib/test.js:368:10)
             at Test.bound [as fail] (/Users/connor/code/hrea/node_modules/.pnpm/tape@4.15.0/node_modules/tape/lib/test.js:89:32)
             at /Users/connor/code/hrea/node_modules/.pnpm/@holochain+tryorama@0.4.10/node_modules/@holochain/tryorama/src/middleware.ts:137:13
             at processTicksAndRejections (node:internal/process/task_queues:96:5)

  ...

  1 tests
  41 passed
  1 failed

  Failed Tests:   There was 1 failure

    x TypeError: Cannot read properties of null (reading 'satisfies') at /Users/connor/code/hrea/test/flows/flow_records_graphql.js:352:25 at processTicksAndRejections (node:internal/process/task_queues:96:5) at p (/Users/connor/code/hrea/node_modules/.pnpm/@holochain+tryorama@0.4.10/node_modules/@holochain/tryorama/src/middleware.ts:126:29)
pospi commented 2 years ago

This looks sensible to me. Wire it into the postinstall script hooks?

Connoropolous commented 2 years ago

I just extended the fixTryoramaTimeout file which already has the hook, so we should be good for now 👍