tecuts commited on
Commit
4d234d2
·
verified ·
1 Parent(s): 62ec371

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -47,15 +47,19 @@ if not SPOTIFY_USERNAME or not SPOTIFY_CREDENTIALS:
47
  raise RuntimeError("Spotify credentials not found in environment variables")
48
 
49
  # Create a temporary credentials.json file
50
- CREDENTIALS_PATH = "/tmp/credentials.json"
 
51
  with open(CREDENTIALS_PATH, "w") as f:
52
  json.dump({
53
  "username": SPOTIFY_USERNAME,
54
  "credentials": SPOTIFY_CREDENTIALS,
55
  "type": "AUTHENTICATION_STORED_SPOTIFY_CREDENTIALS"
56
  }, f)
 
57
 
58
  # Initialize Spotify client
 
 
59
  spo = SpoLogin(credentials_path=CREDENTIALS_PATH)
60
 
61
 
 
47
  raise RuntimeError("Spotify credentials not found in environment variables")
48
 
49
  # Create a temporary credentials.json file
50
+ #CREDENTIALS_PATH = "/tmp/credentials.json"
51
+ '''
52
  with open(CREDENTIALS_PATH, "w") as f:
53
  json.dump({
54
  "username": SPOTIFY_USERNAME,
55
  "credentials": SPOTIFY_CREDENTIALS,
56
  "type": "AUTHENTICATION_STORED_SPOTIFY_CREDENTIALS"
57
  }, f)
58
+ '''
59
 
60
  # Initialize Spotify client
61
+
62
+ CREDENTIALS_PATH = "/app/credentials.json"
63
  spo = SpoLogin(credentials_path=CREDENTIALS_PATH)
64
 
65