Add `home-assistant` to ecosystem projects
Summary
--
I think Micha suggested this before, but I couldn't find the message. This also
may have helped to catch #23125.
Test Plan
--
CI on this PR. I think this is a pretty large repo, so I want to make sure it
doesn't cause too much of a slowdown, in addition to the job passing. However,
it only takes ~4 seconds to check locally compared to ~22 for airflow, despite
containing more files (16k vs 6.5k) and more lines of code (3 million vs 1.2
million).
[`pyupgrade`] Fix handling of `typing.{io,re}` (`UP035`)
Back in Python 3.5, the docs referred to `typing.io` as the primary
location for `IO`, `TextIO`, and `BinaryIO` and `typing.re` as the
primary location for `Pattern` and `Match`:
- https://docs.python.org/3.5/library/typing.html#typing.io
- https://docs.python.org/3.5/library/typing.html#typing.re
In Python 3.6, reference to `typing.io` and `typing.re` disappeared and
these types were importable directly from `typing`:
- https://docs.python.org/3.6/library/typing.html#typing.IO
- https://docs.python.org/3.6/library/typing.html#typing.Pattern
In Python 3.9, the `typing.io` and `typing.re` namespaces were
deprecated pending removal in Python 3.12. In addition, `typing.Pattern`
and `typing.Match` were deprecated in favour of `re.Pattern` and
`re.Match`:
- https://docs.python.org/3.9/library/typing.html#typing.IO
- https://docs.python.org/3.9/library/typing.html#typing.Pattern
Although interestingly it implies that the deprecation of the namespaces
was from Python 3.8.
The pending removal version for the namespaces was updated from 3.12 to
3.13 as the deprecation warning was only in place from 3.11 - that
update was backported through 3.10:
- https://docs.python.org/3.10/library/typing.html#typing.IO
- https://docs.python.org/3.10/library/typing.html#typing.Pattern
The namespaces were removed in Python 3.13:
- https://docs.python.org/3.13/library/typing.html#typing.IO
- https://docs.python.org/3.13/library/typing.html#typing.Pattern
On this basis, it seems we could update `UP035` for the `typing.io` and
`typing.re` namespaces to target as far back as Python 3.6 as they
weren't even mentioned in the docs for Python 3.6 to 3.8 and only
mentioned again when soft deprecated in Python 3.9. The versions of
these types in the main `typing` module have been available the whole
time. As ruff only targets 3.7+, let's go for 3.7.