Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: remove all deprecated code #1248

Merged
merged 11 commits into from
Sep 7, 2023

Conversation

mrossinek
Copy link
Member

@mrossinek mrossinek commented Sep 6, 2023

Summary

This commit removes all deprecated code. Even though this is done a bit earlier than originally announced under the Qiskit deprecation policy, we are taking this step now since this project has become part of a community effort.
As a direct consequence, new codeowners will soon join the team behind Qiskit Nature. Rather than handing over a codebase that includes pieces of code which need attention in the near future (and even continued support until then) we are removing these parts early.

As a consequence, if you still require parts of this code, we suggest you stick to Qiskit Nature 0.6 until you can transition based on the provided migration guides.

This commit also removes the deprecation utilities which are superseded by the ones provided by Qiskit directly (see qiskit.utils.deprecation). Thus, this PR closes #1196

Details and comments

  • add a release note with a prelude section to explain the above

This commit removes all deprecated code. Even though this is done a bit
earlier than originally announced under the Qiskit deprecation policy,
we are taking this step now since this project has become part of a
community effort.
As a direct consequence, new codeowners will soon join the team behind
Qiskit Nature. Rather than handing over a codebase that includes pieces
of code which need attention in the near future (and even continued
support until then) we are removing these parts early.

As a consequence, if you still require parts of this code, we suggest
you stick to Qiskit Nature 0.6 until you can transition based on the
provided migration guides.

This commit also removes the deprecation utilities which are superseded
by the ones provided by Qiskit directly (see qiskit.utils.deprecation).
Now that the old code covered by the migration guide is being removed,
doctest can no longer execute this code. Thus, this commit replaces the
doctest directives with simple code cells.
@mrossinek mrossinek marked this pull request as ready for review September 6, 2023 14:32
@mrossinek
Copy link
Member Author

This also closes #1169

@mrossinek mrossinek added this to the 0.7.0 milestone Sep 6, 2023
@mrossinek
Copy link
Member Author

Since there is too much to go through in detail in this PR, here are a few noteworthy details:

  • I removed the deprecation utils (see prior comments)
  • I removed all occurrences of opflow (this includes PauliSumOp)
  • I removed all factories and their usage
  • I removed the QubitConverter and all its usage
  • I removed the runtime module
  • I removed all the settings attributes which become unused as a result of all these removals
  • please have a look at the suggested prelude in the release note

@woodsp-ibm
Copy link
Member

What do you want to do about the AdaptVQE howto docs/howtos/adapt_vqe.rst It refers to settings that this removes. I get that it will also need to be updated around qiskit_algorithms but this PR removes some of what it refers to, so if we want it in sync with this then maybe update it here - and again for the algorithms change later.

@mrossinek
Copy link
Member Author

What do you want to do about the AdaptVQE howto docs/howtos/adapt_vqe.rst It refers to settings that this removes. I get that it will also need to be updated around qiskit_algorithms but this PR removes some of what it refers to, so if we want it in sync with this then maybe update it here - and again for the algorithms change later.

Nice catch! I did not think to look through the tutorials and how-tos for additional usage of settings or other removed aspects. Will do that now 👍

@mrossinek
Copy link
Member Author

I have pushed two additional changes:

  • removing all further usage of setting attributes which have been removed. Grepping for settings now only shows results for optimize_einsum and in the migration guides (where they should remain)

  • I removed the release note which was added in Remove the deprecated code stack from prior to version 0.5 #1142 because it is now obsolete

@mrossinek mrossinek merged commit db5c156 into qiskit-community:main Sep 7, 2023
15 checks passed
@mrossinek mrossinek deleted the remove-all-deprecated-code branch September 7, 2023 13:28
ialsina pushed a commit to ialsina/qiskit-nature that referenced this pull request Nov 17, 2023
* refactor: remove all deprecated code

This commit removes all deprecated code. Even though this is done a bit
earlier than originally announced under the Qiskit deprecation policy,
we are taking this step now since this project has become part of a
community effort.
As a direct consequence, new codeowners will soon join the team behind
Qiskit Nature. Rather than handing over a codebase that includes pieces
of code which need attention in the near future (and even continued
support until then) we are removing these parts early.

As a consequence, if you still require parts of this code, we suggest
you stick to Qiskit Nature 0.6 until you can transition based on the
provided migration guides.

This commit also removes the deprecation utilities which are superseded
by the ones provided by Qiskit directly (see qiskit.utils.deprecation).

* docs: remove doctest from migration guides

Now that the old code covered by the migration guide is being removed,
doctest can no longer execute this code. Thus, this commit replaces the
doctest directives with simple code cells.

* docs: add 0.7 prelude

* docs: add spelling exceptions

* docs: fix indent in release note

* fix: remove final occurrence of opflow

* lint: run black

* fix: remove final occurrences of removed setting attributes

* docs: removes a now obsolete release note

* fix: remove left over setting
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants