From ec9eb8d054f8809c4ef981fb1a3d90b5193faa6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jan=20Kundr=C3=A1t?= Date: Mon, 23 Sep 2019 00:14:56 +0100 Subject: [PATCH] examples: commented-out path printing for Esther I'm trying to clean up the core code while not causing too much trouble to our users. Esther pointed out that there's an internal use case at Orange where people are looking at the incremental results when computing paths. I strongly dislike commented-out debugging code, but for the sake of progress, let's put it in here. It's roughly as good as that unused `show` parameter, and it allowed a refactoring to make the code more readable. --- examples/path_requests_run.py | 1 + 1 file changed, 1 insertion(+) diff --git a/examples/path_requests_run.py b/examples/path_requests_run.py index a5fc979cd..4b836e8a1 100755 --- a/examples/path_requests_run.py +++ b/examples/path_requests_run.py @@ -167,6 +167,7 @@ def compute_path_with_disjunction(network, equipment, pathreqlist, pathlist): if total_path : if pathreq.baud_rate is not None: total_path = propagate(total_path,pathreq,equipment) + # for el in total_path: print(el) temp_snr01nm = round(mean(total_path[-1].snr+lin2db(pathreq.baud_rate/(12.5e9))),2) if temp_snr01nm < pathreq.OSNR : msg = f'\tWarning! Request {pathreq.request_id} computed path from {pathreq.source} to {pathreq.destination} does not pass with {pathreq.tsp_mode}\n' +\