-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Closed
Labels
Type: DefectIncorrect behavior (e.g. crash, hang)Incorrect behavior (e.g. crash, hang)
Description
System information
| Type | Version/Name |
|---|---|
| Distribution Name | CentOS Linux |
| Distribution Version | 7 |
| Kernel Version | 3.10.0-1160.11.1.el7 |
| Architecture | x86_64 |
| OpenZFS Version | 2.0.6 and .7 |
Describe the problem you're observing
arcstat -p doesn't work with either version of python:
Describe how to reproduce the problem
$ /usr/bin/python3.6 /usr/bin/arcstat -p
time read miss miss% dmis dm% pmis pm% mmis mm% size c avail
Traceback (most recent call last):
File "/usr/bin/arcstat", line 521, in
main()
File "/usr/bin/arcstat", line 506, in main
print_values()
File "/usr/bin/arcstat", line 260, in print_values
sys.stdout.write(sep.join(fmt(col) for col in hdr))
TypeError: sequence item 1: expected str instance, float found
Also, arcstat without -p shows rounded values with only one significant figure when run with py2.7.
The rounding behavior changed in py3 (/ means FP division, and integer division is now //).
SamSirry and almightiest
Metadata
Metadata
Assignees
Labels
Type: DefectIncorrect behavior (e.g. crash, hang)Incorrect behavior (e.g. crash, hang)