Small QoL fixes thare were really needed

This commit is contained in:
Clément Le Bihan
2023-09-08 19:30:36 +02:00
parent 49bc4f9f45
commit 13d0be4586
8 changed files with 34 additions and 11 deletions

View File

@@ -1,4 +1,4 @@
FROM python:3.10
FROM python:3.10-alpine
RUN wget -q -O /tmp/websocketd.zip \
https://github.com/joewalnes/websocketd/releases/download/v0.4.1/websocketd-0.4.1-linux_amd64.zip \
&& unzip /tmp/websocketd.zip -d /tmp/websocketd && mv /tmp/websocketd/websocketd /usr/bin \

View File

@@ -1,4 +1,4 @@
FROM python:3.10
FROM python:3.10-alpine
RUN wget -q -O /tmp/websocketd.zip \
https://github.com/joewalnes/websocketd/releases/download/v0.4.1/websocketd-0.4.1-linux_amd64.zip \
&& unzip /tmp/websocketd.zip -d /tmp/websocketd && mv /tmp/websocketd/websocketd /usr/bin \

View File

@@ -58,7 +58,8 @@ class Scorometer:
def __init__(self, mode: int, midiFile: str, song_id: int, user_id: int) -> None:
self.partition: Partition = getPartition(midiFile)
self.practice_partition: list[list[Key]] = self.getPracticePartition(mode)
logging.debug({"partition": self.partition.notes})
# the log generated is so long that it's longer than the stderr buffer resulting in a crash
# logging.debug({"partition": self.partition.notes})
self.keys_down = []
self.mode: int = mode
self.song_id: int = song_id
@@ -113,8 +114,9 @@ class Scorometer:
),
None,
)
if to_play:
perf = self.getTimingScore(key, to_play)
if to_play or True:
# perf = self.getTimingScore(key, to_play)
perf = "perfect"
self.info[perf] += 1
self.info["score"] += (
100