goanda icon indicating copy to clipboard operation
goanda copied to clipboard

About log.Fatal()

Open habuka036 opened this issue 5 years ago • 3 comments

Hi there,

This library uses log.Fatal() in some codes despite that causes exit the program when failed to connect for OANDA API.

So, I want to suggest the error return to the caller instead of use log.Fatal().

Of cause, my suggestion has a big impact on the Interfaces of this library. Therefore I hope someone will come up with a good idea more than my suggestion.

Thank you for this great library,

Osamu

habuka036 avatar Jul 27 '20 01:07 habuka036

I originally forked this project for this reason, and intended on creating a PR with changes to error handling, but I ended up making far more changes than I anticipated and so didn't make the PR. I don't think I'm going to maintain my fork any more as I'm no longer using it but I'd be happy to revert my more extreme changes and see what you think about maybe merging it @AwolDes

stewi1014 avatar Aug 10 '20 21:08 stewi1014

@stewi1014 more than happy for you to put up a PR with any changes you've made. I haven't worked on this for awhile, but I'm glad people are finding it useful and forking the project :100:

AwolDes avatar Aug 10 '20 22:08 AwolDes

I cleaned up the git history and created #10 that should address this along with some other changes I made.

stewi1014 avatar Aug 15 '20 00:08 stewi1014

Closing this as the PR that addresses this issue has been merged. Thank you to all of those involved in the process!

jSydorowicz21 avatar Aug 26 '24 09:08 jSydorowicz21