koleo-cli 0.2.137.10__py3-none-any.whl → 0.2.137.11__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of koleo-cli might be problematic. Click here for more details.

koleo/cli.py CHANGED
@@ -241,11 +241,8 @@ class CLI:
241
241
  dep = arr_dep_to_dt(i["departure"])
242
242
  travel_time = (arr - dep).seconds
243
243
  parts.append(
244
- f"[bold green][link=https://koleo.pl/travel-options/{i["id"]}]{dep.strftime("%H:%M")} - {arr.strftime("%H:%M")}[/bold green] {travel_time//3600}h{(travel_time % 3600)/60:.0f}m {i['distance']}km: [/link]"
244
+ f"[bold green][link=https://koleo.pl/travel-options/{i["id"]}]{dep.strftime("%H:%M")} - {arr.strftime("%H:%M")}[/bold green] {travel_time//3600}h{(travel_time % 3600)/60:.0f}m {i['distance']}km:[/link]"
245
245
  )
246
- if i["constriction_info"]:
247
- for constriction in i["constriction_info"]:
248
- parts.append(f" [bold red]- {constriction} [/bold red]")
249
246
  if len(i["trains"]) == 1:
250
247
  train = i["trains"][0]
251
248
  stop = next(iter(i for i in train["stops"] if i["station_id"] == train["start_station_id"]), {})
@@ -258,10 +255,15 @@ class CLI:
258
255
  )
259
256
  )
260
257
  brand = next(iter(i for i in api_brands if i["id"] == train["brand_id"]), {}).get("logo_text")
258
+ s = f" [red]{brand}[/red] {train["train_full_name"]}[purple] {stop_station['name']} {self.format_position(stop["platform"], stop["track"])}[/purple]"
261
259
  parts[-1] += (
262
260
  f" [red]{brand}[/red] {train["train_full_name"]}[purple] {stop_station['name']} {self.format_position(stop["platform"], stop["track"])}[/purple]"
263
261
  )
262
+ for constriction in i["constriction_info"]:
263
+ parts.append(f" [bold red]- {constriction}[/bold red]")
264
264
  else:
265
+ for constriction in i["constriction_info"]:
266
+ parts.append(f" [bold red]- {constriction}[/bold red]")
265
267
  previous_arrival: datetime | None = None
266
268
  for train in i["trains"]:
267
269
  brand = next(iter(i for i in api_brands if i["id"] == train["brand_id"]), {}).get("logo_text")
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: koleo-cli
3
- Version: 0.2.137.10
3
+ Version: 0.2.137.11
4
4
  Summary: Koleo CLI
5
5
  Home-page: https://github.com/lzgirlcat/koleo-cli
6
6
  Author: Zoey !
@@ -1,13 +1,13 @@
1
1
  koleo/__init__.py,sha256=N_IkOBZCSPCCw31Hu72CFys707PziGFmXpNVl0CXAz8,47
2
2
  koleo/__main__.py,sha256=wu5N2wk8mvBgyvr2ghmQf4prezAe0_i-p123VVreyYc,62
3
3
  koleo/api.py,sha256=07PSwLFmirdJ_JhPBJ7rO1nv_v90njIcwmOoxT4P_4M,5708
4
- koleo/cli.py,sha256=CeZBwuS2ibZZ_HQq8bRwcY4HLq59_tEb9ux7daOvgc4,23239
4
+ koleo/cli.py,sha256=ixTi_44y-j4Yf_cgpZz-9iI5sH1pdyaqHRV-WtqzLbQ,23500
5
5
  koleo/storage.py,sha256=U1ydt8AZ3WsiNBOmThD-cxomLzLrpHRG4BZbMg-14Fc,2304
6
6
  koleo/types.py,sha256=pjVCIH39rUNeipazeRKOuTRCWoslLdbGivKiQmfd5Pw,5226
7
7
  koleo/utils.py,sha256=CsYWNf3IPhHJln445tzXSA7r2z3NpmqVSmw8Rrb7YT0,1822
8
- koleo_cli-0.2.137.10.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
9
- koleo_cli-0.2.137.10.dist-info/METADATA,sha256=wwrlHORzN11td36xS_fjWglZpIWA11EryaJ6rpm9kXk,3096
10
- koleo_cli-0.2.137.10.dist-info/WHEEL,sha256=OVMc5UfuAQiSplgO0_WdW7vXVGAt9Hdd6qtN4HotdyA,91
11
- koleo_cli-0.2.137.10.dist-info/entry_points.txt,sha256=LtCidkVDq8Zd7-fxpRbys1Xa9LTHMZwXVbdcQEscdes,41
12
- koleo_cli-0.2.137.10.dist-info/top_level.txt,sha256=AlWdXotkRYzHpFfOBYi6xOXl1H0zq4-tqtZ2XivoWB4,6
13
- koleo_cli-0.2.137.10.dist-info/RECORD,,
8
+ koleo_cli-0.2.137.11.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
9
+ koleo_cli-0.2.137.11.dist-info/METADATA,sha256=G2q-fowwyDNeu6aY9osXfKDV8vZu9VKJa0CB46NoifY,3096
10
+ koleo_cli-0.2.137.11.dist-info/WHEEL,sha256=P9jw-gEje8ByB7_hXoICnHtVCrEwMQh-630tKvQWehc,91
11
+ koleo_cli-0.2.137.11.dist-info/entry_points.txt,sha256=LtCidkVDq8Zd7-fxpRbys1Xa9LTHMZwXVbdcQEscdes,41
12
+ koleo_cli-0.2.137.11.dist-info/top_level.txt,sha256=AlWdXotkRYzHpFfOBYi6xOXl1H0zq4-tqtZ2XivoWB4,6
13
+ koleo_cli-0.2.137.11.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (75.2.0)
2
+ Generator: setuptools (75.3.0)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5