pytest-mypy-plugins icon indicating copy to clipboard operation
pytest-mypy-plugins copied to clipboard

Document cache directory usage

Open zero323 opened this issue 4 years ago • 0 comments

When tests are executed with typecheck_in_new_subprocess and disable_cache is False, --cache-dir is passed directly to mypy call as a path relative to root directory.

This means that the following are ignored

  • MYPY_CACHE_DIRin execution environment orenv` block of the test case.
  • cache_dir in mypy configuration.

are ignored.

This behavior is confusing, so it might be a good idea to document it.

In a long run, YamlTestItem should check if any of these are provided, and omit --cache-dir in such cases (this would be useful for example with remote cache).

zero323 avatar Oct 18 '21 16:10 zero323