Skip to content

Commit ecfc4b9

Browse files
committed
get the metro tp to execute smoothly
1 parent fa87a9b commit ecfc4b9

File tree

4 files changed

+14
-0
lines changed

4 files changed

+14
-0
lines changed

notebooks/tps/metro/.teacher/README-metro-corrige-nb.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -601,12 +601,16 @@ class Graph:
601601
maintenant on devrait pouvoir construire le graphe
602602

603603
```{code-cell} ipython3
604+
:tags: [raises-exception]
605+
604606
metro = build_graph(stations, hops)
605607
606608
print(f"notre graphe a {len(metro)} stations et {metro.nb_edges()} liens")
607609
```
608610

609611
```{code-cell} ipython3
612+
:tags: [raises-exception]
613+
610614
# exercice: calculer le nombre de lignes
611615
nb_lines = ...
612616
# prune-line-begin
@@ -730,6 +734,8 @@ def build_map(metro, show_labels=True):
730734
à ce stade si votre code pour `Node` et `Graph` est correct vous pouvez voir ici la carte du réseau avec la station Chatelet numérotée `0`
731735

732736
```{code-cell} ipython3
737+
:tags: [raises-exception]
738+
733739
# on met au moins un label pour voir l'effet
734740
metro.find_node_from_station_id(chatelet_station_id).label = '0'
735741
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../labelicon.py
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
../nuancier.py

notebooks/tps/metro/README-metro-nb.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -508,12 +508,16 @@ class Graph:
508508
maintenant on devrait pouvoir construire le graphe
509509

510510
```{code-cell} ipython3
511+
:tags: [raises-exception]
512+
511513
metro = build_graph(stations, hops)
512514
513515
print(f"notre graphe a {len(metro)} stations et {metro.nb_edges()} liens")
514516
```
515517

516518
```{code-cell} ipython3
519+
:tags: [raises-exception]
520+
517521
# exercice: calculer le nombre de lignes
518522
nb_lines = ...
519523
@@ -633,6 +637,8 @@ def build_map(metro, show_labels=True):
633637
à ce stade si votre code pour `Node` et `Graph` est correct vous pouvez voir ici la carte du réseau avec la station Chatelet numérotée `0`
634638

635639
```{code-cell} ipython3
640+
:tags: [raises-exception]
641+
636642
# on met au moins un label pour voir l'effet
637643
metro.find_node_from_station_id(chatelet_station_id).label = '0'
638644

0 commit comments

Comments
 (0)