mlkit icon indicating copy to clipboard operation
mlkit copied to clipboard

[Bug report] ML Kit Document Scanner pageLimit does not work

Open hieunguyen2211 opened this issue 3 months ago • 11 comments

Describe the bug After the upgrade of Google Play services on September 29, 2025, for the official release of MLKit Document Scanner, the pageLimit feature does not work, regardless of whether using the beta version or upgrading to the official release version.

To Reproduce Example Steps to reproduce the behavior in sample app:

  1. Set pageLimit to 2
  2. Go to Document Scanner showcase

Expected behavior The pageLimit should work like before the upgrade of Google Play services.

SDK Info:

  • mlkit-document-scanner:16.0.0-beta1
  • mlkit-document-scanner:16.0.0

Smartphone:

  • Device/Simulator: Samsung A15
  • Device/Simulator OS: Android 14

hieunguyen2211 avatar Oct 01 '25 10:10 hieunguyen2211

Thanks for flagging this - we are looking into this.

mebjas avatar Oct 06 '25 01:10 mebjas

Update:

Issue has been addressed, and the fix is expected to be rolled out as part of Google Play services apk version >= 25.42.xx. Est. rollout date is: Nov, 03

avivadla8 avatar Oct 21 '25 05:10 avivadla8

Update:

Issue has been addressed, and the fix is expected to be rolled out as part of Google Play services apk version >= 25.42.xx. Est. rollout date is: Nov, 03

Is there any update for this fix? It's already Nov 03

MP-Kate avatar Nov 04 '25 02:11 MP-Kate

val apkVersion = GoogleApiAvailability.getInstance().getApkVersion(appCompatActivity)
println("-> $apkVersion")

-> 254334035

It's still ignoring the page limit value...

michael-winkler avatar Nov 05 '25 06:11 michael-winkler

@MP-Kate My Pixel 10 Pro is running on Google Play Services version number 25.44.32, and the issue seems to be fixed on this version. I have set the pageLimit to 1 in one of my apps, and the scanner is only allowing the user to select or scan a single image.

mehul4795 avatar Nov 05 '25 10:11 mehul4795

@mehul4795 where did you get the Google Play Services version 25.44.32?

The latest version that I only see is 25.43.34, which still ignores the page limit value.

MP-Kate avatar Nov 07 '25 04:11 MP-Kate

@MP-Kate May be it was automatically updated along with the system update I received yesterday.

mehul4795 avatar Nov 07 '25 10:11 mehul4795

val apkVersion = GoogleApiAvailability.getInstance().getApkVersion(appCompatActivity)
println("-> $apkVersion")

-> 254433035

Since today. Google Pixel 9 Pro. But page limit is still not working.

val options = GmsDocumentScannerOptions.Builder()
    .setGalleryImportAllowed(false)
    .setPageLimit(1)
    .setResultFormats(
        GmsDocumentScannerOptions.RESULT_FORMAT_JPEG
    )
    .setScannerMode(GmsDocumentScannerOptions.SCANNER_MODE_BASE)
    .build()

michael-winkler avatar Nov 10 '25 05:11 michael-winkler

-> 254435035

Still not fixed. See https://issuetracker.google.com/issues/445725446

michael-winkler avatar Nov 13 '25 08:11 michael-winkler

-> 254534035

Now it works for me and the page limit input is used. @hieunguyen2211

michael-winkler avatar Nov 24 '25 08:11 michael-winkler

The issue is resolved with Google Play Services version 25.45.34. Thank you very much.

hieunguyen2211 avatar Nov 25 '25 03:11 hieunguyen2211