Skip to content

reg-suit run throws maxMemoryUsageInMB error when comparing two long images #713

@ho-shinjo-bf

Description

@ho-shinjo-bf

Describe the bug

reg-cli(reg-suit run) throws error if images are two long to compare. The images size are about 1MB.
Am I able to pass exceededAmount as an option? Or use another option to solve this problem?

/home/runner/work/next/node_modules/.pnpm/jpeg-js@0.4.4/node_modules/jpeg-js/lib/decoder.js:1071
      throw new Error(`maxMemoryUsageInMB limit exceeded by at least ${exceededAmount}MB`);
            ^

Error: maxMemoryUsageInMB limit exceeded by at least 28MB
    at requestMemoryAllocation (/home/runner/work/next/node_modules/.pnpm/jpeg-js@0.4.4/node_modules/jpeg-js/lib/decoder.js:1071:13)
    at buildComponentData (/home/runner/work/next/node_modules/.pnpm/jpeg-js@0.4.4/node_modules/jpeg-js/lib/decoder.js:525:5)
    at constructor.parse (/home/runner/work/next/node_modules/.pnpm/jpeg-js@0.4.4/node_modules/jpeg-js/lib/decoder.js:869:18)
    at Object.decode (/home/runner/work/next/node_modules/.pnpm/jpeg-js@0.4.4/node_modules/jpeg-js/lib/decoder.js:1116:11)
    at /home/runner/work/next/node_modules/.pnpm/img-diff-js@0.5.4/node_modules/img-diff-js/lib/decode-jpeg.js:20:34
    at Generator.next (<anonymous>)
    at fulfilled (/home/runner/work/next/node_modules/.pnpm/img-diff-js@0.5.4/node_modules/img-diff-js/lib/decode-jpeg.js:5:58)

Reproduced step

Steps to reproduce the behavior:

  1. Use reg-suit run to compare two long images

Expected behavior

End without error

Actual behavior

End with over maxMemoryUsageInMB

Screenshots

nth

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions