Project

General

Profile

Actions

Bug #46414

closed

ceph_volume_client.py: python 3.8 compatibility

Added by Dan van der Ster almost 4 years ago. Updated over 3 years ago.

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

0%

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

Description

Installing 15.2.1 on Ubuntu 20.04 yields this warning:

Setting up python3-cephfs (15.2.1-0ubuntu1) ...
/usr/lib/python3/dist-packages/ceph_volume_client.py:358: SyntaxWarning: "is not" with a literal. Did you mean "!="?
group_id = group_id if group_id is not 'None' else None
/usr/lib/python3/dist-packages/ceph_volume_client.py:381: SyntaxWarning: "is" with a literal. Did you mean "=="?
readonly = True if access_level is 'r' else False
/usr/lib/python3/dist-packages/ceph_volume_client.py:1102: SyntaxWarning: "is" with a literal. Did you mean "=="?
unwanted_access_level = 'r' if want_access_level is 'rw' else 'rw'

Make the suggested changes.


Related issues 1 (0 open1 closed)

Copied to Ceph - Backport #46536: octopus: ceph_volume_client.py: python 3.8 compatibilityResolvedNathan CutlerActions
Actions #1

Updated by Patrick Donnelly almost 4 years ago

  • Status changed from New to Fix Under Review
  • Assignee set to Dan van der Ster
  • Target version set to v16.0.0
  • Source set to Development
  • Pull request ID set to 34637
Actions #2

Updated by Patrick Donnelly almost 4 years ago

  • Subject changed from octopus: ceph_volume_client.py: python 3.8 compatibility to ceph_volume_client.py: python 3.8 compatibility
Actions #3

Updated by Dan van der Ster almost 4 years ago

  • Pull request ID changed from 34637 to 34974
Actions #4

Updated by Dan van der Ster almost 4 years ago

  • Description updated (diff)
Actions #5

Updated by Patrick Donnelly almost 4 years ago

  • Status changed from Fix Under Review to Pending Backport
Actions #6

Updated by Nathan Cutler almost 4 years ago

  • Copied to Backport #46536: octopus: ceph_volume_client.py: python 3.8 compatibility added
Actions #7

Updated by Nathan Cutler over 3 years ago

  • Status changed from Pending Backport to Resolved

While running with --resolve-parent, the script "backport-create-issue" noticed that all backports of this issue are in status "Resolved" or "Rejected".

Actions

Also available in: Atom PDF