Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #87392 > unrolled thread

Re: Odd ValueError using float

Started byemile <emile@fenx.com>
First post2015-03-13 15:44 -0700
Last post2015-03-13 15:44 -0700
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Odd ValueError using float emile <emile@fenx.com> - 2015-03-13 15:44 -0700

#87392 — Re: Odd ValueError using float

Fromemile <emile@fenx.com>
Date2015-03-13 15:44 -0700
SubjectRe: Odd ValueError using float
Message-ID<mailman.341.1426286670.21433.python-list@python.org>
On 03/13/2015 03:14 PM, Chris Angelico wrote:
> On Sat, Mar 14, 2015 at 9:10 AM, emile <emile@fenx.com> wrote:
>> (Pdb) decval
>> '4'
>> (Pdb) len(decval)
>> 1
>> (Pdb) int(decval)
>> *** ValueError: invalid literal for int() with base 10: '41.700000000000003'
>> (Pdb)
>>
>>
>> Any ideas?
>
> What's type(decval) tell you? I suspect you may have something other
> than a string, even though it looks like a string in its repr.

 >sigh<   Now it's running again.  Up to 20 minutes ago when I posted it 
continually.

Is-it-time-to-go-pick-grapes-yet?-ly y'rs,

Emile


[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web