How to Contribute to Open Source: My Journey from a Qiskit GitHub Issue to a Merged Pull Request
How to Contribute to Open Source: My Qiskit GitHub Issue to Merged Pull Request Journey

Introduction
One of the most satisfying moments in open source is seeing your pull request marked as Merged.
For me, that moment came when my pull request to Qiskit was successfully merged into the main codebase. It was not my first open-source contribution, but it was a very meaningful one because it gave me a deeper understanding of how professional open-source collaboration works inside a large technical project.
This contribution started from a GitHub issue, moved through documentation improvements, maintainer feedback, test coverage, CI checks, and finally ended with a merged pull request.
Qiskit is an open-source software development kit for working with quantum computers. It provides tools for building, optimizing, and working with quantum circuits, operators, and quantum-computing primitives. For developers, researchers, educators and learners, Qiskit serves as one of the important bridges between quantum computing theory and practical quantum programming.
Contributing to Qiskit was not just about editing a few lines of documentation. It was about understanding a real issue, working inside a mature open-source codebase, respecting contribution guidelines, responding to maintainer feedback and improving something that future users may rely on.
My contribution focused on improving Qiskit’s arithmetic API documentation and adding related test coverage.
Screenshot of merged Qiskit pull request on GitHub
How I Found a Qiskit GitHub Issue to Work On
For many beginners, one of the hardest parts of contributing to open source is not writing the code. It is knowing where to start.
Open source can feel intimidating at first. You may see thousands of files, many open issues, active maintainers, labels you do not fully understand, and project workflows that look complex from the outside.
The best approach is not to start by trying to solve the biggest problem in the repository. A better approach is to look for issues that are already clear, scoped, and beginner-friendly.
While exploring the Qiskit GitHub repository, I searched through open issues and paid attention to labels and issue descriptions. Labels such as good first issue, help wanted and documentation-related labels can be helpful when you are trying to find an entry point into a project.
For beginners who want to contribute to open source, this is a practical way to start:
Search through the project’s open issues.
Look for issues with clear descriptions.
Pay attention to labels such as good first issue, help wanted or documentation.
Read the discussion carefully before making changes.
Check whether a maintainer has suggested a direction.
Choose an issue where you understand the problem well enough to explain it.
Start with a focused contribution instead of trying to change too many things at once.
That was how I found an issue related to Qiskit’s API documentation. It was not about building a new feature from scratch. It was about making existing documentation clearer and more accurate.
That kind of contribution is valuable because documentation is often the first place users go when they are trying to understand how an API works.
Why Documentation Contributions Matter in Open Source
At first, a documentation task may look simple but in a technical project like Qiskit, documentation is not just a side note.
Documentation is part of the product. Clear API documentation helps users understand how classes, gates, circuits and functions behave. If documentation is incomplete or inaccurate, users may misunderstand the API, use it incorrectly or spend extra time reading the source code to understand what should have been explained clearly.
This is very important in quantum computing, where concepts such as Pauli rotations, quantum gates, qubit ordering, and adder circuits can already be complex for many users. A small documentation improvement can make a real difference.
It can help a beginner understand a concept faster. It can help an experienced developer avoid confusion. It can help future contributors understand the purpose of a class, function or test.
My Qiskit contribution reminded me that documentation is engineering work. It requires accuracy, structure, clarity and attention to detail.
The Main Qiskit Concepts Involved
The issue I worked on involved Qiskit’s arithmetic API documentation, especially around:
PolynomialPauliRotationsPolynomialPauliRotationsGateHalfAdderGateRelated adder gate constructor documentation
Test coverage for X and Z basis cases
Before explaining the exact changes, it is useful to briefly explain these concepts in simple terms.
What is PolynomialPauliRotations?
PolynomialPauliRotations is a Qiskit circuit class used to apply Pauli rotations where the rotation angle is controlled by a polynomial function of the input state.
In simpler terms, it helps build a quantum circuit where the amount of rotation depends on a polynomial expression. If the input state represents a value, the circuit uses a polynomial function of that value to determine the rotation angle.
What is PolynomialPauliRotationsGate?
PolynomialPauliRotationsGate represents similar polynomial-controlled Pauli rotation behavior, but as a gate.
A gate is a reusable quantum operation that can be added to a quantum circuit. So while PolynomialPauliRotations is the circuit-style version, PolynomialPauliRotationsGate is the gate-style version used as a direct circuit instruction.
What is HalfAdderGate?
HalfAdderGate is a quantum arithmetic gate used to add two equally sized quantum registers and include a carry-out bit.
In classical computing, a half adder adds bits and produces a sum and a carry. In Qiskit’s quantum arithmetic API, HalfAdderGate follows a similar idea in a reversible quantum-circuit form. The carry-out bit matters because some additions require an extra bit to represent the final result.
Researching about these concepts helped me see why the documentation needed to be precise. These APIs are technical and users depend on the documentation to understand how the circuit or gate behaves.
What I Changed in the Qiskit Pull Request
My pull request focused on improving arithmetic API documentation and adding test coverage after maintainer review.
The main contributions included:
Clarifying the documentation for
PolynomialPauliRotationsandPolynomialPauliRotationsGate.Adding clearer descriptions for the
basis="X"andbasis="Z"cases.Improving the
HalfAdderGatedocumentation by explaining the clean|0⟩carry-out qubit.Explaining why the output sum register has
n + 1qubits.Removing outdated
nameparameter documentation from adder gate constructors that do not acceptname.Addressing maintainer feedback by removing wording that could make qubit-ordering explanation confusing.
Adding X/Z basis test coverage in
test_functional_pauli_rotations.py.Ensuring the new tests covered both
PolynomialPauliRotationsGateandPolynomialPauliRotations.
The work started as a documentation-focused pull request, but through review, it became stronger because it also included test coverage.
Improving PolynomialPauliRotations Documentation
One of the first parts of the contribution involved PolynomialPauliRotations and PolynomialPauliRotationsGate.
These classes support different Pauli rotation bases, including:
basis="X"basis="Y"basis="Z"
The previous documentation mainly described the default Y-basis behavior. Since the API also supports X and Z bases, I added clearer descriptions for the basis="X" and basis="Z" cases.
This made the documentation more complete because it better reflected what the API actually supports.
For users reading Qiskit’s API documentation, this kind of clarity matters. If an API supports multiple options, users should not have to inspect the implementation before understanding what those options mean.
Clarifying the HalfAdderGate Documentation
Another part of my contribution involved HalfAdderGate.
The goal was to make the carry-out behavior clearer. I improved the documentation by explicitly showing the clean |0⟩ input qubit and explaining that it stores the carry-out bit.
This matters because the output sum register has n + 1 qubits. Without explaining the role of the extra clean qubit, the mapping can be confusing for users trying to understand the gate behavior.
In quantum computing documentation, small wording details can make a big difference. A single sentence can help a user understand why a register has an extra qubit, how a gate behaves, or what a formula is trying to express.
Removing Outdated Parameter Documentation
I also removed outdated name parameter documentation from adder gate constructors that do not actually accept a name argument. This was a small but important cleanup.
Good API documentation should match the real code. If a constructor does not accept a parameter, the documentation should not list that parameter. Otherwise, users may try to use an argument that does not exist and run into avoidable errors.
This reminded me that documentation improvement is not only about adding new explanations. Sometimes, it is also about removing inaccurate or outdated information.
Responding to Maintainer Feedback
After opening the pull request, I received feedback from a Qiskit maintainer. One of the comments pointed out that a paragraph I added to explain qubit ordering could make the documentation more confusing instead of clearer. The maintainer suggested removing it. That feedback was important.
It reminded me that technical writing is not about adding more words. It is about adding the right words. Sometimes, the best documentation improvement is knowing what to remove so I removed the confusing explanation.
The maintainer also requested tests for the X and Z basis cases, especially because the documentation now mentioned those cases more directly. That changed the scope of the pull request. The PR was no longer only a documentation update. It now needed test coverage too.
Qiskit maintainer feedback requesting test coverage for X and Z basis cases
Adding Test Coverage for X and Z Basis Cases
To address the review feedback, I added tests in test_functional_pauli_rotations.py.
The new tests covered the X and Z basis cases for both:
PolynomialPauliRotationsGatePolynomialPauliRotations
This made the contribution stronger because the newly documented behavior was now backed by test coverage.
That was one of the biggest lessons from the process: when documentation describes behavior publicly, tests help protect that behavior. Documentation tells users what to expect. Tests help ensure the project continues to meet that expectation.
Passing CI and Getting the Pull Request Merged
After updating the code, I pushed the changes, updated the pull request description, and replied to the maintainer explaining what I had done.
Then came the waiting process.
The pull request needed review, CI checks and approval from the project maintainers.
Eventually, the PR passed 27 CI checks. It was approved, entered the merge queue, and was successfully merged into Qiskit’s main branch.
The contribution was also backported, which made the experience even more meaningful. It showed that the maintainers considered the change useful beyond only the main development branch.
Qiskit pull request passed 27 CI checks and was merged into main
Lessons for Beginners Who Want to Contribute to Open Source
This experience taught me that beginners do not need to start with massive code changes to contribute to open source. You can start small and still make meaningful contributions.
If you want to begin contributing to open source, here are some lessons from my experience:
Start by searching for beginner-friendly issues.
Use labels like good first issue, help wanted and documentation.
Read the issue carefully before commenting or making changes.
Choose an issue where you understand the expected improvement.
Do not underestimate documentation contributions.
Be ready to receive maintainer feedback.
Treat feedback as collaboration, not criticism.
If your documentation mentions behavior, be prepared to add tests when needed.
Keep your pull request focused.
Explain your changes clearly in the PR description.
Be patient while CI runs and maintainers review your work.
For beginners, documentation issues can be a great entry point because they help you understand the project without immediately needing to change complex internal logic. But documentation still requires careful reading, accuracy, and respect for the project’s standards.
A small contribution can become a serious learning experience when you approach it properly.
What This Open-Source Contribution Taught Me
This Qiskit contribution taught me several important lessons about open-source development.
First, documentation is engineering work. Clear documentation helps users trust and understand a project.
Second, tests make documentation stronger. If a behavior is important enough to document, it may also be important enough to test.
Third, maintainer feedback is not rejection. It is collaboration. The review process helped me improve the contribution and made the final PR better.
Fourth, open source is a learning environment. You do not need to know everything before contributing. You need patience, curiosity, attention to detail and the willingness to improve your work.
Finally, I learned that small contributions can still have real value. Improving a docstring, clarifying a parameter, or adding a focused test can help future users and contributors.
Why This Matters for My Technical Growth
This merged pull request is more than just a contribution link for me.
It is proof that I can:
Search for open-source issues.
Identify a suitable contribution opportunity.
Read and understand a real GitHub issue.
Work inside a large technical codebase.
Improve API documentation.
Respond to maintainer feedback.
Add relevant test coverage.
Follow open-source contribution standards.
Get a contribution merged into a major project.
That is a meaningful step in my growth as a technical contributor.
It also reminded me that open source is not only for people who already know everything. It is also for people who are willing to learn carefully, contribute thoughtfully, and improve through feedback.
Conclusion
My open-source contribution to Qiskit started with searching for a suitable GitHub issue and grew into a complete learning experience involving API clarity, quantum computing documentation, test coverage, code review, CI checks, and collaboration with maintainers.
Seeing the pull request merged into Qiskit’s main codebase was a proud moment.
It reminded me that learning becomes more powerful when it produces something useful for others.
I am grateful to the Qiskit maintainers for their review and guidance and I am excited to keep learning, building, and contributing to open source.
This is one contribution, but it is also part of a bigger journey.
About the author
- Gloria is a passionate web developer with a strong drive for creating intuitive, dynamic, and responsive web applications. Always eager to learn new technologies and improve coding skills, Gloria is dedicated to building seamless user experiences through clean and efficient code. Stay tuned for insights and tips on web development, shared from a developer’s perspective.
Comments
Join the discussionNo comments yet. Be the first to comment.



