You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
want to remove this zero byte for further string handling
insert both methods into the code:
a.replace(chr(0),'')
a.replace('\x00','')
try to exchange the chr(0) by '\x00' in the editor by CTRL-F ...(because 2nd statement is a bit faster)
full code disappears, can be recovered by CTRL-Z
Traceback
Traceback (most recent call last):
File "C:\Users\klaus.stolberg\AppData\Local\anaconda3\Lib\site-packages\spyder\widgets\findreplace.py", line 697, in replace_find_all
cursor.insertText(re_pattern.sub(replace_text, text))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\klaus.stolberg\AppData\Local\anaconda3\Lib\re\__init__.py", line 317, in _subx
template = _compile_repl(template, pattern)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\klaus.stolberg\AppData\Local\anaconda3\Lib\re\__init__.py", line 308, in _compile_replreturn _parser.parse_template(repl, pattern)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\klaus.stolberg\AppData\Local\anaconda3\Lib\re\_parser.py", line 1087, in parse_templateraise s.error('bad escape %s'% this, len(this)) fromNonere.error: bad escape \x at position 10
Hi @klausthenikolaus thank you for the report! Checking seems like this could be a duplicate of #21007 Could it be possible for you to update to a more recent Spyder version (>=5.5.0) and try again? Let us know if updating helps!
Description
What steps will reproduce the problem?
a.replace(chr(0),'')
a.replace('\x00','')
Traceback
Versions
Dependencies
The text was updated successfully, but these errors were encountered: