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

Pyyaml install docs #121

Merged
merged 5 commits into from
Jul 19, 2023
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
7 changes: 7 additions & 0 deletions .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,13 @@ jobs:
shell: bash
if: steps.poetry-cache.outputs.cache-hit != 'true'
run: |
# workaround start
# this is a pyyaml v5 vs cython v3 conflict workaround
# see https://github.com/alan-turing-institute/sqlsynthgen/issues/120
python -m poetry run pip install "cython<3"
python -m poetry run pip install wheel
python -m poetry run pip install --no-build-isolation "pyyaml==5.4.1"
# workaround end
python -m poetry install --all-extras
- name: Install Pre-Commit
shell: bash
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,13 @@ jobs:
shell: bash
if: steps.poetry-cache.outputs.cache-hit != 'true'
run: |
# workaround start
# this is a pyyaml v5 vs cython v3 conflict workaround
# see https://github.com/alan-turing-institute/sqlsynthgen/issues/120
python -m poetry run pip install "cython<3"
python -m poetry run pip install wheel
python -m poetry run pip install --no-build-isolation "pyyaml==5.4.1"
# workaround end
python -m poetry install --all-extras
- name: Create src database
shell: bash
Expand Down
7 changes: 7 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,13 @@ build:
# nodejs: "19"
# rust: "1.64"
# golang: "1.19"
jobs:
# This pre-install job is a pyyaml v5 vs cython v3 conflict workaround
# see https://github.com/alan-turing-institute/sqlsynthgen/issues/120
pre_install:
- pip install "cython<3"
- pip install wheel
- pip install --no-build-isolation "pyyaml==5.4.1"

# Build documentation in the docs/ directory with Sphinx
sphinx:
Expand Down
11 changes: 10 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,16 @@ Please install the following software on your workstation:
poetry install --all-extras
```

*If you don't need to [build the project documentation](#building-documentation-locally), run instead just `poetry install`*
If Poetry errors when installing PyYaml, you will need to manually specify the Cython version and manually install PyYaml (this is a temporary workaround for a PyYaml v5 conflict with Cython v3, see [here](https://github.com/yaml/pyyaml/issues/601) for full details):

```bash
poetry run pip install "cython<3"
poetry run pip install wheel
poetry run pip install --no-build-isolation "pyyaml==5.4.1"
poetry install --all-extras
```

*If you don't need to [build the project documentation](#building-documentation-locally), run instead just `poetry install`.*

1. Install the git hook scripts. They will run whenever you perform a commit:

Expand Down
14 changes: 12 additions & 2 deletions docs/source/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,23 @@ Installation
End User
--------

To use sqlsynthgen, first install it:
To use SqlSynthGen, first install it:

.. code-block:: console

$ pip install sqlsynthgen

and check that you can view the help message with:

If Pip errors when installing PyYaml, you will need to manually specify the Cython version and manually install PyYaml (this is a temporary workaround for a PyYaml v5 conflict with Cython v3, see `here <https://github.com/yaml/pyyaml/issues/601>`_ for full details):

.. code-block:: console

pip install "cython<3"
pip install wheel
pip install --no-build-isolation "pyyaml==5.4.1"
pip install sqlsynthgen

Check that you can view the help message with:

.. code-block:: console

Expand Down