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: split dev requirements out of main requirements.txt #467

Merged
Merged
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
6 changes: 2 additions & 4 deletions .github/workflows/python_format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@ jobs:
with:
python-version: '3.7'
architecture: 'x64'
- name: Install flynt
run: cat requirements.txt | grep flynt | xargs pip install
- name: Install black
run: cat requirements.txt | grep black | xargs pip install
- name: Install dev requirements
run: pip install -r dev-requirements.txt
- name: Format
run: check/format-incremental
1 change: 1 addition & 0 deletions .github/workflows/testing_wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ jobs:
CIBW_REPAIR_WHEEL_COMMAND_MACOS: ""
# due to package and module name conflict have to temporarily move it away to run tests
CIBW_BEFORE_TEST: "mv {package}/qsimcirq /tmp"
CIBW_TEST_EXTRAS: "dev"
CIBW_TEST_COMMAND: "pytest {package}/qsimcirq_tests/qsimcirq_test.py && mv /tmp/qsimcirq {package}"
steps:
- uses: actions/checkout@v2
Expand Down
1 change: 1 addition & 0 deletions MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
include requirements.txt
include dev-requirements.txt
include CMakeLists.txt

graft pybind_interface
Expand Down
3 changes: 3 additions & 0 deletions dev-requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
black==20.8b1
flynt~=0.60
pytest
6 changes: 6 additions & 0 deletions docs/install_qsimcirq.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ Prerequisites are included in the
[`requirements.txt`](https://github.com/quantumlib/qsim/blob/master/requirements.txt)
file, and will be automatically installed along with qsimcirq.

If you'd like to develop qsimcirq, a separate set of dependencies are includes
in the
[`dev-requirements.txt`](https://github.com/quantumlib/qsim/blob/master/dev-requirements.txt)
file. You can install them with `pip3 install -r dev-requirements.txt` or
`pip3 install qsimcirq[dev]`.

## Linux installation

We provide `qsimcirq` Python wheels on 64-bit `x86` architectures with `Python 3.{6,7,8,9}`.
Expand Down
12 changes: 2 additions & 10 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,13 +1,5 @@
# Runtime requirements for the python 3 version of cirq.

absl-py
cirq-core
numpy~=1.16
typing_extensions
absl-py

# Build and test requirements

black==20.8b1
flynt~=0.60
pybind11
pytest
typing_extensions
4 changes: 4 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ def build_extension(self, ext):


requirements = open("requirements.txt").readlines()
dev_requirements = open("dev-requirements.txt").readlines()

description = "Schrödinger and Schrödinger-Feynman simulators for quantum circuits."

Expand All @@ -94,6 +95,9 @@ def build_extension(self, ext):
author_email="devabathini92@gmail.com",
python_requires=">=3.3.0",
install_requires=requirements,
extras_require={
"dev": dev_requirements,
},
license="Apache 2",
description=description,
long_description=long_description,
Expand Down