From 38230c064bae11b0ec85df39adf85871326fbed0 Mon Sep 17 00:00:00 2001 From: ptristan Date: Mon, 8 Apr 2024 16:34:09 -0300 Subject: [PATCH 1/4] deprecate V1 --- qiskit_ibm_runtime/base_primitive.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/qiskit_ibm_runtime/base_primitive.py b/qiskit_ibm_runtime/base_primitive.py index bfa4b739e..1a5eeed55 100644 --- a/qiskit_ibm_runtime/base_primitive.py +++ b/qiskit_ibm_runtime/base_primitive.py @@ -271,6 +271,13 @@ def __init__( self._service: QiskitRuntimeService | QiskitRuntimeLocalService = None self._backend: Optional[BackendV1 | BackendV2] = None + issue_deprecation_msg( + "The primitives' version 1 has been deprecated", + "0.23.0", + "Please use the primitives' version 2. See the `V2 migration guide `_. for more details", + 3, + ) + if options is None: self._options = asdict(Options()) elif isinstance(options, Options): From 47d680eb5e3e33cb0c9d0b03d92cb069317a725d Mon Sep 17 00:00:00 2001 From: ptristan Date: Mon, 8 Apr 2024 16:40:30 -0300 Subject: [PATCH 2/4] linter fixes --- qiskit_ibm_runtime/base_primitive.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/qiskit_ibm_runtime/base_primitive.py b/qiskit_ibm_runtime/base_primitive.py index 1a5eeed55..00fa92ae9 100644 --- a/qiskit_ibm_runtime/base_primitive.py +++ b/qiskit_ibm_runtime/base_primitive.py @@ -272,9 +272,10 @@ def __init__( self._backend: Optional[BackendV1 | BackendV2] = None issue_deprecation_msg( - "The primitives' version 1 has been deprecated", + "The primitives' V1 has been deprecated", "0.23.0", - "Please use the primitives' version 2. See the `V2 migration guide `_. for more details", + "Please use the primitives' V2. See the `V2 migration guide " + "`_. for more details", 3, ) From b9973b0ee16840fc9a6263e30ff7f4b34d752d78 Mon Sep 17 00:00:00 2001 From: ptristan3 <44805021+ptristan3@users.noreply.github.com> Date: Mon, 8 Apr 2024 20:20:41 -0300 Subject: [PATCH 3/4] Update qiskit_ibm_runtime/base_primitive.py Co-authored-by: Kevin Tian --- qiskit_ibm_runtime/base_primitive.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qiskit_ibm_runtime/base_primitive.py b/qiskit_ibm_runtime/base_primitive.py index 00fa92ae9..fcf5ff937 100644 --- a/qiskit_ibm_runtime/base_primitive.py +++ b/qiskit_ibm_runtime/base_primitive.py @@ -272,7 +272,7 @@ def __init__( self._backend: Optional[BackendV1 | BackendV2] = None issue_deprecation_msg( - "The primitives' V1 has been deprecated", + "The Sampler and Estimator V1 primitives have been deprecated", "0.23.0", "Please use the primitives' V2. See the `V2 migration guide " "`_. for more details", From dd156abac6178bcb614e13b1f44335e5cc59f734 Mon Sep 17 00:00:00 2001 From: ptristan3 <44805021+ptristan3@users.noreply.github.com> Date: Mon, 8 Apr 2024 20:20:48 -0300 Subject: [PATCH 4/4] Update qiskit_ibm_runtime/base_primitive.py Co-authored-by: Kevin Tian --- qiskit_ibm_runtime/base_primitive.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qiskit_ibm_runtime/base_primitive.py b/qiskit_ibm_runtime/base_primitive.py index fcf5ff937..ff0b781c2 100644 --- a/qiskit_ibm_runtime/base_primitive.py +++ b/qiskit_ibm_runtime/base_primitive.py @@ -274,7 +274,7 @@ def __init__( issue_deprecation_msg( "The Sampler and Estimator V1 primitives have been deprecated", "0.23.0", - "Please use the primitives' V2. See the `V2 migration guide " + "Please use the V2 Primitives. See the `V2 migration guide " "`_. for more details", 3, )