Thanks to visit codestin.com
Credit goes to github.com

Skip to content

qt4_editor/formlayout.py TypeError: float() argument must be a string or a number #1547

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

Merged
merged 1 commit into from
Jul 31, 2013

Conversation

mdboom
Copy link
Member

@mdboom mdboom commented Jul 31, 2013

Using matplotlib 1.2 within pyqt on Python 3.3 I receive

formlayout.py", line 343, in get
value = float(field.text())
TypeError: float() argument must be a string or a number

That does not happen under Python 2.7.
Modifying that line in backends/qt4_editor/formlayout.py by wrapping the field.text() into a str() like

value = float(str(field.text()))

solves this.

mdboom added a commit that referenced this pull request Jul 31, 2013
qt4_editor/formlayout.py TypeError: float() argument must be a string or a number
@mdboom mdboom merged commit e93059f into matplotlib:v1.3.x Jul 31, 2013
@mdboom mdboom deleted the qt4editor-formlayout-float-bug branch August 7, 2014 13:49
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

Successfully merging this pull request may close these issues.

1 participant