[MERGED] python/osmo-python-tests[master]: osmo_verify_transcript: add error handling for missing port

This is merely a historical archive of years 2008-2021, before the migration to mailman3.

A maintained and still updated list archive can be found at https://lists.osmocom.org/hyperkitty/list/gerrit-log@lists.osmocom.org/.

Neels Hofmeyr gerrit-no-reply at lists.osmocom.org
Tue Oct 24 15:30:29 UTC 2017


Neels Hofmeyr has submitted this change and it was merged.

Change subject: osmo_verify_transcript: add error handling for missing port
......................................................................


osmo_verify_transcript: add error handling for missing port

Change-Id: I1627c36cfb627e7f3a9b4d9f087bf10875ae0690
---
M osmopy/osmo_verify_transcript_common.py
1 file changed, 3 insertions(+), 0 deletions(-)

Approvals:
  Neels Hofmeyr: Verified
  Harald Welte: Looks good to me, approved



diff --git a/osmopy/osmo_verify_transcript_common.py b/osmopy/osmo_verify_transcript_common.py
index e4b5553..d8e9860 100644
--- a/osmopy/osmo_verify_transcript_common.py
+++ b/osmopy/osmo_verify_transcript_common.py
@@ -70,6 +70,9 @@
         self.verbose = verbose
         self.update = update
 
+        if not port:
+            raise Exception("You need to provide port number to connect to")
+
     def connect(self):
         assert self.socket is None
         retries = 30

-- 
To view, visit https://gerrit.osmocom.org/4321
To unsubscribe, visit https://gerrit.osmocom.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I1627c36cfb627e7f3a9b4d9f087bf10875ae0690
Gerrit-PatchSet: 1
Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Harald Welte <laforge at gnumonks.org>
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>



More information about the gerrit-log mailing list