mirror of
https://github.com/Faraphel/Atlas-Install.git
synced 2025-07-03 19:28:25 +02:00
version is now loaded when counting track
This commit is contained in:
parent
ef5ab72131
commit
d3892b6e3c
1 changed files with 2 additions and 2 deletions
|
@ -10,6 +10,7 @@ def count_track(self):
|
||||||
tracks = []
|
tracks = []
|
||||||
with open("./ct_config.json", encoding="utf-8") as f:
|
with open("./ct_config.json", encoding="utf-8") as f:
|
||||||
ctconfig = json.load(f)
|
ctconfig = json.load(f)
|
||||||
|
self.VERSION = ctconfig["version"]
|
||||||
for cup in ctconfig["cup"].values():
|
for cup in ctconfig["cup"].values():
|
||||||
if not (cup["locked"]): tracks.extend(cup["courses"].values())
|
if not (cup["locked"]): tracks.extend(cup["courses"].values())
|
||||||
tracks.extend(ctconfig["tracks_list"])
|
tracks.extend(ctconfig["tracks_list"])
|
||||||
|
@ -39,7 +40,7 @@ def patch_track(self, tracks, total_track="?"):
|
||||||
|
|
||||||
process_list[track_file] = None # Used for
|
process_list[track_file] = None # Used for
|
||||||
self.Progress(statut=self.translate("Conversion des courses") + f"\n({i + 1}/{total_track})\n" +
|
self.Progress(statut=self.translate("Conversion des courses") + f"\n({i + 1}/{total_track})\n" +
|
||||||
"\n".join(process_list.keys()), add=1)
|
"\n".join(process_list.keys()), add=1)
|
||||||
|
|
||||||
for _track in [get_track_szs(track_file), get_track_wu8(track_file)]:
|
for _track in [get_track_szs(track_file), get_track_wu8(track_file)]:
|
||||||
if os.path.exists(_track):
|
if os.path.exists(_track):
|
||||||
|
@ -80,7 +81,6 @@ def patch_track(self, tracks, total_track="?"):
|
||||||
for track_file, process in process_list.copy().items():
|
for track_file, process in process_list.copy().items():
|
||||||
if process is not None:
|
if process is not None:
|
||||||
if process.poll() is None:
|
if process.poll() is None:
|
||||||
print("still running...")
|
|
||||||
pass # if the process is still running
|
pass # if the process is still running
|
||||||
else: # process ended
|
else: # process ended
|
||||||
process_list.pop(track_file)
|
process_list.pop(track_file)
|
||||||
|
|
Loading…
Reference in a new issue