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

Fix: electron asar - failed to open spec dir #531

Merged
merged 4 commits into from Feb 3, 2021

Conversation

phpfs
Copy link
Contributor

@phpfs phpfs commented Feb 2, 2021

This PR attempts to resolve the issue described in ticket #530 "electron asar - failed to open spec dir".

Although the removed statements seem to have had intention, their absence does not cause any issue with the current mocha test suite. Locally, the PR runs with 337 test passed and 4 pending - exactly like beforehand. To me it makes sense that the code works without these statements since actual reading takes place using the absolute path only.

It remains to be discussed wether this is a proper fix for the issue (or just a workaround) and if this may cause issues for some users.

Thank you very much @cdimascio for your help :)

For electron-based apps, it is not possible to change the current working directory as all source is packaged within an asar. Therefore, we suggest to remove these calls.
@cdimascio
Copy link
Owner

@phpfs yes. it appears we no longer need to change dir. cool! thanks for this

@cdimascio
Copy link
Owner

one minor nit, please remove the empty finally block. once in, i'll get this merged in and a new version rolled out asap

Copy link
Owner

@cdimascio cdimascio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

cleanup unneeded finally block and we'll get this merged in

@cdimascio
Copy link
Owner

nevermind ;) i cleaned it up

@cdimascio cdimascio merged commit d09f1a2 into cdimascio:master Feb 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants