Bug 446085 - Error after double clicking on .py file when is_executable is checked
Summary: Error after double clicking on .py file when is_executable is checked
Status: RESOLVED NOT A BUG
Alias: None
Product: dolphin
Classification: Applications
Component: general (show other bugs)
Version: 21.08.3
Platform: Manjaro Linux
: NOR normal
Target Milestone: ---
Assignee: Dolphin Bug Assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-11-25 18:53 UTC by Artur Rudenko
Modified: 2021-11-26 16:16 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Error window (22.29 KB, image/png)
2021-11-25 18:53 UTC, Artur Rudenko
Details
Python test file (152 bytes, text/x-python)
2021-11-26 14:01 UTC, Paul Worrall
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Artur Rudenko 2021-11-25 18:53:11 UTC
Created attachment 143941 [details]
Error window

SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. Create .py file
2. Set it as executable
3.  Try to open it by double clicking

OBSERVED RESULT
Unknown error code 100
execvp: Not a directory

EXPECTED RESULT
Executing (?) python file

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: Manjaro KDE 
(available in About System)
KDE Plasma Version: 5.23.3
KDE Frameworks Version: 5.88.0
Qt Version: 5.15-2

ADDITIONAL INFORMATION
Comment 1 Paul Worrall 2021-11-26 14:01:31 UTC
Created attachment 143967 [details]
Python test file

I followed your steps, creating the attached .py (a simple "Hello World" using PyQt5), but couldn't reproduce the error message, could you repeat the test with the attached file?
Comment 2 Artur Rudenko 2021-11-26 15:14:35 UTC
(In reply to Paul Worrall from comment #1)
> Created attachment 143967 [details]
> Python test file
> 
> I followed your steps, creating the attached .py (a simple "Hello World"
> using PyQt5), but couldn't reproduce the error message, could you repeat the
> test with the attached file?

Ah, missing shebang is the problem. Without "#!/usr/bin/env python3", looks like it is trying to run it as bash file, even if the file has .py extension