# Failed: Skipped: you need to specify a reason the pytest.mark.skipif is skipping
ERROR: found no collectors for tests/test_x.py::test_y

- **ID:** `python/pytest-skipif-string-condition`
- **Domain:** python
- **Category:** config_error
- **Verification:** ai_generated
- **Fix Rate:** 80%

## Root Cause

pytest.mark.skipif requires both a condition and a reason keyword. Passing a string as the first positional arg (a common mistake) makes pytest treat it as an invalid condition.

## Version Compatibility

| Version | Status | Introduced | Deprecated |
|---------|--------|------------|------------|
| 7.x | active | — | — |
| 8.x | active | — | — |

## Workarounds

1. **** (98% success)
   ```
   Use keyword arguments:
  @pytest.mark.skipif(sys.platform == 'win32', reason='POSIX-only')
  def test_x(): ...
   ```
2. **** (95% success)
   ```
   For module-level skips:
  pytestmark = pytest.mark.skipif(condition, reason='...')
   ```

## Dead Ends

- **** — Unconditionally skips the test even on platforms where it should run. (90% fail)
- **** — Positional args are not supported for reason; must be keyword. (80% fail)
