Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-14933

[JS] apache-arrow does not compile with typescript when types are checked

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 6.0.1
    • 7.0.0
    • JavaScript
    • None
    • Node v16.6.0
      TypeScript v4.5.2
      Apache Arrow v6.0.1

    Description

      Similar to https://stackoverflow.com/questions/66956030/apache-arrow-does-not-compile-with-typescript

      Apache Arrow v6.0 does not compile with TypeScript v4.5 when Apache Arrow's types are checked (e.g., `"skipLibCheck": false`)

      When I import `import { Table } from '@apache-arrow/ts';`, I am getting several errors like the following:

      • node_modules/apache-arrow/util/buffer.d.ts:10:328 - error TS2304: Cannot find name 'ReadableStreamReadResult'.
      • node_modules/apache-arrow/Arrow.d.ts:86:540 - error TS2304: Cannot find name 'ReadableStreamReadDoneResult'
      • node_modules/apache-arrow/recordbatch.d.ts:24:22 - error TS2415: Class 'RecordBatch<T>' incorrectly extends base class 'StructVector<T>'.
      • node_modules/apache-arrow/io/interfaces.d.ts:61:18 - error TS2304: Cannot find name 'PipeOptions'.
      • ...

      I've created a repo that reproduces the errors: https://github.com/flekschas/apache-arrow-typescript

      Are those error expected/known or does apache-arrow require a special TypeScript config?

      Attachments

        Activity

          People

            Unassigned Unassigned
            flekschas Fritz Lekschas
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: