Skip to content

[Bug] Markdown paste not working for Latex expression #1274

@TangentH

Description

@TangentH

Is there an existing issue for this?

  • I have searched the existing issues

Are you using the latest Zotero and the latest plugin?

  • I have confirmed I'm using the latest Zotero and the latest plugin

Environment

  • OS: Windows 11 23H2
  • Zotero Version: 7.0.11
  • Plugin Version: 2.2.5

Describe the bug

Markdown paste does not seem to support Latex formulas very well, even if "Use enhanced Markdown paste" is turned on in the settings.
The effect is as shown in the figure below.
The unordered list is rendered normally, but the Latex formula cannot be rendered normally. I must manually specify this part of the area as a Math block using the magic key to render it normally.

Thanks a lot!

Image

Debug Output

[JavaScript Error: "The connection was refused when attempting to contact wss://stream.zotero.org/."]

[JavaScript Error: "WebSocket connection closed: 1006 "]

[JavaScript Error: "Passing a URI to Zotero.File.getContentsAsync() is deprecated -- use Zotero.HTTP.request() instead"]

[JavaScript Error: "Passing a URI to Zotero.File.getContentsAsync() is deprecated -- use Zotero.HTTP.request() instead"]

appName => Zotero, version => 7.0.11 (x64), os => Windows 11 22631, locale => zh-CN, extensions => Better Notes for Zotero (2.2.5, extension), Scite Zotero Plugin (V7+) (2.0.2, extension, disabled), Bionic for Zotero (0.1.0, extension, disabled), Ethereal Reference (1.3.8, extension, disabled), Notero (1.0.0, extension, disabled), Zotero 插件市场 (1.7.5, extension, disabled), Google Scholar Citation Count (4.1.1, extension, disabled), zotero-inspire (0.3.10, extension, disabled), Translate for Zotero (2.1.2, extension, disabled), Ethereal Style (5.3.9, extension, disabled), Zotero Attanger (1.2.9, extension, disabled)

(3)(+0013926): HTTP POST https://api.zotero.org/users/14204621/items succeeded with 200

(3)(+0000000): [ConcurrentCaller] Done with function (0/4 running, 0 queued)

(4)(+0000003): Tags haven't changed

(4)(+0000000): Relations have not changed for item 1/TFAM97ET

(4)(+0000001): Field 'dateAdded' has not changed

(4)(+0000000): Field 'dateModified' has not changed

(4)(+0000000): Note hasn't changed

(3)(+0000000): Saving to sync cache:

