Yooooomi / your_spotify

Self hosted Spotify tracking dashboard
GNU General Public License v3.0
2.82k stars 113 forks source link

Extended streaming history problems #248

Closed Worldrazor closed 1 year ago

Worldrazor commented 1 year ago

Describe the bug

Can't upload my extended streaming history. It says to use files with starting with endsongX.json. I dont have that, so maybe Spotify has changed something? When I try to upload all my year_number.json it dosen't do anything. Just shows the loading sign and then does nothing. I can upload each file 1 by one it seems like.

Screenshot 2023-06-09 at 10 42 27 Screenshot 2023-06-09 at 10 36 51

Expected behavior

Upload my files so I can see the statistics.

Additional context

Please paste the docker-compose file you're using to host YourSpotify and their logs (you can skip mongo logs). If your issue have anything related to other tools, please paste their config too.

version: "3"

services:
  server:
    image: yooooomi/your_spotify_server
    restart: always
    ports:
      - "8080:8080"
    links:
      - mongo
    depends_on:
      - mongo
    environment:
      API_ENDPOINT: https://spotify-api.domain.com # This MUST be included as a valid URL in the spotify dashboard (see below)
      CLIENT_ENDPOINT: https://spotify.domain.com
      SPOTIFY_PUBLIC: 78ca6f8b982a463784fc6a74da0a6c8d
      SPOTIFY_SECRET: a0a7fe6378e44cf990f8cf43fd427438
  mongo:
    container_name: mongo
    image: mongo:6
    volumes:
      - ./your_spotify_db:/data/db

  web:
    image: yooooomi/your_spotify_client
    restart: always
    ports:
      - "3000:3000"
    environment:
      API_ENDPOINT: https://spotify-api.domain.com
Yooooomi commented 1 year ago

Hello, yeah they definitely changed something according to your screenshot. You can force the process iirc. File names should not block the import.

Worldrazor commented 1 year ago

Could you elaborate? Do I need to upload the files one by one or is there a better way? Because it dosen't do anything when I try to upload multiple files through the "upload page".

Yooooomi commented 1 year ago

Uploading them all at once should not break. I think what is breaking is that you upload more than 20mb of data. This is something i can increase in the future.

Yooooomi commented 1 year ago

Wait, I think the limit is 20mb per file so this should be ok. Could you send a screenshot of the actual request in the browsers network panel?

Worldrazor commented 1 year ago

This right?

Screenshot 2023-06-09 at 11 47 42
Yooooomi commented 1 year ago

Yeah exactly, thanks. What reverse proxy are you using? If any

Worldrazor commented 1 year ago

Cloudflare tunnel

Yooooomi commented 1 year ago

Can you double check that you're allowed to upload 50mo in an http payload? It seems to be the problem

Worldrazor commented 1 year ago

Sorry, but how and where would I check that?

I'm using chrome, and I also just tried with safari

Yooooomi commented 1 year ago

Cloudflare is telling that you're trying to upload something to big for it. It won't change depending on browser. I'll try finding a solution with cloudflare tunnel

Yooooomi commented 1 year ago

It seems to be limited to 100mb according to this. So if you chunk your imports it should work :)

Worldrazor commented 1 year ago

Got it, I'll try that when I get home again.

Another question: I have uploaded 2 of the years from the extended history and I can't remember which. If I upload everything again will that be a problem? Will it duplicate entries for example?

Yooooomi commented 1 year ago

Duplicates are handled don't worry :)

Worldrazor commented 1 year ago

Seems to work. I appreciate it! Thank you!

Please drink a beer or two on me this weekend :)

Yooooomi commented 1 year ago

Thanks a lot man