python-diskcache icon indicating copy to clipboard operation
python-diskcache copied to clipboard

Clarify optional None parameters in docstrings

Open IceboxDev opened this issue 4 months ago β€’ 0 comments

πŸ“ Description

Docstrings across the cache modules were overly strict about parameter types, omitting that several valuesβ€”such as expire, tag, or directory could legitimately be None. This led to confusing type-hint warnings. The updated docstrings explicitly document optional None values throughout the core, fanout, Django cache, persistent cache, and recipe helpers, ensuring the documentation matches actual behavior.

✨ Changes

  • [x] 🐞 Bug fix (non-breaking change which fixes an issue)
  • [ ] πŸ”¨ Refactor (non-breaking change which refactors the code base)
  • [ ] πŸš€ New feature (non-breaking change which adds functionality)
  • [ ] πŸ’₯ Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • [x] πŸ“š Documentation update
  • [ ] πŸ”’ Security update

IceboxDev avatar Aug 08 '25 00:08 IceboxDev