KotlinIsland / KotlinIsland/basedmypy
Special case to preserve/ban `implicit-optional` when baselined
- Dominant language
- Python
- Stars
- 202
- Forks
- 6
- PR merge metrics
- No merged PRs in 30d
Description
Turning off implicit-optional and baselining will introduce a bunch of false errors
```py
def foo(value: str = None): # baselined "assignment" error
bar: str = value # no error because type of value is `str`
```
We should implement a special case to either:
- straight up ban this code even when baselining
- preserve the implicit optional
Contributor guide
Research direction
Start by reproducing the shown `implicit-optional` example with baselining enabled, then trace the checker paths that handle implicit optional types and baselined errors. Done means the project has a decided, tested behavior: either this pattern remains banned during baselining or the implicit optional is preserved without producing the false downstream error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- devtools
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100