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 notebook failure in CI tests #6218

Merged

Conversation

pavoljuhas
Copy link
Collaborator

  • Avoid interference between notebook tests.
    Use separate pip target directory for each notebook test that may
    pip-install additional packages. This prevents pip upgrade of numpy in one
    notebook breaking another notebook. Even if second notebook downgrades the
    numpy package with !pip install ... command, the high version may be
    already loaded in memory and effective until kernel restart.

  • Quote brackets in pip shell arguments, prevent shell globing errors.

  • Clean redundant parentheses after @pytest.fixture.

Fixes #6213

Add quotation marks to `pip install 'cirq-core[contrib]'` and such.
Avoid shell globing errors for bash `failglob` or zsh `nomatch` options.
No change in the effective code.
Use separate pip target directory for each notebook test that
may pip-install additional packages.

Fixes quantumlib#6213
@pavoljuhas pavoljuhas requested review from a team, vtomole and cduck as code owners July 25, 2023 18:52
@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@CirqBot CirqBot added the size: S 10< lines changed <50 label Jul 25, 2023
Copy link
Collaborator

@NoureldinYosri NoureldinYosri left a comment

Choose a reason for hiding this comment

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

nice

@pavoljuhas pavoljuhas enabled auto-merge (squash) July 25, 2023 19:00
@pavoljuhas pavoljuhas merged commit db1b37b into quantumlib:master Jul 25, 2023
33 checks passed
@pavoljuhas pavoljuhas deleted the fix-notebook-failure-in-ci-test branch July 25, 2023 20:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
size: S 10< lines changed <50
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Notebook tests failing on master
3 participants