Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

[🐞] Build of supabase-auth-helpers-qwik fails because of TS type error #7146

Open
byte-barista opened this issue Dec 11, 2024 · 3 comments
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working

Comments

@byte-barista
Copy link

byte-barista commented Dec 11, 2024

Which component is affected?

Qwik Runtime

Describe the bug

When I run pnpm build.local during build this error appears:

`> [email protected] build /Users/nemanjamiljkovic/Desktop/qwik/packages/supabase-auth-helpers-qwik

vite build --mode lib

vite v5.3.5 building for lib...
✓ 3 modules transformed.
lib/index.qwik.mjs 2.80 kB │ gzip: 0.85 kB
lib/index.qwik.cjs 2.96 kB │ gzip: 0.89 kB
✓ built in 42ms
⚛️ supabase-auth-helpers-qwik

packages/docs/src/repl/worker/repl-dependencies.ts:51:3 - error TS2740: Type '{ isServer: true; isBrowser: false; isDev: false; }' is missing the following properties from type 'typeof import("/Users/nemanjamiljkovic/Desktop/qwik/packages/qwik/dist/core")': getLocale, useServerData, withLocale, $, and 86 more.

51 self.qwikBuild = {
~~~~~~~~~~~~~~

Found 2 errors in the same file, starting at: packages/docs/src/repl/worker/repl-dependencies.ts:2

❌ Error: Command failed with exit code 2: tsc -p packages/docs/tsconfig.json`

I was able to resolve it with:

  self.qwikBuild = {
    isServer: true,
    isBrowser: false,
    isDev: false,
  } as typeof import('@builder.io/qwik');

Reproduction

https://github.com/byte-barista/qwik

Steps to reproduce

pnpm install && pnpm build.local

System Info

System:
    OS: macOS 15.1.1
    CPU: (10) arm64 Apple M1 Pro
    Memory: 1.50 GB / 32.00 GB
    Shell: 3.2.57 - /bin/bash
  Binaries:
    Node: 22.11.0 - ~/.nvm/versions/node/v22.11.0/bin/node
    npm: 10.9.0 - ~/.nvm/versions/node/v22.11.0/bin/npm
    pnpm: 9.14.2 - ~/.nvm/versions/node/v22.11.0/bin/pnpm
    Watchman: 2024.12.02.00 - /usr/local/bin/watchman
  Browsers:
    Chrome: 131.0.6778.109
    Safari: 18.1.1
  npmPackages:
    @builder.io/partytown: 0.10.2 => 0.10.2 
    @builder.io/qwik: workspace:^ => 1.11.0 
    @builder.io/qwik-city: workspace:^ => 1.11.0 
    typescript: 5.4.5 => 5.4.5 
    undici: * => 6.6.2 
    vite: 5.3.5 => 5.3.5

Additional Information

No response

@byte-barista byte-barista added STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working labels Dec 11, 2024
@gioboa
Copy link
Member

gioboa commented Dec 11, 2024

Hi @byte-barista I can't access to your repo, is it private?

@byte-barista
Copy link
Author

byte-barista commented Dec 12, 2024

Hi @gioboa, I have tried to reproduce the error on Stackblitz and CodeSandbox, but without success. I can't set up the same environment. I've updated the link to the forked repo of Qwik. Essentially, I cloned the project locally and followed the setup instructions from Contributing.md, but the pnpm build.local command fails with a TS error as shown above. I was trying to run pnpm docs.dev because I'm working on drag-and-drop examples for the Cookbook. I'm not blocked because I was able to resolve it as I showed above.

@gioboa
Copy link
Member

gioboa commented Dec 12, 2024

I see, thanks for opening this issue. I think we need to move this supabase package in another repository. but this is needs another discussion 😓

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
STATUS-1: needs triage New issue which needs to be triaged TYPE: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants