Skip to content

Conversation

@jfcherng
Copy link
Contributor

@jfcherng jfcherng commented Apr 21, 2024

With from __future__ import annotations, in type annotations we can convert

  • Type =====> type
  • List =====> list
  • Tuple =====> tuple
  • Dict =====> dict
  • Set =====> set
  • Optional =====> None
  • Union =====> |

Py38 new feature(s):

  • str.format =====> f-string

Not Done in this PR

By the way, we can upgrade flake8 to v7. We previously stayed at v5 because it won't complaint about unused imports, which is used in # type: .... Or, let's go ruff as linter/formatter (this is the setup for all my Python projects now 😄 ).

Signed-off-by: Jack Cherng <jfcherng@gmail.com>
Signed-off-by: Jack Cherng <jfcherng@gmail.com>
@jfcherng jfcherng force-pushed the feat/future-annotations-more branch from 1d67b68 to f55722c Compare April 21, 2024 12:22
Signed-off-by: Jack Cherng <jfcherng@gmail.com>
Signed-off-by: Jack Cherng <jfcherng@gmail.com>
jfcherng and others added 2 commits April 21, 2024 22:15
Co-authored-by: deathaxe <deathaxe82@googlemail.com>
Signed-off-by: Jack Cherng <jfcherng@gmail.com>
@jfcherng
Copy link
Contributor Author

jfcherng commented Apr 21, 2024

Okay, now there are only line length issues left.

@jfcherng jfcherng force-pushed the feat/future-annotations-more branch from 391562b to 3402cce Compare April 21, 2024 18:06
Signed-off-by: Jack Cherng <jfcherng@gmail.com>
@predragnikolic
Copy link
Member

please ignore the failing CI, the test_did_change_before_did_close is a flaky test,
we track it here -> #2461

@predragnikolic
Copy link
Member

predragnikolic commented Apr 23, 2024

Thanks for the changes

I'll merge this tomorrow

@predragnikolic predragnikolic merged commit 0ab7616 into sublimelsp:main Apr 24, 2024
@jfcherng jfcherng deleted the feat/future-annotations-more branch April 24, 2024 19:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants