Skip to content

Commit

Permalink
Merge pull request #34818 from dimagi/dm/mobile-ucr-rows-max-bucket
Browse files Browse the repository at this point in the history
Preserve max bucket size if limit < 250K
  • Loading branch information
millerdev authored Jun 25, 2024
2 parents 30efc6e + 2c9968b commit 7cc0f27
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion corehq/apps/app_manager/fixtures/mobile_ucr.py
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,11 @@ def _should_sync(restore_state):

@memoized
def _count_buckets():
max_size = max(settings.MAX_MOBILE_UCR_SIZE, 250000)
count_buckets = []
for x in range(10):
bucket_value = 100 * 10 ** x
if bucket_value >= settings.MAX_MOBILE_UCR_SIZE:
if bucket_value >= max_size:
count_buckets.append(settings.MAX_MOBILE_UCR_SIZE)
break
else:
Expand Down

0 comments on commit 7cc0f27

Please sign in to comment.