(3)(+0000001): [ "0": { "key": "TFAM97ET" "version": 29475 "library": { "type": "user" "id": 14204621 "name": "Titangent" "links": { "alternate": { "href": "https://www.zotero.org/titangent" "type": "text/html" } } } "links": { "self": { "href": "https://api.zotero.org/users/14204621/items/TFAM97ET" "type": "application/json" } "alternate": { "href": "https://www.zotero.org/titangent/items/TFAM97ET" "type": "text/html" } "up": { "href": "https://api.zotero.org/users/14204621/items/99QNFGMB" "type": "application/json" } } "meta": { "numChildren": 0 } "data": { "key": "TFAM97ET" "version": 29475 "parentItem": "99QNFGMB" "itemType": "note" "note": "<div data-schema-version="9">

    \n
  • \n<span style="color: rgb(51, 51, 51)">源分布有3个局部特征点 [f_1, f_2, f_3]。\n
  • \n
  • \n<span style="color: rgb(51, 51, 51)">目标分布有2个聚类中心 [c_1, c_2]。 通过OT算法(比如Sinkhorn算法)计算后,得到一个匹配矩阵 P: P = \begin{bmatrix} 0.2 & 0.8 \\ 0.5 & 0.5 \\ 0.7 & 0.3 \end{bmatrix}\n
  • \n
\n" "tags": [] "relations": {} "dateAdded": "2025-01-24T04:34:19Z" "dateModified": "2025-01-24T04:34:19Z" } } ]

(4)(+0000001): INSERT OR REPLACE INTO syncCache (libraryID, key, syncObjectTypeID, version, data) VALUES (?, ?, ?, ?, ?) [1, 'TFAM97ET', 3, 29475, '{"key":"TFAM97ET","version":29475,"library":{"type":"user","id":14204621,"name":"Titangent","links":{"alternate":{"href":"https://www.zotero.org/titangent","type":"text/html"}}},"links":{"self":{"href":"https://api.zotero.org/users/14204621/items/TFAM97ET","type":"application/json"},"alternate":{"href":"https://www.zotero.org/titangent/items/TFAM97ET","type":"text/html"},"up":{"href":"https://api.zotero.org/users/14204621/items/99QNFGMB","type":"application/json"}},"meta":{"numChildren":0},"data":{"key":"TFAM97ET","version":29475,"parentItem":"99QNFGMB","itemType":"note","note":"<div data-schema-version="9">

    \n
  • \n<span style="color: rgb(51, 51, 51)">源分布有3个局部特征点 [f_1, f_2, f_3]。\n
  • \n
  • \n<span style="color: rgb(51, 51, 51)">目标分布有2个聚类中心 [c_1, c_2]。 通过OT算法(比如Sinkhorn算法)计算后,得到一个匹配矩阵 P: P = \begin{bmatrix} 0.2 & 0.8 \\ 0.5 & 0.5 \\ 0.7 & 0.3 \end{bmatrix}\n
  • \n
\n","tags":[],"relations":{},"dateAdded":"2025-01-24T04:34:19Z","dateModified":"2025-01-24T04:34:19Z"}}']

(3)(+0000001): [ConcurrentCaller] All tasks are done

(4)(+0000003): Beginning DB transaction kj5Bblro

(4)(+0000001): Item 4140 has not changed

(4)(+0000000): Updating database with new library data

(4)(+0000000): UPDATE libraries SET version=?, storageVersion=? WHERE libraryID=? [29475, 29475, 1]

(4)(+0000001): UPDATE items SET version=29475 WHERE itemID IN (?) [4140]

(4)(+0000001): UPDATE items SET synced=1 WHERE itemID IN (?) [4140]

(4)(+0000002): Committed DB transaction kj5Bblro

(4)(+0000000): DELETE FROM syncCache WHERE ROWID IN (SELECT SC.ROWID FROM syncCache SC LEFT JOIN items O USING (libraryID, key, version) WHERE syncObjectTypeID=? AND SC.libraryID=? AND (O.libraryID IS NULL OR SC.version < O.version)) [3, 1]

(2)(+0000003): Failed: 0

(4)(+0000000): Unregistering notifier observer in notifier with id 'itemsUpload_yw'

(3)(+0000000): Done uploading items in library 1

(3)(+0000000): {}

(4)(+0000000): Upload result is 1

(4)(+0000001): Updating database with new library data

(4)(+0000000): Beginning DB transaction gitN4NsM

(4)(+0000000): UPDATE libraries SET lastSync=? WHERE libraryID=? [1737693263, 1]

(4)(+0000003): Committed DB transaction gitN4NsM

(3)(+0000000): Done syncing 我的文库

(4)(+0000001): REPLACE INTO version (schema, version) VALUES ('lastsync', ?) [1737693264]

(3)(+0000001): Starting file syncing

(3)(+0000000): Done with file syncing

(3)(+0000000): Starting full-text syncing

(3)(+0000000): Done with full-text syncing

(3)(+0000000): Done syncing

(3)(+0000001): Notifier.trigger('finish', 'sync', []) called [observers: 2]

(4)(+0000000): SELECT libraryID AS id FROM feeds WHERE refreshInterval IS NOT NULL AND ( lastCheck IS NULL OR (julianday(lastCheck, 'utc') + (refreshInterval/1440.0) - julianday('now', 'utc')) <= 0 )

(3)(+0000004): Running update for feeds:

(3)(+0000001): All feed updates done

(3)(+0000000): Scheduling next feed update

(4)(+0000000): SELECT ( CASE WHEN lastCheck IS NULL THEN 0 ELSE strftime('%s', lastCheck) + refreshInterval * 60 - strftime('%s', 'now') END ) AS nextCheck FROM feeds WHERE refreshInterval IS NOT NULL ORDER BY nextCheck ASC LIMIT 1

(3)(+0000000): Next feed check in 196 seconds

(3)(+0003071): WebSocket message: {"event":"topicUpdated","topic":"/users/14204621","version":29475}

(3)(+0000001): Library is already up to date

(3)(+0013317): Starting full-text content processor

(4)(+0000002): Registering notifier observer 'fulltext_pv' for [sync]

Anything else?

No response

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions