osmo-gsm-tester[master]: error log: clarify for using more resources than reserved

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
Thu Jun 8 21:38:34 UTC 2017


Patch Set 1:

(1 comment)

https://gerrit.osmocom.org/#/c/2852/1/src/osmo_gsm_tester/resource.py
File src/osmo_gsm_tester/resource.py:

Line 483:                 msg = 'suite.conf reserved only %d x %r.' % (len(kind_reserved), kind)
> Are you perhaps checking the wrong way or I am missing something here? I'm 
exactly, this is correct. I could check for used_count == len(), but my personal preference is to write more paranoid code. What if for some odd software bug, used_count ends up > len()? Hence I rather check for "not (used_count < len())". Also IMHO this clarifies what I usually want: used_count to be smaller than the reserved amount. If it's not smaller, then go to this error case.


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

Gerrit-MessageType: comment
Gerrit-Change-Id: I1c67600ba69351859e46b8b2f368ee8106db0993
Gerrit-PatchSet: 1
Gerrit-Project: osmo-gsm-tester
Gerrit-Branch: master
Gerrit-Owner: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Jenkins Builder
Gerrit-Reviewer: Neels Hofmeyr <nhofmeyr at sysmocom.de>
Gerrit-Reviewer: Pau Espin Pedrol <pespin at sysmocom.de>
Gerrit-HasComments: Yes



More information about the gerrit-log mailing list