Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit f11899d0 authored by Myles Watson's avatar Myles Watson Committed by Charlie Boutier
Browse files

Escape MMIs that are not Python identifiers

Map 6000 -> _mmi_6000

Bug: 239453735
Bug: 241962982
Test: atest pts-bot:SDP/SR/SA/BV-20-C -v
Ignore-AOSP-First: Cherry-picked from AOSP
Merged-In: I89181fa2a082b000a9b210cbfb4f5136999706b6
Change-Id: I89181fa2a082b000a9b210cbfb4f5136999706b6
parent 73509fdd
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -35,6 +35,8 @@ class ProfileProxy:
            AttributeError: the MMI is not implemented.
        """
        try:
            if not mmi_name.isidentifier():
                mmi_name = "_mmi_" + mmi_name
            return getattr(self, mmi_name)(
                test=test, description=mmi_description, pts_addr=pts_addr)
        except AttributeError: