Skip to content

Commit e458c67

Browse files
kt474beckykd
andauthored
Prepare release 0.40.0 (#2268)
* prepare release 0.40.0 * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> * Update release-notes/0.40.0.rst Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com> --------- Co-authored-by: Rebecca Dimock <66339736+beckykd@users.noreply.github.com>
1 parent 5088124 commit e458c67

File tree

6 files changed

+116
-101
lines changed

6 files changed

+116
-101
lines changed

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
# The short X.Y version
2828
version = ''
2929
# The full version, including alpha/beta/rc tags
30-
release = '0.39.0'
30+
release = '0.40.0'
3131

3232
# -- General configuration ---------------------------------------------------
3333

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ zip-safe = false
5050
root = "."
5151
write_to = "qiskit_ibm_runtime/VERSION.txt"
5252
version_scheme = "release-branch-semver"
53-
fallback_version = "0.39.0"
53+
fallback_version = "0.40.0"
5454

5555
[project]
5656
name = "qiskit-ibm-runtime"

release-notes/0.40.0.rst

Lines changed: 114 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,114 @@
1+
0.40.0 (2025-05-28)
2+
===================
3+
4+
New Features
5+
------------
6+
7+
- The following changes were made to support the upcoming
8+
`IBM Quantum platform migration <https://docs.quantum.ibm.com/migration-guides/classic-iqp-to-cloud-iqp>`__:
9+
10+
- A new channel type, ``ibm_quantum_platform``, has been introduced for service initialization (``QiskitRuntimeService()``).
11+
It joins the existing ``ibm_quantum`` (now deprecated) and ``ibm_cloud`` channels. By **default**,
12+
``ibm_quantum_platform`` is selected when no channel is specified. This new channel connects to the
13+
new IBM Quantum Platform API and is intended to replace ``ibm_cloud``. In the meantime, the ``ibm_cloud`` channel will redirect to the new
14+
API, but its continued use is discouraged.
15+
16+
- An ``instance`` value is **no longer required** for saving (:meth:`.QiskitRuntimeService.save_account`) or
17+
initializing (``QiskitRuntimeService()``) an account on the new platform (``ibm_quantum_platform``, and temporarily, ``ibm_cloud``
18+
channels). If an instance is not passed in, all instances will be checked when a backend is retrieved,
19+
(``service.backend("backend_name")``). If an instance is passed
20+
into :meth:`.QiskitRuntimeService.save_account`, or passed in
21+
during initialization, it will be used as the **default instance** when retrieving backends.
22+
The instance passed in at initialization will take **precedence** over the one saved in the account.
23+
24+
- Note that the IBM Cloud API Token (``token``) is required for saving
25+
(:meth:`.QiskitRuntimeService.save_account`) or
26+
initializing (``QiskitRuntimeService()``) an account on the new platform. It's treated as the account identifier
27+
and will unlock the resources associated with the account the token was created in. A list of tokens per account can be found `here <https://cloud.ibm.com/iam/apikeys>`__.
28+
Only one account per API token can be used. If you want to use multiple accounts, you must create multiple API tokens.
29+
30+
- The :meth:`.QiskitRuntimeService.backend` and :meth:`.QiskitRuntimeService.backends` methods have been
31+
updated to accept an ``instance`` passed in explicitly when retrieving backends:
32+
``service.backend(name="...", instance="...")``.
33+
34+
- New parameters, ``region``, and ``plans_preference``, have been added to the
35+
:class:`.QiskitRuntimeService` initializer and :meth:`.QiskitRuntimeService.save_account` method.
36+
These can be used to **prioritize** certain instances on the new platform
37+
(``ibm_quantum_platform``, and temporarily, ``ibm_cloud`` channels) without explicitly providing the CRN. In more detail:
38+
39+
- ``region``: Sets a region preference. ``us-east`` or ``eu-de``.
40+
- ``plans_preference``: Is a list of account types, ordered by preference. An instance of the first type in the list will be prioritized.
41+
42+
For example, if ``region`` is saved as ``us-east``, only instances from ``us-east`` will be checked. If ``plans_preference`` is set,
43+
the instances will be prioritized in the order given, so ``['Open', 'Premium']`` would prioritize all Open Plan instances, then all
44+
Premium Plan instances, and then the rest. Note that the plan names in ``plans_preference`` must exactly match the API names (case insensitive).
45+
46+
- The ``instance`` input parameter of :class:`.QiskitRuntimeService` has been extended to accept
47+
new input types for the ``ibm_quantum_platform`` and ``ibm_cloud`` channels.
48+
In addition to the IBM Cloud Resource Name (CRN), the instance **name** can now
49+
be passed in as the instance value.
50+
51+
- The :meth:`~.QiskitRuntimeService.instances` method has been extended to show all
52+
available instances associated to an account for the ``ibm_quantum_platform`` and ``ibm_cloud``
53+
channels, in addition to the already enabled ``ibm_quantum`` channel.
54+
55+
The following code snippets show the new usage patterns enabled by the changes described above
56+
(`2239 <https://github.com/Qiskit/qiskit-ibm-runtime/pull/2239>`__):
57+
58+
.. code-block:: python
59+
60+
# save account
61+
service = QiskitRuntimeService.save_account(
62+
# No channel needs to be specified, ibm_quantum_platform is the default
63+
token=token,
64+
region="eu-de", # Optional
65+
plans_preference=['Open',...], #Optional
66+
set_as_default=True #Optional
67+
)
68+
69+
# initialize account
70+
service = QiskitRuntimeService() # defaults to ibm_quantum_platform account
71+
service.backend(name="...") # picks instance based on saved preferences
72+
service.backend(name="...", instance="...") # can also explicity pass in an instance to use
73+
74+
# initialize account with instance
75+
service = QiskitRuntimeService(instance = "...") # sets instance as default instance
76+
service.backend(name="...") # only checks default instance, fails if the backend not in the instance
77+
service.backend(name="...", instance="...") # can still explicity pass in a different instance
78+
79+
# OR
80+
81+
# save account with instance
82+
service = QiskitRuntimeService.save_account(
83+
# No channel needs to be specified, ibm_quantum_platform is the default
84+
token=token,
85+
instance="..." # This will be the default instance
86+
region="us-east", # Optional
87+
plans_preference=['Open',...], #Optional
88+
set_as_default=True #Optional
89+
)
90+
91+
# initialize account
92+
service = QiskitRuntimeService() # defaults to ibm_quantum_platform account
93+
service.backend(name="...") # only checks saved default instance from save_account
94+
service.backend(name="...", instance="...") # can also explicity pass in an instance which takes precendence
95+
96+
# initializing account with instance works the same way
97+
service = QiskitRuntimeService(instance = "...") # sets instance as default instance, overrides instance from save_account
98+
service.backend(name="...") # only checks default instance, fails if the backend not in the instance
99+
service.backend(name="...", instance="...") # can still explicity pass in a different instance
100+
101+
- The ``private`` option under :class:`EnvironmentOptions` is now supported on the
102+
``ibm_cloud`` and ``ibm_quantum_platform`` channels (new IBM Quantum Platform). When this option
103+
is set to ``True``, the job will be returned without parameters, and results can only
104+
be retrieved once.
105+
106+
There is also a new :meth:`~.RuntimeJobV2.private` property that returns whether
107+
or not a job is private. (`2263 <https://github.com/Qiskit/qiskit-ibm-runtime/pull/2263>`__)
108+
109+
110+
Bug Fixes
111+
---------
112+
113+
- The call to :meth:`~.IBMBackend.defaults` in :meth:`~.IBMBackend.target` was removed
114+
because backend defaults are no longer used in the target generation. (`2261 <https://github.com/Qiskit/qiskit-ibm-runtime/pull/2261>`__)

release-notes/unreleased/2239.feat.rst

Lines changed: 0 additions & 90 deletions
This file was deleted.

release-notes/unreleased/2261.bug.rst

Lines changed: 0 additions & 2 deletions
This file was deleted.

release-notes/unreleased/2263.feat.rst

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)