Skip Menu |

This queue is for tickets about the Finance-Bitcoin CPAN distribution.

Report information
The Basics
Id: 93524
Status: resolved
Priority: 0/
Queue: Finance-Bitcoin

People
Owner: Nobody in particular
Requestors: rafaeljose [...] zoho.com
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: (no value)
Fixed in: (no value)



Subject:
Date: Tue, 4 Mar 2014 17:48:05 -0300
To: <bug-Finance-Bitcoin [...] rt.cpan.org>
From: "Rafael Jose" <rafaeljose [...] zoho.com>
I’m unable to send variables as a parameter for btc values in the bitcoin api calls like sendfrom or move. It is just accepting hardcoded values when a BTC value is expected. The returned error is “500 Internal server error”
I saw your question on PerlMonks too. http://www.perlmonks.org/?node_id=1076924 Have you tried using: $api->call( 'sendfrom', $sender_account, $receiving_address, $btc+0, # add 0 to explicitly cast to a number 6 ); JSON has different types for numeric and string data. Perl doesn't. So the Perl JSON modules use all kinds of weird tricks to try to guess whether something that looks like a number is supposed to be encoded as a number or a string. Let me know if that works.
I've not head anything back about this issue, so I'm assuming this technique solved the problem. I've now documented this problem in the Finance::Bitcoin::API pod.
Released 0.902 including this documentation change.
Subject: Re: [rt.cpan.org #93524]
Date: Fri, 2 May 2014 15:34:14 -0300
To: <bug-Finance-Bitcoin [...] rt.cpan.org>
From: "Rafael Jose" <rafaeljose [...] zoho.com>
Yes, i managed to make it work by using the + 0 , seems to be some problem with Perl itself Thank You Show quoted text
-----Mensagem Original----- From: Toby Inkster via RT Sent: Wednesday, March 05, 2014 6:38 AM To: rafaeljose@zoho.com Subject: [rt.cpan.org #93524] <URL: https://rt.cpan.org/Ticket/Display.html?id=93524 > I saw your question on PerlMonks too. http://www.perlmonks.org/?node_id=1076924 Have you tried using: $api->call( 'sendfrom', $sender_account, $receiving_address, $btc+0, # add 0 to explicitly cast to a number 6 ); JSON has different types for numeric and string data. Perl doesn't. So the Perl JSON modules use all kinds of weird tricks to try to guess whether something that looks like a number is supposed to be encoded as a number or a string. Let me know if that works.