Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
121 changes: 121 additions & 0 deletions .github/workflows/ISSUE_TEMPLATE/bug_report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,121 @@
name: "🐛 Bug Report"
description: "Report a bug or unexpected behavior in cqlib"
title: "[BUG] "
labels: ["bug", "triage"]
body:
- type: markdown
attributes:
value: |
**Thank you for reporting a bug!**

Before submitting:
- Search [existing issues](https://github.com/cq-lib/cqlib/issues) to avoid duplicates
- Security vulnerabilities → email <tianyan@chinatelecom.cn> (see [SECURITY.md](SECURITY.md))

- type: input
id: version
attributes:
label: "cqlib version"
description: "Run `pip show cqlib` or check `cargo.toml`"
placeholder: "e.g. 0.1.0, commit a1b2c3d"
validations:
required: true

- type: dropdown
id: component
attributes:
label: "Which component?"
options:
- "cqlib-core (Rust core)"
- "binding-python (Python bindings)"
- "binding-c (C bindings)"
- "cqlib (public Rust crate)"
- "Other / Not sure"
validations:
required: true

- type: textarea
id: environment
attributes:
label: "Environment"
description: "OS, architecture, Rust version, Python version"
placeholder: |
- OS: Ubuntu 22.04 / macOS 14 / Windows 11
- Architecture: x86_64 / ARM64
- Rust: 1.85.0
- Python: 3.12.0
render: markdown
validations:
required: true

- type: textarea
id: steps
attributes:
label: "Steps to reproduce"
description: "Minimal code to reproduce the bug"
placeholder: |
**Python:**
```python
from cqlib import Circuit
qc = Circuit(2)
qc.h(0)
qc.cx(0, 1)
# bug happens here
```

**Rust:**
```rust
use cqlib_core::circuit::{Circuit, Qubit};
let mut qc = Circuit::new(2);
// bug happens here
```

**C:**
```c
#include <cqlib/circuit.h>
cqlib_circuit_t *qc = cqlib_circuit_new(2);
// bug happens here
```
render: markdown
validations:
required: true

- type: textarea
id: expected
attributes:
label: "Expected behavior"
placeholder: "What did you expect to happen?"
validations:
required: true

- type: textarea
id: actual
attributes:
label: "Actual behavior"
placeholder: "What actually happened? Include full error messages, logs, or stack traces."
render: text
validations:
required: true

- type: textarea
id: quantum_context
attributes:
label: "Quantum-specific context (if applicable)"
description: "For issues related to simulation, noise, or numerical computation"
placeholder: |
- Input circuit / gates
- Parameters used (theta, random seed, etc.)
- Simulator / backend configuration
- Noise model parameters
- Expected vs actual tolerance / precision
render: markdown
validations:
required: false

- type: textarea
id: additional
attributes:
label: "Additional context"
placeholder: "Screenshots, related issues, workarounds tried, etc."
validations:
required: false
11 changes: 11 additions & 0 deletions .github/workflows/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
blank_issues_enabled: false
contact_links:
- name: "\uD83D\uDCAC Ask a question in Discussions"
url: https://github.com/cq-lib/cqlib/discussions
about: "Please use Discussions for general questions and community conversation"
- name: "\uD83D\uDCD6 Read the documentation"
url: https://qc.zdxlz.com/
about: "Check the official cqlib documentation before opening an issue"
- name: "\u270D\uFE0F Contribution guide (\u4E2D\u6587)"
url: https://github.com/cq-lib/cqlib/blob/main/CONTRIBUTING.CN.md
about: "Read the contributing guide before submitting code"
85 changes: 85 additions & 0 deletions .github/workflows/ISSUE_TEMPLATE/feature_request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
name: "\U0001F680 Feature Request"
description: "Suggest a new feature or enhancement for cqlib"
title: "[FEATURE] "
labels: ["enhancement", "triage"]
body:
- type: markdown
attributes:
value: |
**Thank you for suggesting a feature!**

Before submitting:
- Search [existing issues](https://github.com/cq-lib/cqlib/issues) to check if this has already been proposed
- Major API changes should be discussed in an Issue first (see [CONTRIBUTING.md](CONTRIBUTING.md))

- type: textarea
id: problem
attributes:
label: "Problem statement"
description: "What problem does this feature solve? Describe your use case."
placeholder: "E.g., I want to run VQE on custom Hamiltonians but the current API requires..."
validations:
required: true

- type: dropdown
id: area
attributes:
label: "Which area does this affect?"
multiple: true
options:
- "Circuit Construction"
- "Intermediate Representation (IR / Optimization)"
- "Compiler Passes (gate decomposition / routing / scheduling)"
- "Device Model (calibration / topology / noise)"
- "Simulation (state vector / noise model)"
- "Error Mitigation (ZNE / Virtual Distillation)"
- "Visualization"
- "Python Bindings"
- "C Bindings"
- "Documentation / Examples"
validations:
required: true

- type: textarea
id: proposal
attributes:
label: "Proposed solution"
description: "Describe what you would like to see. Code snippets or pseudo-code are welcome."
placeholder: |
```python
# Example of how the API might look
from cqlib import Circuit, VQE

qc = Circuit(4)
...
result = VQE(qc, hamiltonian).run()
```
render: markdown
validations:
required: true

- type: textarea
id: alternatives
attributes:
label: "Alternatives considered"
description: "What workarounds have you tried? Are there existing libraries that solve this?"
validations:
required: false

- type: checkboxes
id: scope
attributes:
label: "Scope check"
options:
- label: "This is within cqlib's scope (quantum computing SDK: circuits, IR, compilation, simulation, error mitigation)"
required: false
- label: "I am willing to contribute a PR for this feature"
required: false

- type: textarea
id: additional
attributes:
label: "Additional context"
placeholder: "References, papers, similar features in other frameworks (Qiskit, Cirq, PennyLane, etc.)"
validations:
required: false
60 changes: 60 additions & 0 deletions .github/workflows/ISSUE_TEMPLATE/question.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
name: "\u2753 Question"
description: "Ask a question about using cqlib"
title: "[QUESTION] "
labels: ["question", "triage"]
body:
- type: markdown
attributes:
value: |
**Welcome!** This template is for usage questions, troubleshooting help, and general inquiries.

Before asking:
- Check the [README](README.md) and [documentation](https://qc.zdxlz.com/)
- Search [existing questions](https://github.com/cq-lib/cqlib/issues?q=label%3Aquestion)

- type: dropdown
id: topic
attributes:
label: "What is your question about?"
options:
- "Installation / Build"
- "API Usage"
- "Quantum Computing Theory"
- "Performance / Optimization"
- "Documentation"
- "Other"
validations:
required: true

- type: textarea
id: question
attributes:
label: "Your question"
description: "Describe what you are trying to do and what you need help with."
placeholder: |
I am trying to...
I have read / tried...
I expected..., but got...
validations:
required: true

- type: textarea
id: code
attributes:
label: "Relevant code (if applicable)"
description: "Paste the code or circuit you are working with."
render: markdown
validations:
required: false

- type: textarea
id: context
attributes:
label: "Environment"
description: "If relevant: cqlib version, OS, Python/Rust version"
placeholder: |
- cqlib version: 0.1.0
- Python: 3.12.0
- OS: Ubuntu 22.04
validations:
required: false
21 changes: 21 additions & 0 deletions .github/workflows/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!--
Before submitting:
- Read the [Contributing Guide](CONTRIBUTING.md)
- Run tests: `cargo test --all` and `pytest tests/python/`
- Run lints: `cargo fmt --check`, `cargo clippy`, `ruff check`
-->

## Description

<!-- Briefly describe what this PR does and why. -->

## Related Issues

<!-- Closes #123 | Related to #456 -->

## Checklist

- [ ] I have read the [Contributing Guide](CONTRIBUTING.md)
- [ ] Lints and tests pass locally
- [ ] I have added tests that prove my fix/feature works
- [ ] I have updated documentation as needed
Loading