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

Fix repeated plots in docs #13635

Merged
merged 1 commit into from
Jan 8, 2025
Merged

Fix repeated plots in docs #13635

merged 1 commit into from
Jan 8, 2025

Conversation

ElePT
Copy link
Contributor

@ElePT ElePT commented Jan 8, 2025

Summary

The use of :context: in pages with several plots was causing an accumulation of figures, this PR fixes this issue by adding :context: close-figs. For example, the grover_operator docs before this PR showed:
Screenshot 2025-01-08 at 17 37 30

While after the fix there is only one figure per snippet (as expected):

Screenshot 2025-01-08 at 17 36 34

Details and comments

@ElePT ElePT requested a review from a team as a code owner January 8, 2025 16:39
@qiskit-bot
Copy link
Collaborator

One or more of the following people are relevant to this code:

  • @Cryoris
  • @Qiskit/terra-core
  • @ajavadia

@ElePT ElePT mentioned this pull request Jan 8, 2025
@ElePT ElePT added documentation Something is not clear or an error documentation Changelog: None Do not include in changelog labels Jan 8, 2025
@ElePT ElePT added this to the 2.0.0 milestone Jan 8, 2025
@coveralls
Copy link

Pull Request Test Coverage Report for Build 12675002826

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • 9 unchanged lines in 2 files lost coverage.
  • Overall coverage decreased (-0.004%) to 88.94%

Files with Coverage Reduction New Missed Lines %
crates/qasm2/src/lex.rs 3 92.73%
crates/qasm2/src/parse.rs 6 97.62%
Totals Coverage Status
Change from base Build 12670558519: -0.004%
Covered Lines: 79442
Relevant Lines: 89321

💛 - Coveralls

Copy link
Member

@jakelishman jakelishman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, in some ways I'm surprised that this is the default behaviour. I guess I can just about see the purpose if you're showing how a plot builds up in the matplotlib documentation, but for most uses, it seems like close-figs should be the default.

@jakelishman jakelishman enabled auto-merge January 8, 2025 17:12
@jakelishman jakelishman added this pull request to the merge queue Jan 8, 2025
Merged via the queue into Qiskit:main with commit 8b2f6bd Jan 8, 2025
19 checks passed
@ElePT
Copy link
Contributor Author

ElePT commented Jan 9, 2025

@Mergifyio backport stable/1.4

Copy link
Contributor

mergify bot commented Jan 9, 2025

backport stable/1.4

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jan 9, 2025
@ElePT
Copy link
Contributor Author

ElePT commented Jan 9, 2025

@Mergifyio backport stable/1.3

Copy link
Contributor

mergify bot commented Jan 9, 2025

backport stable/1.3

✅ Backports have been created

mergify bot pushed a commit that referenced this pull request Jan 9, 2025
github-merge-queue bot pushed a commit that referenced this pull request Jan 9, 2025
(cherry picked from commit 8b2f6bd)

Co-authored-by: Elena Peña Tapia <57907331+ElePT@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Changelog: None Do not include in changelog documentation Something is not clear or an error documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants