Changement du print lors de d'une erreur avec le serveur #27

Merged
tipragot merged 1 commit from remove-print into main 2024-01-07 11:03:46 +00:00
Showing only changes of commit fe82f29071 - Show all commits

View file

@ -21,8 +21,8 @@ IP = "pong.cocosol.fr"
def get_scores() -> list[tuple[int, str]]:
try:
return rq.get(f"https://{IP}/data").json()
except:
print("Error with the serveur")
except Exception as error:
print("Error with the serveur : " + str(error))
return []
@ -81,7 +81,6 @@ def __spawn_score(world: World):
"""
Ajoute le score dans le monde.
"""
print(get_scores())
for i, (score, name) in enumerate(get_scores()):
world.new_entity().set(
TextBundle(