Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Error on saving file on local machine" #178

Closed
jhovgaard opened this issue Jan 8, 2018 · 9 comments · Fixed by #214
Closed

"Error on saving file on local machine" #178

jhovgaard opened this issue Jan 8, 2018 · 9 comments · Fixed by #214
Labels

Comments

@jhovgaard
Copy link

Hi guys!

For a long time I've been having multiple players complaining about mods not being installed after subscribing. It seems to be strictly Windows (64 bit). Whenever there's a call to greenworks.ugcSynchronizeItems, it will instantly return the following error "Error on saving file on local machine".

I believe this is the line: https://github.com/greenheartgames/greenworks/blob/master/src/greenworks_workshop_workers.cc#L357

For the affected players I've confirmed the following:

  • Plenty of free disk space
  • No third party AV, only Windows Defender
  • Running the electron process as administrator doesn't change anything.

My game is saving files to the exact same directory using fs.writeFile with no problems.

Any idea what can be causing this?

Thanks for reading!
Jonas

@hokein hokein added the bug label Jan 8, 2018
@hokein
Copy link
Member

hokein commented Jan 8, 2018

@jhovgaard Thanks for reporting it.

I suspect the root cause is at https://github.com/greenheartgames/greenworks/blob/master/src/greenworks_workshop_workers.cc#L85, theGetAbsoluteFilePath doesn't generate the legal format file path on Windows (we should use \ as file separator instead of / ) .

@jhovgaard
Copy link
Author

Hi again,

After looking closer at the paths I figured out how to reproduce it: include special characters like Nordic Æ, Ø and Å in folder names. It probably fails with other non-english characters too.

@Noobulater
Copy link

Also having this issue

@Noobulater
Copy link

Noobulater commented Apr 20, 2018

You can resolve this by just specifying the full path yourself. (was trying to use a relative path, don't do that, just use path to find out exactly where to place the file)

FYI : I tried replacing/rebuilding it with \\ and that made no difference

@patrickklug
Copy link
Member

This could explain some issue we've been seeing too. If anyone has a clue how to fix this, we'd love a patch.

@Eyesiah
Copy link

Eyesiah commented Dec 3, 2018

Was any progress made on this issue? I have users also reporting it, and I was able to reproduce it by creating a steam library at D:\SteamLibraryÆØÅ and installing our game there. But our game passes in the absolute path to ugcSynchronizeItems, so I haven't been able to work around it.

@hokein
Copy link
Member

hokein commented Dec 3, 2018

I'm happy to prepare a fix for it, is there any volunteer to test it?

@Eyesiah
Copy link

Eyesiah commented Dec 3, 2018 via email

@jhovgaard
Copy link
Author

jhovgaard commented Dec 4, 2018

I’m ready to test on all platforms too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants