From f7d76bd40abd28317a8b20d6f88d3be4d53dfea7 Mon Sep 17 00:00:00 2001 From: Simon Charette Date: Sat, 15 Jul 2023 13:15:20 -0400 Subject: [PATCH] Remove unnecessary dependency on six. Remove the last remaining usag of it in VCR.testcase. --- setup.py | 1 - vcr/config.py | 6 ++---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/setup.py b/setup.py index e528492..49d7ddc 100644 --- a/setup.py +++ b/setup.py @@ -45,7 +45,6 @@ class PyTest(TestCommand): install_requires = [ "PyYAML", "wrapt", - "six>=1.5", "yarl", # Support for urllib3 >=2 needs Python >=3.10 # so we need to block urllib3 >=2 for Python <3.10 for now. diff --git a/vcr/config.py b/vcr/config.py index 3cf48f7..c8dc593 100644 --- a/vcr/config.py +++ b/vcr/config.py @@ -6,8 +6,6 @@ import types from collections import abc as collections_abc from pathlib import Path -import six - from . import filters, matchers from .cassette import Cassette from .persisters.filesystem import FilesystemPersister @@ -256,5 +254,5 @@ class VCR: def test_case(self, predicate=None): predicate = predicate or self.is_test_method - # TODO: Remove this reference to `six` in favor of the Python3 equivalent - return six.with_metaclass(auto_decorate(self.use_cassette, predicate)) + metaclass = auto_decorate(self.use_cassette, predicate) + return metaclass("temporary_class", (), {})