ocsigen / ts2ocaml

Generate OCaml bindings from TypeScript definitions via the TypeScript compiler API

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error: string is null or whitespace\nParameter name: str

Lupus opened this issue · comments

I've ran into the following issue while trying to generate bindings for cassandra-driver package:

vagrant@buster:~/git/ts_to_mli$ yarn ts2ocaml jsoo node_modules/cassandra-driver/index.d.ts --preset=full --output-dir=lib --simplify --verbose
yarn run v1.19.2
$ /home/vagrant/git/ts_to_mli/node_modules/.bin/ts2ocaml jsoo node_modules/cassandra-driver/index.d.ts --preset=full --output-dir=lib --simplify --verbose
* using the preset 'full'.
* parsing node_modules/cassandra-driver/index.d.ts...
warn: importing an identifier is not supported at line 27, col 1 of node_modules/cassandra-driver/index.d.ts
> import Long = types.Long;
warn: importing an identifier is not supported at line 28, col 1 of node_modules/cassandra-driver/index.d.ts
> import Uuid = types.Uuid;
warn: importing an identifier is not supported at line 29, col 1 of node_modules/cassandra-driver/index.d.ts
> import graph = datastax.graph;
warn: re-exporting an external module is not supported. at line 32, col 1 of node_modules/cassandra-driver/index.d.ts
> export { concurrent } from './lib/concurrent';
warn: re-exporting an external module is not supported. at line 33, col 1 of node_modules/cassandra-driver/index.d.ts
> export { mapping } from './lib/mapping';
warn: re-exporting an external module is not supported. at line 34, col 1 of node_modules/cassandra-driver/index.d.ts
> export { geometry } from './lib/geometry';
* the inferred output file name is 'cassandra_driver.mli'
* running typer...
* normalizing syntax trees...
* resolving identifiers...
* evaluating type expressions...
* emitting a binding for js_of_ocaml...
Error: string is null or whitespace\nParameter name: str
    at _a (/home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:86737)
    at /home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:307319
    at Kt (/home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:24654)
    at pu (/home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:307312)
    at /home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:375726
    at rn (/home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:28445)
    at /home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:375682
    at /home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:377026
    at En.f (/home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:31822)
    at En.GetEnumerator (/home/vagrant/git/ts_to_mli/node_modules/@ocsigen/ts2ocaml/dist/ts2ocaml.js:2:30744)
Done in 0.96s.

Versions used:
cassandra-driver@4.4.0
@ocsigen/ts2ocaml@1.0.0