asticode / go-astilectron

Build cross platform GUI apps with GO and HTML/JS/CSS (powered by Electron)

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Suddenly not working anymore

GameBurrow opened this issue · comments

I have 2 computers, one running Windows 10 and one running Windows 11. Both are quite cleanly installed. When open my executables that have been built by astielectron, they look like this:

image

The computer that is running Windows 10, was my main computer up until last week. The same version of the .exe worked just fine there both with Win 11 and Win 11.

Just incease tried to update all go packages and rebuild, still the same.

It should look like this:
image

Mmmm it seems the .html is not loaded properly 🤔 And the icon next to the window title is the wrong one too...

Can you tell me if there's something at C:\Users\kerts\AppData\Roaming\GO Group Virtual OMSI Tool\resources\icon.png ?

Mmmm it seems the .html is not loaded properly 🤔 And the icon next to the window title is the wrong one too...

Can you tell me if there's something at C:\Users\kerts\AppData\Roaming\GO Group Virtual OMSI Tool\resources\icon.png ?

Not at all
image

Are you using the bundler?

Are you using the bundler?

Yep. My entire project is open-sourced: https://gitlab.com/gogroupvirtual/omsi-map-overhaul-generator

I was having something like this so I just ended up using go embed to bundle the resources in the binary itself. So it could be used as a temp fix if you want, until you find whats the real fix.

From which directory are you running the bundler ? And what are the ouput logs ?

I think what's happening is that you're not running the bundler from inside your src directory, therefore your resources are not binded to the binary.

As I said, it worked before.

This .exe https://gitlab.com/gogroupvirtual/omsi-map-overhaul-generator/-/releases/0.7.1, built 2 months ago. Worked up just fine, starting from around last week. It no longer works. Same - already built .exe

This stopped working at this commit: without the Asset methods, the bootstrap has no way to disembed resources properly.

Ah I see. I'm guessing it worked on the old computer because I already had the files there from previous runs.

Let me try to fix that.

Indeed, that was the cause.