On upgrading to 2.4.0, lines in application.properties which only have the pound/hash character (#), without a trailing space or comment, cause the next line to be skipped, and so the property to be ignored. I typically use these lines to make the file more readable.
I couldn't find anything in the docs suggesting this was intentional, and it is not the standard behavior of java.util.Properties, so it was unexpected (for me, at least) and took some time to track down.
The problem seems to be in the CharacterReader of OriginTrackedPropertiesLoader, specifically in skipComment.
The workaround is simple enough, of course (just add a space or comment after the pound). But it seems unexpected enough to either be a bug, or to merit clear documentation.
Comment From: markbigler
I think this issue has already been reported here: https://github.com/spring-projects/spring-boot/issues/24228.
Comment From: snicoll
That's right, closing as duplicate.