On macOS, renaming results in errors if the file name contains @
.
Anki 2.1.55 (f38c4e2f) Python 3.9.15 Qt 5.14.2 PyQt 5.14.1
Platform: macOS-12.6.1-x86_64-i386-64bit
Flags: frz=True ao=True sv=3
Add-ons, last update check: 2022-12-09 23:01:09
Möglicherweise beteiligte Erweiterungen: <U+2068>OpenInExternalEditorRenameDuplicate for ImageAudioVideo<U+2069>
Caught exception:
Traceback (most recent call last):
File "aqt.webview", line 562, in handler
File "aqt.editor", line 576, in <lambda>
File "/Users/ferophila/Library/Application Support/Anki2/addons21/1560623518/edit_insert_rename_duplicate.py", line 79, in <lambda>
editor.saveNow(lambda: func(editor, fname, type, field))
File "/Users/ferophila/Library/Application Support/Anki2/addons21/1560623518/rename.py", line 133, in rename
cnt = _replace_all_img_src(ep, fname, new_filename)
File "/Users/ferophila/Library/Application Support/Anki2/addons21/1560623518/rename.py", line 64, in _replace_all_img_src
op_chg_cnt = mw.col.backend.find_and_replace(
File "anki._backend_generated", line 1554, in find_and_replace
File "anki._backend", line 148, in _run_command
anki.errors.InvalidInput: <pre>regex parse error:
(?i)(?P<first><img[^>]* src=)(?:"Bildschirmfoto\ 2022\-12\-08\ at\ 22\.54\.07@2x\.png")|(?:'Bildschirmfoto\ 2022\-12\-08\ at\ 22\.54\.07@2x\.png')(?P<second>[^>]*>)
^^
error: unrecognized escape sequence</pre>