Image scale doesn't work

I don't know if this is a bug or if I'm doing something wrong.

I did the same procedure in another project and had no problems.

After uploading, a resize occurs, and there will still be an "if" there. But even without the "if", I can see that something is wrong.

Up until the upload, everything is successful, but when processing the image, nothing happens. When I debug, I notice that it is missing a module.

Am I doing something wrong or is this a bug?

I'm using w7 beta7, with Server Connect Beta.

See the print.

Click this button:
image

And then try again. Does it work?

If it doesn't work, it's a bug, the sharp module is not being installed

I tried, but the only recommendation was to install, npm install -g npm@10.9.0,

I even updated, restarted Wappler in the Windows tray.

Without success, the problem still exists.

Should I change the tag to bug?

Could you show a screenshot? I don't think you did it right

I even tested the 2 updates, the problem still persists

I meant the screenshot of you doing npm install :sweat_smile: I think you did in the wrong Terminal, it needs to be in the terminal of the web server (Docker container), in Wappler it's called "Web Server"

either Web Server or where it was. The problem still occurs.

I repeated the entire process with "Web Server", it still asks for the module

In Web Server, did you try to run the npm install command I mentioned?

Edit: My bad, I removed the command lol

npm install sharp

That command is a workaround to install the sharp module. But in reality it's a Wappler bug that failed to put sharp in package.json

1 Like

passing the command you passed now it works.
but before you had not passed this command, only now.

npm install sharp

Yes it works.
is it a bug?

Yes, I'm sorry :pray:

Yes, it's a bug

I must have aged about 20 years with the "sharp" problem.

I was happy that everything worked perfectly.

When I included the "ifs", the conditions, where a type of image processing is performed for each case, I received an error again and the sharp module did not load.

The message is now different:

"Error: Could not load the "sharp" module using the linux-x64 runtime"

Many will think it must be something in the docker environment, and why was it working for the last 2 days right after running "npm install sharp"?

I've tried changing the OS in docker, Alpine, Debian 12, Debian11.

I've tried following the console recommendations:

1- npm install --include=optional sharp
2 - npm install --os=linux --cpu=x64 sharp

Nothing makes sharp load.

Has anyone else been having this problem? What version of sharp is being used?

If anyone has any more tips, I'd appreciate it.