[Gambas-user] Gambas3 IDE crashes itself out of existence
John Anderson
johna at starflightinc.com
Wed May 26 17:46:56 CEST 2021
On 5/26/2021 12:02 AM, Dimitris Anogiatis wrote:
> Hey John... can you open a terminal, go to the folder that you got the
> TestProject.gambas and type:
>
> file TestProject.gambas
>
> It should give you something like this:
>
> TestProject.gambas: a /usr/bin/env gbr3 script executable (binary data)
>
> If it gives you a different result, there might be something wrong
> with the MIME types.
>
>
Yes, that is exactly what I get. It isn't a MIME type problem.
The issue isn't that I'm concerned that Gambas can't open a "binary
file"...I don't expect it to of course. But if a user goes to Open a
File and (accidentally?) selects a binary file (it's not like you can
always tell only by filename in Linux) the IDE should produce a
read-able message, it shouldn't crash itself and it shouldn't be putting
a file that can't be opened on the Recent Files list. The "problem
file" was never "opened", so it should not be in "recent file" list
anyway. That's not in the user's sphere of responsibility.
Better yet: maybe Binary files and other types that can't be opened are
not shown on that file browser window. Filter out everything except
text / sources files if that's what "Open a File" can handle. Maybe in
the future on if I hit "Open a File" and I select a PNG file, Gambas
takes me to GIMP or whatever default image editor is installed. That
would be cool. But for now not crashing the IDE is probably main fix.
Again: I know it's not a HUGE issue, but one that wants to be looked at
to help keep the IDE stable even if the user selects a wrong file type
by accident in a file browser. If it happens on Home Welcome page there
are maybe other places it can happen inside the IDE. It would be a drag
if you went to add a file to a project, accidentally selected a binary
file and crashed the IDE with unsaved data. I haven't tried that
extensively.
Screenshot attached of what I see for modal error dialog. Once I hit
OK, IDE is gone. - But next time I open IDE that file is on Recent File
List.
-John
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Gambas3_Open_Binary_File_Open_Dialog.png
Type: image/png
Size: 10506 bytes
Desc: not available
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20210526/e340c34a/attachment-0001.png>
More information about the User
mailing list