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 #3318 - Suppress spinner in parallel runs in CI #3321

Merged
merged 3 commits into from
Aug 13, 2024

Conversation

ziima
Copy link
Contributor

@ziima ziima commented Aug 11, 2024

Suppress spinner in parallel run in CI (not legacy though).

@@ -186,6 +187,19 @@ def test_parallel_no_spinner(tox_project: ToxProjectCreator) -> None:
)


def test_parallel_no_spinner_ci(tox_project: ToxProjectCreator) -> None:
"""Ensure spinner is disabled by default in CI."""
with mock.patch.object(parallel, "execute") as mocked, mock.patch.dict(os.environ, {"CI": "1"}):
Copy link
Member

Choose a reason for hiding this comment

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

Use pytest-mock instead

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed

Copy link
Contributor Author

Choose a reason for hiding this comment

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

OK, I had to rolled back. It seems pytest-mock has some issue with os.environ. Also unittest.mock is used to modify os.environ throughout tox tests.

Copy link
Member

@gaborbernat gaborbernat Aug 11, 2024

Choose a reason for hiding this comment

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

I strongly urge you to reconsider. For patching the operating system environment variables, you should use the built-in pytest monkeypatch fixture. That's what I've been doing for all the other tests in this project as far as I can see and tell.

Copy link
Member

Choose a reason for hiding this comment

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

I will not accept any pull request that doesn't use the already practiced tools and introduces a new way of doing the same thing.

@ziima ziima force-pushed the 3318-ci-no-spinner branch from 2b84041 to 87cb1a8 Compare August 11, 2024 17:17
gaborbernat and others added 2 commits August 13, 2024 09:39
Signed-off-by: Bernát Gábor <bgabor8@bloomberg.net>
@gaborbernat gaborbernat merged commit 3b3628d into tox-dev:main Aug 13, 2024
1 of 3 checks passed
@ziima
Copy link
Contributor Author

ziima commented Aug 14, 2024

Thanks for fixing the PR, I didn't get back to that yet.

