Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

BigInt check in Arrow profiler is breaking Svelte-kit / Vite builds #263

Open
cristianvogel opened this issue Feb 8, 2022 · 3 comments
Open

Comments

@cristianvogel
Copy link

The one that causes problems is on line 104 https://github.com/uwdata/arquero/blob/master/src/arrow/encode/profiler.js

Changing target on Vite to es2020 isn't really viable for my project at least, and is difficult to do inside a svelt-kit config.

Is that BigInt support really necessary?

@marr
Copy link

marr commented Sep 22, 2022

I am seeing this as well.

@jheer
Copy link
Member

jheer commented Sep 22, 2022

Sorry that this is causing issues. Is the crux of the issue the use of the ** exponentiation operator? Or something else? We don't explicitly use BigInt in the code, so any more detailed description of the error could help.

@cristianvogel
Copy link
Author

HI. As you can read above from the 8 Feb, I have located the exact problem for you. In my local copy of the library, I remove this check and everything compiles fine. If you don't need it for the library , then perhaps try to safely remove the below, I think?

else if (p.bigints === valid) {
    const v = -p.min > p.max ? -p.min - 1n : p.max;
    return p.min < 0
      ? v < 2 ** 63 ? Type.Int64
        : error(`BigInt exceeds 64 bits: ${v}`)
      : p.max < 2 ** 64 ? Type.Uint64
        : error(`BigInt exceeds 64 bits: ${p.max}`);
  }

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants