lensvol / pybetter

Tool for fixing trivial problems with your code.
MIT License
62 stars 6 forks source link

Fix another edge case with triple quotes and prefix containing 'r'. #64

Closed lensvol closed 3 years ago

lensvol commented 3 years ago

Closes #62

Interestingly enough this also triggers a bug in the current LibCST (0.3.16) - rf"""Hello, world""" is a valid string in Python, but trips internal validation inside LibCST.

codecov[bot] commented 3 years ago

Codecov Report

Merging #64 (ffd9486) into master (660d71b) will not change coverage. The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master      #64   +/-   ##
=======================================
  Coverage   78.22%   78.22%           
=======================================
  Files          14       14           
  Lines         427      427           
=======================================
  Hits          334      334           
  Misses         93       93           
Impacted Files Coverage Δ
pybetter/transformers/empty_fstring.py 100.00% <ø> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 660d71b...ffd9486. Read the comment docs.

Zac-HD commented 3 years ago

Interestingly enough this also triggers a bug in the current LibCST (0.3.16) - rf"""Hello, world""" is a valid string in Python, but trips internal validation inside LibCST.

It would be great to report that upstream, especially if you can put together a simple reproducing example 😄

lensvol commented 3 years ago

Sure, I just did not get to do that yet :)