Project

General

Profile

Bug #37963

ceph-volume lvm prepare --dmcrypt raises TypeError (py3)

Added by Hector Martin 4 months ago. Updated 4 months ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
01/18/2019
Due date:
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:

Description

Using Python 3.6.5 and Ceph 13.2.4:

# ceph-volume lvm prepare --bluestore --data rootvg/osd-test --dmcrypt --no-systemd
Running command: /usr/bin/ceph-authtool --gen-print-key
Running command: /usr/bin/ceph-authtool --gen-print-key
--> TypeError: integer argument expected, got float

Bug is here: https://github.com/ceph/ceph/blob/master/src/ceph-volume/ceph_volume/util/encryption.py#L26 - that needs to be // (works in both Python 2 and 3 for truncating division).

Might be worth auditing all of the Python codebase for division that should be integer instead of float, and/or adding from __future__ import division to all modules so that the behavior is consistent between both Python versions.

History

#1 Updated by Alfredo Deza 4 months ago

  • Status changed from New to Verified

#2 Updated by Alfredo Deza 4 months ago

  • Status changed from Verified to In Progress

#3 Updated by Andrew Schoen 4 months ago

  • Status changed from In Progress to Resolved

Also available in: Atom PDF