nut-tree/nut.js

TypeError: libnut.highlight is not a function

JoeyDon opened this issue · 2 comments

Version
"dependencies": {
"@nut-tree/libnut": "^4.5.0",
"@nut-tree/nl-matcher": "3.1.0",
"@nut-tree/nut-js": "4.5.0",
"@nut-tree/plugin-ocr": "^2.1.0"
}

Short overview
I got TypeError: libnut.highlight is not a function, anyone knows what might be the reason and how to fix? I would love to use this func to test patterns visually

Issue occurs on
M3 macbook air

node version:
v19

OS type and version:
MacOs M3

Detailed error description
TypeError: libnut.highlight is not a function

Full code sample to reproduce

    screen.config.highlightDurationMs = 3000;
    const highlightRegion = new Region(50, 100, 200, 300);
    await screen.highlight(highlightRegion);

Hi @JoeyDon 👋

This is a known bug that’s already fixed in the latest snapshot. A release is coming before the end of the year, meanwhile you could try the snapshot

npm i @nut-tree/nut-js@next -f

Hi @JoeyDon 👋

This issue is fixed with release v4.5.1