naa0yama referenced this pull request in naa0yama/PythonBoilerplate Aug 22, 2024
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [tox](https://togithub.com/tox-dev/tox)
([changelog](https://tox.wiki/en/latest/changelog.html)) | `~4.16.0` ->
`~4.18.0` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/tox/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/tox/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/tox/4.16.0/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/tox/4.16.0/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>tox-dev/tox (tox)</summary>

### [`v4.18.0`](https://togithub.com/tox-dev/tox/releases/tag/4.18.0)

[Compare
Source](https://togithub.com/tox-dev/tox/compare/4.17.1...4.18.0)

<!-- Release notes generated using configuration in .github/release.yml
at 4.18.0 -->

#### What's Changed

- Fix [#&#8203;3278](https://togithub.com/tox-dev/tox/issues/3278) -
Boost temporary directories cleanup in tests by
[@&#8203;ziima](https://togithub.com/ziima) in
[https://github.com/tox-dev/tox/pull/3323](https://togithub.com/tox-dev/tox/pull/3323)
- Fix absolute base python paths conflicting by
[@&#8203;gaborbernat](https://togithub.com/gaborbernat) in
[https://github.com/tox-dev/tox/pull/3325](https://togithub.com/tox-dev/tox/pull/3325)
- Fix [#&#8203;3318](https://togithub.com/tox-dev/tox/issues/3318) -
Suppress spinner in parallel runs in CI by
[@&#8203;ziima](https://togithub.com/ziima) in
[https://github.com/tox-dev/tox/pull/3321](https://togithub.com/tox-dev/tox/pull/3321)

**Full Changelog**:
tox-dev/tox@4.17.1...4.18.0

### [`v4.17.1`](https://togithub.com/tox-dev/tox/releases/tag/4.17.1)

[Compare
Source](https://togithub.com/tox-dev/tox/compare/4.17.0...4.17.1)

<!-- Release notes generated using configuration in .github/release.yml
at 4.17.1 -->

##### What's Changed

- Restore limited `<major>.<minor>` environment name support by
[@&#8203;gaborbernat](https://togithub.com/gaborbernat) in
[https://github.com/tox-dev/tox/pull/3319](https://togithub.com/tox-dev/tox/pull/3319)
- fix(tox_env.python): do not process absolute paths to interpreter as
PythonSpec by [@&#8203;paveldikov](https://togithub.com/paveldikov) in
[https://github.com/tox-dev/tox/pull/3311](https://togithub.com/tox-dev/tox/pull/3311)

##### New Contributors

- [@&#8203;paveldikov](https://togithub.com/paveldikov) made their first
contribution in
[https://github.com/tox-dev/tox/pull/3311](https://togithub.com/tox-dev/tox/pull/3311)

**Full Changelog**:
tox-dev/tox@4.17.0...4.17.1

### [`v4.17.0`](https://togithub.com/tox-dev/tox/releases/tag/4.17.0)

[Compare
Source](https://togithub.com/tox-dev/tox/compare/4.16.0...4.17.0)

<!-- Release notes generated using configuration in .github/release.yml
at 4.17.0 -->

##### What's Changed

- Fix user guide system overview so nodes don't overlap. by
[@&#8203;Tom01098](https://togithub.com/Tom01098) in
[https://github.com/tox-dev/tox/pull/3307](https://togithub.com/tox-dev/tox/pull/3307)
- Table with list of default env vars per OS by
[@&#8203;seyidaniels](https://togithub.com/seyidaniels) in
[https://github.com/tox-dev/tox/pull/3291](https://togithub.com/tox-dev/tox/pull/3291)
- Add GraalPy and test both GraalPy and Jython env identifiers by
[@&#8203;timfel](https://togithub.com/timfel) in
[https://github.com/tox-dev/tox/pull/3312](https://togithub.com/tox-dev/tox/pull/3312)
- Add on platform constat to core by
[@&#8203;gaborbernat](https://togithub.com/gaborbernat) in
[https://github.com/tox-dev/tox/pull/3315](https://togithub.com/tox-dev/tox/pull/3315)

##### New Contributors

- [@&#8203;Tom01098](https://togithub.com/Tom01098) made their first
contribution in
[https://github.com/tox-dev/tox/pull/3307](https://togithub.com/tox-dev/tox/pull/3307)
- [@&#8203;timfel](https://togithub.com/timfel) made their first
contribution in
[https://github.com/tox-dev/tox/pull/3312](https://togithub.com/tox-dev/tox/pull/3312)

**Full Changelog**:
tox-dev/tox@4.16.0...4.17.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View the
[repository job
log](https://developer.mend.io/github/naa0yama/PythonBoilerplate).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNy40NDAuNyIsInVwZGF0ZWRJblZlciI6IjM4LjI2LjEiLCJ0YXJnZXRCcmFuY2giOiJtYWluIiwibGFiZWxzIjpbImRhdGFzb3VyY2U6cHlwaSIsImRlcFR5cGU6ZGV2IiwibWFuYWdlcjpwb2V0cnkiLCJyZW5vdmF0ZSIsInVwZGF0ZS1taW5vciIsInZlcnNpb25pbmc6cG9ldHJ5Il19-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
hofbi referenced this pull request in luminartech/dev-tools Sep 3, 2024
This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [tox](https://togithub.com/tox-dev/tox)
([changelog](https://tox.wiki/en/latest/changelog.html)) | `==4.17.1` ->
`==4.18.0` |
[![age](https://developer.mend.io/api/mc/badges/age/pypi/tox/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![adoption](https://developer.mend.io/api/mc/badges/adoption/pypi/tox/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![passing](https://developer.mend.io/api/mc/badges/compatibility/pypi/tox/4.17.1/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|
[![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/tox/4.17.1/4.18.0?slim=true)](https://docs.renovatebot.com/merge-confidence/)
|

---

### Release Notes

<details>
<summary>tox-dev/tox (tox)</summary>

### [`v4.18.0`](https://togithub.com/tox-dev/tox/releases/tag/4.18.0)

[Compare
Source](https://togithub.com/tox-dev/tox/compare/4.17.1...4.18.0)

<!-- Release notes generated using configuration in .github/release.yml
at 4.18.0 -->

#### What's Changed

- Fix [#&#8203;3278](https://togithub.com/tox-dev/tox/issues/3278) -
Boost temporary directories cleanup in tests by
[@&#8203;ziima](https://togithub.com/ziima) in
[https://github.com/tox-dev/tox/pull/3323](https://togithub.com/tox-dev/tox/pull/3323)
- Fix absolute base python paths conflicting by
[@&#8203;gaborbernat](https://togithub.com/gaborbernat) in
[https://github.com/tox-dev/tox/pull/3325](https://togithub.com/tox-dev/tox/pull/3325)
- Fix [#&#8203;3318](https://togithub.com/tox-dev/tox/issues/3318) -
Suppress spinner in parallel runs in CI by
[@&#8203;ziima](https://togithub.com/ziima) in
[https://github.com/tox-dev/tox/pull/3321](https://togithub.com/tox-dev/tox/pull/3321)

**Full Changelog**:
tox-dev/tox@4.17.1...4.18.0

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "before 4am on the first day of the
month" (UTC), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you
are satisfied.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/luminartech/dev-tools).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOC41Ni4wIiwidXBkYXRlZEluVmVyIjoiMzguNTYuMCIsInRhcmdldEJyYW5jaCI6Im1hc3RlciIsImxhYmVscyI6W119-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
@ziima ziima deleted the 3318-ci-no-spinner branch September 13, 2024 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants