Project

General

Profile

Actions

Bug #37963

closed

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

Added by Hector Martin over 5 years ago. Updated about 5 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Target version:
-
% Done:

0%

Source:
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Pull request ID:
Crash signature (v1):
Crash signature (v2):

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.

Actions #1

Updated by Alfredo Deza over 5 years ago

  • Status changed from New to 12
Actions #2

Updated by Alfredo Deza over 5 years ago

  • Status changed from 12 to In Progress
Actions #3

Updated by Andrew Schoen about 5 years ago

  • Status changed from In Progress to Resolved
Actions

Also available in: Atom PDF