From 43ade9b8263fa6f59f35ff35614083eaff418986 Mon Sep 17 00:00:00 2001 From: Ariadne Conill Date: Wed, 14 May 2025 13:49:28 -0700 Subject: [PATCH] tests: fix identify_done callbacks As part of the Alpine 3.22 rebuild, we have observed a TypeError involving the identify_done() function receiving 3 arguments while only accepting 2 positional arguments. Accordingly, add a third unused argument to the local identify_done callbacks in the test suite. --- tests/egismoc-0586/custom.py | 2 +- tests/egismoc-0587/custom.py | 2 +- tests/egismoc-05a1/custom.py | 2 +- tests/egismoc/custom.py | 2 +- tests/elanmoc/custom.py | 2 +- tests/focaltech_moc/custom.py | 2 +- tests/fpcmoc/custom.py | 2 +- tests/goodixmoc/custom.py | 2 +- tests/realtek-5816/custom.py | 2 +- tests/realtek/custom.py | 2 +- 10 files changed, 10 insertions(+), 10 deletions(-) diff --git a/tests/egismoc-0586/custom.py b/tests/egismoc-0586/custom.py index 3a66238..f079acb 100755 --- a/tests/egismoc-0586/custom.py +++ b/tests/egismoc-0586/custom.py @@ -36,7 +36,7 @@ def enroll_progress(*args): print("finger status: ", d.get_finger_status()) print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/egismoc-0587/custom.py b/tests/egismoc-0587/custom.py index 3a66238..f079acb 100755 --- a/tests/egismoc-0587/custom.py +++ b/tests/egismoc-0587/custom.py @@ -36,7 +36,7 @@ def enroll_progress(*args): print("finger status: ", d.get_finger_status()) print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/egismoc-05a1/custom.py b/tests/egismoc-05a1/custom.py index 3a66238..f079acb 100755 --- a/tests/egismoc-05a1/custom.py +++ b/tests/egismoc-05a1/custom.py @@ -36,7 +36,7 @@ def enroll_progress(*args): print("finger status: ", d.get_finger_status()) print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/egismoc/custom.py b/tests/egismoc/custom.py index 3a66238..f079acb 100755 --- a/tests/egismoc/custom.py +++ b/tests/egismoc/custom.py @@ -36,7 +36,7 @@ def enroll_progress(*args): print("finger status: ", d.get_finger_status()) print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/elanmoc/custom.py b/tests/elanmoc/custom.py index 1a3b8b3..e316d6c 100755 --- a/tests/elanmoc/custom.py +++ b/tests/elanmoc/custom.py @@ -38,7 +38,7 @@ def enroll_progress(*args): print("finger status: ", d.get_finger_status()) print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/focaltech_moc/custom.py b/tests/focaltech_moc/custom.py index 6a876c6..0a3d831 100755 --- a/tests/focaltech_moc/custom.py +++ b/tests/focaltech_moc/custom.py @@ -38,7 +38,7 @@ def enroll_progress(*args): print("finger status: ", d.get_finger_status()) print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/fpcmoc/custom.py b/tests/fpcmoc/custom.py index 709ba93..b91d53b 100755 --- a/tests/fpcmoc/custom.py +++ b/tests/fpcmoc/custom.py @@ -41,7 +41,7 @@ def enroll_progress(*args): assert d.get_finger_status() == FPrint.FingerStatusFlags.NEEDED print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/goodixmoc/custom.py b/tests/goodixmoc/custom.py index 91922f1..7acdb14 100755 --- a/tests/goodixmoc/custom.py +++ b/tests/goodixmoc/custom.py @@ -40,7 +40,7 @@ def enroll_progress(*args): assert d.get_finger_status() & FPrint.FingerStatusFlags.NEEDED print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True identify_match, identify_print = dev.identify_finish(res) diff --git a/tests/realtek-5816/custom.py b/tests/realtek-5816/custom.py index 15a71e2..60fd8fc 100755 --- a/tests/realtek-5816/custom.py +++ b/tests/realtek-5816/custom.py @@ -40,7 +40,7 @@ def enroll_progress(*args): # assert d.get_finger_status() & FPrint.FingerStatusFlags.NEEDED print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True try: diff --git a/tests/realtek/custom.py b/tests/realtek/custom.py index 15a71e2..60fd8fc 100755 --- a/tests/realtek/custom.py +++ b/tests/realtek/custom.py @@ -40,7 +40,7 @@ def enroll_progress(*args): # assert d.get_finger_status() & FPrint.FingerStatusFlags.NEEDED print('enroll progress: ' + str(args)) -def identify_done(dev, res): +def identify_done(dev, res, _): global identified identified = True try: -- 2.49.0