Skip to content

[BUG] cbapi broken on Python 3.12 #328

@sim0nx

Description

@sim0nx

I am seeing this behaviour on:

  • OS: Ubuntu
  • Carbon Black Product: CB API
  • Python Version: 3.12

Describe the bug
Using cbapi breaks with an error while importing 'cbapi.six.moves'

Steps to Reproduce
Steps to reproduce the behavior (Provide a log message if relevant):

  1. Install Python 3.12
  2. Install cbapi
  3. import cbapi

Python 3.12.3 (main, Apr 10 2024, 05:33:47) [GCC 13.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import cbapi
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/user/venv/lib/python3.12/site-packages/cbapi/__init__.py", line 12, in <module>
    from cbapi.response.rest_api import CbEnterpriseResponseAPI, CbResponseAPI
  File "/home/user/venv/lib/python3.12/site-packages/cbapi/response/__init__.py", line 5, in <module>
    from .models import (
  File "/home/user/venv/lib/python3.12/site-packages/cbapi/response/models.py", line 17, in <module>
    from cbapi.six.moves import urllib
ModuleNotFoundError: No module named 'cbapi.six.moves'

Expected behavior
It should just work :-)

Could you please fix Python 3.12 compatibility

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions