larsw opened a new issue, #3880: URL: https://github.com/apache/jena/issues/3880
### Change As far as I can tell, the `GraphUtils.exactlyOneProperty` function is only used correctly one place in the codebase (https://github.com/apache/jena/blob/4ddc739161c64434be91c2b47616cf38e0c404e3/jena-tdb1/src/main/java/org/apache/jena/tdb1/assembler/IndexAssembler.java#L61), the rest of the call sites assume that the function may actually return `false`, something it will never do; it will either return `true` or raise either `PropertyRequiredException` or `NotUniqueException`. I suggest that the function is marked as deprecated, and a new one named `assertExactlyOneProperty` is used instead (that returns void - or raises one of the two aformentioned exceptions), and use that one internally in the codebase instead. External consumers of the existing function should be told to stop using the current function and migrate to the new one. ### Are you interested in contributing a pull request for this task? Yes -- 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: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
