Closed ThetaGamma closed 2 months ago
Vergessen: in tunequest funktioniert die authentifizierung mit client-id und client-secret und ich habe alle validen callback urls im Spotify Developer Dashboard hinzugefügt (e.g. localhost:3000, localhost:5173, usw)
Hi, ich hab gerade mal unter linux (ubuntu 22.04.1) mit node 20.9 und npm 10.1 getestet und hat ohne probleme geklappt. Hast du vielleicht noch ein paar mehr infos über dein OS + Node / NPM Version.
Funktioniert das bei dir im docker container nicht oder lässt du das lokal direkt bei dir unter linux laufen?
Viele Grüße
Hi das ist sehr strange... ich habe es sowohl direkt unter linux versucht (Ubuntu 22.04.4, node v22.6.0, npm 10.8.2) als auch im Container. Beim Builder hab ich einmal node 20 und dann node-22 alpine getestet, der runner nginx basiert auf debian. Mein Mac hat übrigens auch node v22.6.0, npm 10.8.2.
Ich ziehe mal eine ganz jungfräuliche VM mit deinen Versionen hoch und teste dort... Viele Grüße Torsten
OK, getestet: gleiches Ergebnis:
Module "crypto" has been externalized for browser compatibility. Cannot access "crypto.webcrypto" in client code. See https://vitejs.dev/guide/troubleshooting.html#module-externalized-for-browser-compatibility for more details.
Kommt diese meldung in der Node/Vite console oder in der Browser Console? Wenn du dir den code aber mal anguckst, bei mir passiert da bis auf nen paar loops und nen bisschen parsen nicht wirklich viel, das scheint ein problem zwischen vite und @spotify/web-api-ts-sdk zu sein, da kann ich nicht wirklich viel dran machen zumal ich es ja leider bei mir nicht mal reproduzieren kann...
In der Browser Console. Dann lassen wir's darauf beruhen 😊
Servus @effem
ich hab den tunecard creator local auf meinem Mac mit
npm run dev
zum Laufen bekommen und bekomme auch die PDFs. --> Top Job! Allerdings läuft der code nicht auf Linux. Ich hab es vollständig lokal unter Linux (ebenfalls mitnpm run dev
) versucht, als auch in einem container.FYI: Dockerfile des containers
Als Browser habe ich Chrome, Safari und Firefox getestet. Die App steigt bei dem "require crypto" aus (vgl code unter dist/assets/*.js nach dem build), sobald die app sich bei Spotify authentifizieren will
Die Lib kommt über die Spotify SDK in den Code. Verschiedene Quellen empfehlen wahlweise crypto durch
crypto-js
odercrypto-browserify
in dervite.config.ts
zu ersetzen. z.B. soTja, aber leider auch erfolglos...
(BTW: