more edits

- watchdog still broken
This commit is contained in:
geoffrey45
2022-06-17 10:22:53 +03:00
parent 1cc7c933b7
commit 7718a7c99f
4 changed files with 29 additions and 38 deletions
+4 -1
View File
@@ -2,6 +2,7 @@
Contains all the models for objects generation and typing.
"""
from dataclasses import dataclass, field
import random
from typing import List
from app import helpers
@@ -33,8 +34,10 @@ class Track:
try:
self.trackid = tags["_id"]["$oid"]
except KeyError:
self.trackid = "".join(
random.choice("abcdefghijklmnopqrstuvwxyz0123456789") for i in range(20)
)
print("No id")
print(tags)
self.title = tags["title"]
self.artists = tags["artists"].split(", ")