Bug 485691

Summary: Ghostwriter crashes on launch
Product: [Applications] ghostwriter Reporter: İsmail <ismailsahillioglu>
Component: generalAssignee: megan.conkle
Status: RESOLVED FIXED    
Severity: crash CC: bertronika, brunopitrus, bugs.kde.org, bugzylittle, duncan_maclean, felix, freekdekruijf, GeoBaltz, kdedev, o.g.m.belleux, robviren, uriesk
Priority: NOR Keywords: qt6
Version: 24.02.2   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In: 24.07.80
Sentry Crash Report:
Attachments: coredumpctl info
coredumpctl info ghostwriter-24.02.2-1

Description İsmail 2024-04-17 19:08:14 UTC
SUMMARY
Ghostwriter crashes on launch no matter where it get launched (GUI or terminal).

STEPS TO REPRODUCE
1. Launch
2. 
3. 

OBSERVED RESULT
Crash on launch (segmentation fault).

EXPECTED RESULT
Launch as expected.

SOFTWARE/OS VERSIONS
Operating System: openSUSE Tumbleweed 20240416
KDE Plasma Version: 6.0.3
KDE Frameworks Version: 6.1.0
Qt Version: 6.7.0
Kernel Version: 6.8.6-1-default (64-bit)
Graphics Platform: X11
Processors: 12 × 11th Gen Intel® Core™ i5-11400H @ 2.70GHz
Memory: 7.5 GiB of RAM
Graphics Processor: Mesa Intel® UHD Graphics
Manufacturer: ASUSTeK COMPUTER INC.
System Version: 1.0

ADDITIONAL INFORMATION
Here is the terminal output when I launch it from terminal:

$ ghostwriter
No preferred fonts were found. Using system default...
QFont::fromString: Invalid description ',12,-1,5,400,0,0,0,0,0,0,0,0,0,0,1'
QFont::fromString: Invalid description ',12,-1,5,400,0,0,0,0,0,0,0,0,0,0,1'
Command "pandoc" is not available.
Command "multimarkdown" is not available.
Command "cmark" is not available.
Segmentation fault (core dumped)
Comment 1 George Baltz 2024-04-21 19:51:29 UTC
Created attachment 168760 [details]
coredumpctl info

Same problem here - openSUSE Tumbleweed, up to date.  Output from execution and `coredumpctl info`.
Comment 2 Christophe Marin 2024-05-11 14:54:27 UTC
*** Bug 485962 has been marked as a duplicate of this bug. ***
Comment 3 Duncan M 2024-05-15 22:26:09 UTC
Hello,

The same issue occurs for me as of last update.

App: Ghostwriter-24.02.2-1.fc40.x86_64 (I experience the same issue on 24.02.1-1 if that helps)
Distro: Fedora Linux 40 (up to date)
DE: Plasma 6.0.4-1.fc40
QT: 6.7.0-1.fc40
Kernel: Linux 6.8.9-300.fc40.x86_64
Video: Nvidia 550.78

The program closes with a segfault when launched from shortcut or command-line. However, the Flatpak (Flathub) does not crash for me. I have attached my coredump to provide what I can. Cheers.
Comment 4 Duncan M 2024-05-15 22:31:36 UTC
Created attachment 169517 [details]
coredumpctl info ghostwriter-24.02.2-1
Comment 5 Freek de Kruijf 2024-05-16 16:20:46 UTC
I have the same problem. Error messages:
Using pandoc version 3.1.13
Using multimarkdown version 6.7.0
Using cmark version 0.31.0
Segmentatiefout (geheugendump gemaakt)
Comment 6 Rod Biren 2024-05-25 01:32:01 UTC
Also getting an error at launch on a fresh opensuse install

```fish: Job 1, 'ghostwriter' terminated by signal SIGSEGV (Address boundary error)```
Comment 7 Olivier BELLEUX 2024-06-06 20:57:58 UTC
Same for leap 15.5

STEPS TO REPRODUCE
1. open konsole
2. launch ghostwriter
3. output : 
```
Using pandoc version 3.1.11.1
Command "multimarkdown" is not available.
Command "cmark" is not available.
```

SOFTWARE/OS VERSIONS
Operating System: openSUSE Leap 15.5
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.2.0
Qt Version: 6.7.1
Kernel Version: 5.14.21-150500.55.65-default (64-bit)
Graphics Platform: Wayland
Comment 8 Andreas G 2024-06-10 08:32:02 UTC
Same on Fedora 40
Comment 9 Andreas G 2024-06-19 08:16:17 UTC
(In reply to Andreas G from comment #8)
> Same on Fedora 40

works now on fedora 40 after an update today
Comment 10 Olivier BELLEUX 2024-06-19 12:59:30 UTC
Same on opensuse leap 15.6

Operating System: openSUSE Leap 15.6
KDE Plasma Version: 6.1.0
KDE Frameworks Version: 6.3.0
Qt Version: 6.7.1
Kernel Version: 6.4.0-150600.21-default (64-bit)
Graphics Platform: X11
Comment 11 Christophe Marin 2024-06-27 08:49:04 UTC
(In reply to Andreas G from comment #9)
> (In reply to Andreas G from comment #8)
> > Same on Fedora 40
> 
> works now on fedora 40 after an update today

Seems that's because Fedora switched it back to build with Qt5
Comment 12 megan.conkle 2024-07-05 18:54:43 UTC
Git commit 305b7d086220cf8991343aea0871206a08398762 by Megan Conkle.
Committed on 05/07/2024 at 18:53.
Pushed by wereturtle into branch 'master'.

Port to Qt6 and Remove QtFontAwesome

Completed the port to Qt6.  Qt5 support has been removed.
QtFontAwesome has also been removed and replaced with normal SVG icons.
This is due to a corner case where Qt could not find the Font Awesome
fonts when Qt was built from scratch. The port to Qt6 also has fixed
a crash on initial open that appeared recently under Qt5 mixed in
a Qt6 environment.

M  +4    -0    CHANGELOG.md

https://invent.kde.org/office/ghostwriter/-/commit/305b7d086220cf8991343aea0871206a08398762
Comment 13 megan.conkle 2024-07-07 01:39:28 UTC
Git commit ce0ff54cd800db0acc75e496f8789fea72f22ba5 by Megan Conkle.
Committed on 07/07/2024 at 01:38.
Pushed by wereturtle into branch 'master'.

Fix syntax highlighting with unicode characters

Applied yet another hacky fix to the syntax highlighting issue that keeps
cropping up with various combinations of unicode characters. Cross your fingers!

Also noticed a few other bugs happened to be fixed either by this change
or by previous refactoring during the port to Qt6.
Related: bug 487636, bug 482078, bug 475234

M  +5    -1    .gitignore
M  +3    -0    CHANGELOG.md
M  +2    -7    src/editor/markdowneditor.cpp
M  +70   -6    src/editor/markdownhighlighter.cpp
M  +3    -6    src/markdown/cmarkgfmapi.cpp
M  +2    -2    src/markdown/markdownnode.cpp
M  +15   -6    src/markdown/markdownnode.h
A  +604  -0    widgets.qss

https://invent.kde.org/office/ghostwriter/-/commit/ce0ff54cd800db0acc75e496f8789fea72f22ba5