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 our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ENH - make some of the code more robust for string input #2383
base: master
Are you sure you want to change the base?
Conversation
You should test whether your modifications do not break anything. When outside the DCCN, please consider testing: test_yorkinstruments, test_bug2511, test_bug2370, test_bug1818 When inside the DCCN, please also consider testing: test_bug2170, test_bug2511, test_bug3438, test_curry, test_bug1833, test_bug2419, test_bug1914, test_bug2888, test_pull1826, test_bug2385, test_pull2183, test_bug2232, test_fileformat_asa, test_bug3042, test_yorkinstruments, test_bug3027, test_issue1991, test_pull1248, test_bug1427, test_bug1924, test_bug1818, test_issue1992 Suggested tests outside the DCCN use public data or do not use data. |
@robertoostenveld this fixes an old issue. I was wondering whether we should build an option into ft_checkconfig (by default to be 'no', which converts any strings into chars). This could be part of ft_default (e.g. ft_default.checkchar). I think that the overhead in ft_checkconfig would be minimal, and at least it captures all occurrences of "" in the cfg ' s |
do we have any use cases where we expect people to specify strings? I don't think so. Why would the default for cfg.checkchar be 'no', would we not in general want to convert strings to chars? And should it be |
My expectations are not too high here. I think that @mjcourte used a string in the original issue report. Not sure whether current generations of Matlab users use strings and char intermixed.
Well, I was thinking that it would create a little bit of extra overhead, but I don't mind defaulting to 'yes'
Yes, well that's a good point. checkstring would be more appropriate |
Regarding enabling it by default: if it is not enabled by default, chances are very high that people will encounter the problem (when they specify a string as value) and not find the solution themselves. The documentation in ft_defaults is quite sparse, and when people call ft_whatever it is unlikely that they'll even consider the relevance of ft_defaults. |
Yes, all good. Do I have permission to proceed? :) |
Yes, pleas go ahead! |
No description provided.