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

File paths with spaces not resolving #5

Closed
JJSax opened this issue Feb 17, 2022 · 5 comments
Closed

File paths with spaces not resolving #5

JJSax opened this issue Feb 17, 2022 · 5 comments

Comments

@JJSax
Copy link

JJSax commented Feb 17, 2022

In my exact case, I have my open file path inside a folder named "Genetic Algorithm Tests". When launching Love2d, the path it says in the love2d crash screen.

Error

[love "boot.lua"]:323: Cannot load game at path 'c:/Users/jauge/OneDrive/Documents/Programs/Love2d/Genetic'.
Make sure a folder exists at the specified path.


Traceback

[love "callbacks.lua"]:228: in function 'handler'
[C]: in function 'error'
[C]: in function 'xpcall'
[C]: in function 'xpcall'

You'll notice the folder name ends at the first space, which is incorrect.

I'm also getting an error when using alt+L to launch saying "command 'loveme.launch' not found", though this might be another extension.

@mintysylvie
Copy link

Yup! I had this issue too. Project was inside a folder named "Coding Projects". Failed to find main.lua. Changed to "CodingProjects" and it works finally! Even if this never gets fixed, you saved me the hassle of finding a different extension

@ShinuToki
Copy link

I had the same error but I managed to solve it modifying a simple line of the source code of the extension.
In the line 73 of the file Love2d.js you need to replace this:

child.exec(`${love2dExePath} ` + projectRoot).on("close", function (code, signal) {

for this:

child.exec(`${love2dExePath} ` + `"${projectRoot}"`).on("close", function (code, signal) {

@lwz7512
Copy link
Owner

lwz7512 commented Dec 15, 2023

Yup! I had this issue too. Project was inside a folder named "Coding Projects". Failed to find main.lua. Changed to "CodingProjects" and it works finally! Even if this never gets fixed, you saved me the hassle of finding a different extension

thanks for your support!

@lwz7512
Copy link
Owner

lwz7512 commented Dec 15, 2023

I had the same error but I managed to solve it modifying a simple line of the source code of the extension. In the line 73 of the file Love2d.js you need to replace this:

child.exec(`${love2dExePath} ` + projectRoot).on("close", function (code, signal) {

for this:

child.exec(`${love2dExePath} ` + `"${projectRoot}"`).on("close", function (code, signal) {

Awesome! i never had a chance to fix it, thanks for your contribution, i'll make patch for this fix!

@lwz7512
Copy link
Owner

lwz7512 commented Dec 15, 2023

issue fixed with new release: v1.10.3

please check it out!

thanks for feedback!

@lwz7512 lwz7512 closed this as completed Dec 15, 2023
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

No branches or pull requests

4 participants