From a6fbc812a3bde5ec05497f5443572c812ca4482b Mon Sep 17 00:00:00 2001 From: Neels Hofmeyr Date: Tue, 28 Apr 2026 05:14:17 +0200 Subject: [PATCH] ConfigurableParameter.get_typical_input_len: limit to 10 lines Calling applications can use get_typical_input_len() to decide for the size of an input field. For very long input, a text input field typically scrolls. So set an upper limit for get_typical_input_len(). Change-Id: Ia3d79e786f397a02bf2a8fafac5030d1198d9f76 Jenkins: skip-card-test --- pySim/esim/saip/personalization.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pySim/esim/saip/personalization.py b/pySim/esim/saip/personalization.py index fb5c1e3e..350ee20c 100644 --- a/pySim/esim/saip/personalization.py +++ b/pySim/esim/saip/personalization.py @@ -297,7 +297,9 @@ class ConfigurableParameter(abc.ABC, metaclass=ClassVarMeta): May be overridden by subclasses. This default implementation returns the maximum allowed value length -- a good fit for most subclasses. ''' - return cls.get_len_range()[1] or 16 + l = cls.get_len_range()[1] or 16 + l = min(10*80, l) + return l @classmethod def is_super_of(cls, other_class):