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

Linking nonexistent files fails with a confusing error #356

Closed
vcaputo opened this issue Sep 28, 2018 · 6 comments
Closed

Linking nonexistent files fails with a confusing error #356

vcaputo opened this issue Sep 28, 2018 · 6 comments
Labels
Milestone

Comments

@vcaputo
Copy link

vcaputo commented Sep 28, 2018

System information

SolveSpace version: 3.0~4d1e1341

Operating system: Debian 9.5 amd64

Expected behavior

What should have happened?

Linked the file

Actual behavior

What actually happened?

Failed with nonsensical error.

Additional information

If I instead go through "New Group -> Link / Assemble -> foo.slvs" it succeeds, so it's not a file-specific problem. (the file in question doesn't reference other .slvs files either, it's a simple cylinder)

In summary:

"Link Recent" fails, showing a 'The linked file "" is not present' dialog, twice in quick succession.

A subsequent attempt at linking instead via "Link / Assemble" selecting the same file again shows the 'The linked file "" is not present" dialog, but only once, and succeeds at linking the file.

On a fresh start, going directly to "Link /Assemble" on the same file shows no such dialog and just works.

@vcaputo vcaputo changed the title "New Group -> Link Recent -> foo.slvs" fails with 'The linked file "" is not present." "New Group -> Link Recent -> foo.slvs" fails with 'The linked file "" is not present.' Sep 28, 2018
@whitequark
Copy link
Contributor

Can you post your ~/.config/solvespace/settings.json file here?

@vcaputo
Copy link
Author

vcaputo commented Sep 28, 2018

https://ruiner.halo.nu/~swivel/tmp/solvespace-settings.json

FYI all the paths referenced in that file exist as well.

@whitequark
Copy link
Contributor

Thanks. I can't reproduce that. I know why you might be getting two dialogs in quick succession, but I believe I've fixed all of the bugs like that a while ago, and the code seems right to me.

Can you break in gdb at LocateImportedFile and show me the result of info locals?

@vcaputo
Copy link
Author

vcaputo commented Sep 28, 2018

Ok, it looks like I made a mistake with asserting the file actually exists; it doesn't, one of the directories in the path had changed names recently.

However, there is still a bug with the dialog box showing "" for the file path, and there appears to be some kind of stuck state causing the dialog to recur even when loading the existing file via "Link / Assemble".

@whitequark maybe you can reproduce what I'm seeing by renaming/reomving the file before opening it via "Link Recent"?

@whitequark whitequark added this to the 3.0 milestone May 24, 2019
@whitequark whitequark removed the Linux label May 24, 2019
@whitequark
Copy link
Contributor

@vcaputo Yes. I can reproduce it now.

@whitequark whitequark changed the title "New Group -> Link Recent -> foo.slvs" fails with 'The linked file "" is not present.' Linking nonexistent files fails with a confusing error May 24, 2019
@whitequark
Copy link
Contributor

Fixed in eb7e12b.

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

No branches or pull requests

2 participants