-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Improve "Invalid TValue" error message #4047
Copy link
Copy link
Closed
Labels
P1Priority of the issue for triage purpose: Needs to be fixed soon.Priority of the issue for triage purpose: Needs to be fixed soon.enhancementNew feature or requestNew feature or requestusabilitySmoothing user interaction or experienceSmoothing user interaction or experience
Metadata
Metadata
Assignees
Labels
P1Priority of the issue for triage purpose: Needs to be fixed soon.Priority of the issue for triage purpose: Needs to be fixed soon.enhancementNew feature or requestNew feature or requestusabilitySmoothing user interaction or experienceSmoothing user interaction or experience
Type
Fields
Give feedbackNo fields configured for issues without a type.
When throwing "Invalid TValue" runtime errors, we tell users which type they entered, but don't tell the user the type that is needed. We tell them their current type is wrong, but not the right type.
There are current 23 places we throw this error. Our most common is when calling a
GetGetter().The one I'm hitting at the moment:
machinelearning/src/Microsoft.ML.Data/Data/DataViewUtils.cs
Line 1128 in 45b6c43
Task:
To make this more actionable, we should tell the user which type is needed for the column type.