Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork11.9k
ENH: better error message for invalid axis and concatenate inputs#4926
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
juliantaylor commentedJul 30, 2014
if we put the functions in the header or the API we could also use it for the ufunc axis arguments. There are probably also a few more places to put this. the concatenate error message as confused me alot when I started using numpy, just remembered the pain with the report :) so I'd like to put it into 1.9 so a non API approach is probably better. |
the old errorsnp.concatenate(1,2)TypeError: object of type 'int' has no len()concatenate([1], [2])TypeError: an integer is requiredare not very unhelpful, add a new internal function that allows addingsome context to axis argument conversion failures and check for sequenceinputs in concatenate.Closesnumpygh-4923.
ENH: better error message for invalid axis and concatenate inputs
charris commentedAug 4, 2014
Thanks Julian. |
juliantaylor commentedAug 4, 2014
ok for 1.9? |
charris commentedAug 4, 2014
That's up to you, but I don't think it is needed. |
ENH: better error message for invalid axis and concatenate inputs
juliantaylor commentedAug 4, 2014
added, I think its a significant usability improvement of the function |
the old errors
np.concatenate(1,2)
TypeError: object of type 'int' has no len()
concatenate([1], [2])
TypeError: an integer is required
are not very helpful, add a new internal function that allows adding
some context to axis argument conversion failures and check for sequence
inputs in concatenate.
Closesgh-4923.