Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

new line character between closing </div> and new tag is not preserved with jsoup-1.15.4 #1911

Closed
Reeniya opened this issue Mar 3, 2023 · 1 comment
Assignees
Labels
bug Confirmed bug that we should fix fixed
Milestone

Comments

@Reeniya
Copy link

Reeniya commented Mar 3, 2023

Hi,
We are trying to upgrade jsoup in our project from 1.11.3 to 1.15.4. We are seeing that the new line character is getting removed between </div> and next new tag.

For example:

Input: <div><br />The Hobbit</div><br /><p>The Movie</p>

with 1.11.3 the output of the html parser with prettyprint set to true:

<html>
 <head></head>
 <body>
  <div>
   <br>
   The Hobbit
  </div>
   <br>
  <p>The Movie</p>
 </body>
</html>

with 1.15.4 the output of the html parser with prettyprint set to true:

<html>
 <head></head>
 <body>
  <div>
   <br>
   The Hobbit
  </div><br>
  <p>The Movie</p>
 </body>
</html>

Issue to re-create: https://try.jsoup.org/~N_NBC-ZuLdJWLSWzpsBenr3129M

@jhy Please can you confirm if this an issue with jsoup-1.15.4 ? if not how do we ensure that we get similar output from the parser as we see in 1.11.3 version

Thanks....

@jhy jhy closed this as completed in 1119192 Mar 9, 2023
@jhy
Copy link
Owner

jhy commented Mar 9, 2023

Thanks, fixed.

@jhy jhy self-assigned this Mar 9, 2023
@jhy jhy added bug Confirmed bug that we should fix fixed labels Mar 9, 2023
@jhy jhy added this to the 1.16.1 milestone Mar 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Confirmed bug that we should fix fixed
Projects
None yet
Development

No branches or pull requests

2 participants