richardstartin commented on PR #10044: URL: https://github.com/apache/pinot/pull/10044#issuecomment-1373383973
> > I think @klsince's question needs addressing - what happens when there are two invalid UTF8 sequences at the mismatch, can we return 0 spuriously, I'll address that before merging. > > Could that ever happen? All the UTF-8 are encoded from strings. It can’t happen because at the very least the parameter came from the query layer as a string. I can’t think of a way to break this logic except when the behaviour is undefined for the string class itself. When I first implemented a simpler version of this, a lot of test cases elsewhere in Pinot failed, even after my own tests which generated a comprehensive range of UTF8 sequences was passing, so the test suite is quite sensitive to this change, and is passing now. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@pinot.apache.org For additional commands, e-mail: commits-h...@pinot.apache.org