-
Notifications
You must be signed in to change notification settings - Fork 91
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
undefined method `strip' for an instance of Hash #301
Comments
PETOSS-568 |
Thanks for raising an issue, a ticket has been created to track your request |
I believe I have figured this out! Documenting here as it may help others. The But that's not true. It returns a hash. And inside that is So this bug is fixed by changing: @api_client.accounting_api.get_accounts(@api_client.last_connection) To @api_client.accounting_api.get_accounts(@api_client.last_connection["id"]) Easy fix but fiendishly hard to debug. Hope this helps someone! |
Actually perhaps worth reopening as this is an easy documentation fix. |
After much, much, much debugging, while getting the mysterious error
undefined method
strip' for an instance of Hash` (btw, whoever decided to catch that error and print it out and carry on without providing the stack trace... I hope you take a good long look at yourself in the mirror some day)...I ended up diagnosing it as an issue with a parameter has being passed into
net/http
.The full stack trace:
This is happening because the
initheader
parameter passed tonet/http/header.rb
'sinitialize_http_header
method is:Notice
Xero-tenant-id
is a hash.initialize_http_header
then dutifully chokes on it because it expects string parameters:Haven't got a solution or workaround yet, but thought i'd put this here in case it helps someone. Will report back once I do have a solution, whatever it is.
The text was updated successfully, but these errors were encountered: