Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

[tracker] pyupgrade --py36-plus #9744

Open
3 of 6 tasks
ShadowJonathan opened this issue Apr 5, 2021 · 0 comments
Open
3 of 6 tasks

[tracker] pyupgrade --py36-plus #9744

ShadowJonathan opened this issue Apr 5, 2021 · 0 comments
Labels
T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.

Comments

@ShadowJonathan
Copy link
Contributor

ShadowJonathan commented Apr 5, 2021

This is a tracker issue for running and PR-ing automated refactors using pyupgrade, per #9131.

I'll do this in the following changes:

Overall Extra Info

Some common changes from pyupgrade:

  • Changes %-formatting to .format (or f-strings if non-trivial)
  • Removes coding: utf-8 file header (not needed since python 3)
  • Changes typing.TypedDict("A") class instantiations to class A(TypedDict)
@erikjohnston erikjohnston added the T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks. label Apr 6, 2021
anoadragon453 pushed a commit that referenced this issue Apr 14, 2021
Part of #9744

Removes all redundant `# -*- coding: utf-8 -*-` lines from files, as python 3 automatically reads source code as utf-8 now.

`Signed-off-by: Jonathan de Jong <[email protected]>`
This was referenced Jul 9, 2021
@ShadowJonathan ShadowJonathan changed the title [tracker] pyupgrade --py36-plus synapse/ tests/ [tracker] pyupgrade --py36-plus Jul 9, 2021
erikjohnston pushed a commit that referenced this issue Jul 19, 2021
This PR is tantamount to running 
```
pyupgrade --py36-plus --keep-percent-format `find synapse/ -type f -name "*.py"`
```

Part of #9744
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
T-Task Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
Projects
None yet
Development

No branches or pull requests

2 participants