How to serach \n #853
Unanswered
kathimohan
asked this question in
Q&A
Replies: 1 comment 2 replies
-
Hi @kathimohan. This is a really interesting question, and thank you for identifying this bug. I'm working on a fix for the error, which occurs because there is no internal PDF representation of a "newline"; we just perceive newlines based on the distances between lines of text. I spent some time today trying to derive the implicit "position" of the newlines, but nothing felt quite right. So, for now, searching for newlines will just return a blank result set. I'm also working on some functionality related to your question here, which will provide a more convenient way to identify where newlines are: #852 |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Not able to find new line using search \n, Is there any way to find new new line and serach for \n
pattern_n = page.search(r"\n")
*** ValueError: min() arg is an empty sequence
pattern_n = page.search(r"\s")
*** ValueError: min() arg is an empty sequence
Beta Was this translation helpful? Give feedback.
All reactions