srielau commented on PR #58282: URL: https://github.com/apache/spark/pull/58282#issuecomment-5508975850
That lines up with my thinking as well. Sent from my iPhone On Sep 1, 2026, at 1:44 PM, Nicholas Chammas ***@***.***> wrote: [https://avatars.githubusercontent.com/u/1039369?s=20&v=4]nchammas left a comment (apache/spark#58282)<https://github.com/apache/spark/pull/58282#issuecomment-5500176000> Can you explain why simply allowing an exception to not use a subclass if none apply, is bad? It's a fine idea. My concern is about the mix of patterns we have across the project for structuring error conditions. I'm trying to constrain them so things stay as consistent as possible. I don't want to add a new pattern without having a plan to clean up some of the old ones; we already have conflicting conventions in use today, and things are incrementally getting worse. How about this updated proposal? When creating an error condition with an optional message (like a hint, suggestion, or similar): 1. If the condition is a top-level condition, make the optional message a sub-condition. e.g. CONDITION and CONDITION.WITH_HINT. 2. If the condition is a sub-condition, make the optional message a sibling condition. e.g. CONDITION.SUB and CONDITION.SUB_WITH_HINT. 3. Don't include _WITHOUT_HINT (or similar) in the name of any error condition. 4. Don't pass in empty strings to optional message parameters like hints or suggestions. Instead, create a sub-condition that always includes that message. If we agree on this approach, then I would be happy to see this PR merged. We can then update the error condition README with this guidance and, perhaps as a follow-up to SPARK-58824<https://issues.apache.org/jira/browse/SPARK-58824>, update existing conditions to follow it. — Reply to this email directly, view it on GitHub<https://github.com/apache/spark/pull/58282?email_source=notifications&email_token=AA22CFACB3ZGDRF26Q3ZJ4D5M4YJFA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTKNJQGAYTONRQGAYKM4TFMFZW63VHNVSW45DJN5XKKZLWMVXHJLDGN5XXIZLSL5RWY2LDNM#issuecomment-5500176000>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AA22CFHSR43E6PW3XM43KUT5M4YJFAVCNFSNUABEKJSXA33TNF2G64TZHMYTOMJWGU3DKOB3JFZXG5LFHM2TENBWGAYTINBRGKQXMAQ>. You are receiving this because you were mentioned.Message ID: ***@***.***> -- 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]
