Skip to content
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

Switch amount data type from int to float? #1

Closed
joshskidmore opened this issue Jan 22, 2022 · 1 comment
Closed

Switch amount data type from int to float? #1

joshskidmore opened this issue Jan 22, 2022 · 1 comment

Comments

@joshskidmore
Copy link
Contributor

Currently, forx does't support amounts that aren't whole integers. For instance, forx btc usd -q .12 returns forx: error: argument -q: invalid int value: '.12'. Changing the type from int to float on line 72 in convert.py seems to resolve the issue, but I'm unsure of repercussions. I'm more than happy to submit a PR for this as well.

@Gbox4
Copy link
Owner

Gbox4 commented Jan 22, 2022

Nice catch, thanks! The change you suggested worked, not any repercussions as the -q value is only used when multiplying by the exchange rate.

@Gbox4 Gbox4 closed this as completed Jan 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants