qownnotes / scripts

QOwnNotes script repository
http://www.qownnotes.org
GNU General Public License v3.0
104 stars 79 forks source link

[BUG] The "YAML nested tags" script breaks formatting and causing text lost in preview #214

Closed kostoms closed 8 months ago

kostoms commented 10 months ago

Script name

yaml-nested-tags

Script authors

@r00tr4v3n

Expected behaviour

Expected behaviour: code blocks are not processed by YAML scripts.

Actual behaviour

When "YAML nested tags" script enabled, creating note with code block containing row "..." followed by any another row does lead to the issue preview being broken while YAML definitions not expected inside code blocks and contents of code blocks is expected to be shown as is.

Steps to reproduce

While having "YAML nested tags" script enabled, create note with contents like below and check preview (the row "..." followed by any another row does lead to the issue, this is not expected in the code block )

---
title: Try this with script "YAML nested tags" enabled

---

This is a test note

```sh
$ cat test.txt
...
$
```

Relevant log output in the Log panel

Expand ``` No specific debug ouput was observed ```

Information about the application, settings and environment

Expand QOwnNotes Debug Information =========================== Note, I've tried it in Windows as well ## General Info **Current Date**: `Wed Dec 27 18:50:58 2023` **Version**: `23.12.4` **Build date**: `Dec 27 2023` **Build number**: `1069` **Platform**: `linux` **Operating System**: `Armbian 23.11.1 jammy` **Build architecture**: `arm64` **Current architecture**: `arm64` **Release**: `Self-build` **Qt Version (build)**: `6.2.4` **Qt Version (runtime)**: `6.2.4` **Portable mode**: `no` **Settings path / key**: `/home/******/.config/PBE/QOwnNotes.conf` **Application database path**: `/home/******/.local/share/PBE/QOwnNotes/QOwnNotes.sqlite` **Application arguments**: `/home/******/bin/qownnotes` **Qt Debug**: `0` **Locale (system)**: `en_US` **Locale (interface)**: *empty* **Primary screen resolution**: `1920x1080` **Screen resolution(s)**: `1920x1080, 1920x1080` **Icon theme**: `Adwaita` **Notes in current note folder**: `13` **Calendar items**: `0` **Enabled scripts**: `39` ## Server Info **serverUrl**: *empty* **appIsValid**: `yes` **notesPathExists**: *empty* **serverVersion**: *empty* **appVersion**: *empty* ## Spellchecking **Enabled**: `false` **Selected language**: *empty* **Language codes**: *empty* **Language names**: *empty* **Application dictionaries path**: `/home/******/.local/share/PBE/QOwnNotes/dicts` ## Note folders **currentNoteFolderId**: `2` ### Note folder `default` **id**: `1` **isCurrent**: `no` **activeTagId**: `92` **localPath**: `/home/kostos/Notes` **remotePath**: `Notes` **cloudConnectionId**: `1` **isShowSubfolders**: `yes` **isUseGit**: `no` **allowDifferentNoteFileName**: `yes` **activeNoteSubFolder name**: *empty* **database file**: `/home/******/notes.sqlite` ### Note folder `QOwnNotes` **id**: `2` **isCurrent**: `yes` **activeTagId**: `-1` **localPath**: `/home/******/******/notes.QOwnNotes` **remotePath**: `notes.QOwnNotes` **cloudConnectionId**: `1` **isShowSubfolders**: `yes` **isUseGit**: `no` **allowDifferentNoteFileName**: `yes` **activeNoteSubFolder name**: `Permissions` **database file**: `/home/******/******/notes.QOwnNotes/notes.sqlite` Sorry too much info to obfuscate.. Deleting the rest
pbek commented 10 months ago

Can you please mention the authors of the script (like advised in the issue template). You will find the authors in the Script repository.

r00tr4v3n commented 10 months ago

The regex might need fixing, if it's just the "..." causing the issue.

github-actions[bot] commented 9 months ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 8 months ago

This issue was closed because it has been inactive for 14 days since being marked as stale.