Zachary Ware <[email protected]> added the comment:
This is because you're trying to use the string's delimiting character (') in
the string itself, which won't work for fairly apparent reasons :). Try
removing the `f` prefix and see what happens.
You can get around this by using a triple-quoted string which will allow you to
use both quote characters within the string:
>>> blah = '"hi"'
>>> f'''{blah.strip('"')}'''
'hi'
----------
nosy: +zach.ware
resolution: -> not a bug
stage: -> resolved
status: open -> closed
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue38568>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com