Skip to content

Changelog

Changelogยถ

All notable changes to this project will be documented in this file.

[Unreleased] - YYYY-MM-DDยถ

[1.2.1] - 2023-12-24ยถ

Addedยถ
  • Python 3.12 support added

[1.2.0] - 2023-12-22ยถ

Changedยถ
  • Python 3.6 support dropped
  • Python 3.7 support dropped
Fixedยถ
  • Improved Type Comment Analysis

To ensure accurate type comment analysis, a crucial fix was implemented in the code. The update involves refining the process by adding a check within ast.AnnAssign and ast.arg types. Specifically, the code now includes a verification that visit_Constant occurs under an annotation, addressing unnecessary name discovery issues for better accuracy in type_comment assessment.

import sys
from typing import (
    List,
)


test_list: List[str] = ["spam", "eggs"]  # it thought spam and eggs were a ast.Name object.

[1.1.0] - 2023-11-17ยถ

Addedยถ
  • Support for Python version 3.11.

[1.0.1] - 2023-11-17ยถ

Changedยถ
  • Implement strtobool function (and remove distutils dependency) #297

[1.0.0] - 2023-07-07ยถ

Addedยถ
  • Automatically pick up config options from setup.cfg if it is present in the project root else check and if it exists use pyproject.toml. #256

If you want you can disable this feature by passing --disable-auto-discovery-config

  • Add github-action #229
  • Add support like command line commands in configuration files. #287
Fixedยถ
  • ignore-init setting is not working from command line call #263
  • Running without options or a config file #281
  • Attribute as import refactor #284
Changedยถ
  • Raise more human-readable exceptions when the key is mistyped in the configuration #286

[0.16.1] - 2023-07-05ยถ

Fixedยถ
  • Fix: ignore-init setting is not working from command line call #263

[0.16.0] - 2023-04-04ยถ

Addedยถ
  • Add support like command line commands in configuration files. #287
Changedยถ
  • Raise more human-readable exceptions when the key is mistyped in the configuration. #286

[0.15.0] - 2023-03-31ยถ

Fixedยถ
  • Fix: attribute as import refactor #284

[0.14.1] - 2023-02-04ยถ

Fixedยถ
  • Running without options or a config file #281.

[0.14.0] - 2023-02-03ยถ

Addedยถ
  • Automatically pick up config options from setup.cfg if it is present in the project root else check and if it exists use pyproject.toml. #256

If you want you can disable this feature by passing --disable-auto-discovery-config

[0.13.0] - 2023-02-01ยถ

Changedยถ
  • The remove command is set to the default behavior. #273
Fixesยถ
  • pre-commit autoupdate yields a weird result #275

[0.12.3] - 2022-12-04ยถ

Addedยถ
  • Multiple versions of the docs

[0.12.2] - 2022-11-09ยถ

๐Ÿ› Fixesยถ
  • --color=never is now respected when showing the diffs

0.12.1ยถ

๐Ÿ› Fixesยถ
  • Changelog url PR #250
  • Name Error PR #250

0.12.0ยถ

๐Ÿ”ฅ Featuresยถ
  • Add if condition analysis and ๐Ÿงช Refactor PR #247

For example;

import sys

if sys.version_info >= (3, 8):
    from typing import Literal
else:
    from typing_extensions import Literal
  • setup.py remove and pyproject.toml was added. PR #245

0.11.3ยถ

๐Ÿ› Fixesยถ
  • Fix main.py to run unimport

0.11.2ยถ

๐Ÿ› Fixesยถ
  • Re complile fail mentioning โ€˜ps_dโ€™ when using โ€“gitignore PR #241
Internalยถ

For Python 3.7 and above

  • Drop support for patspec, 0.5.0 above and below 0.10.0 versions.
  • Only 0.10.0 and above versions are supported, in these versions the gitignore parameter works more accurately.
  • For more accurate results when using โ€“gitignore parameter, please do not use Python 3.6 and Windows.
๐Ÿ“ Docsยถ
  • Docs update
Internalยถ
  • Refactor main.py and add tests PR #238

0.11.1ยถ

๐Ÿ› Fixesยถ
  • Setup

0.11.0ยถ

๐Ÿ“ Docsยถ
  • Update docs
Deprecatedยถ
  • Remove requirements feature PR #234

    This feature alone is not enough and can be developed as a new project using unimport, it should not be a feature of unimport.

0.10.0ยถ

๐Ÿ› Fixesยถ
  • Configurations flow PR #230
  • Exit code behavior PR #225
Internalยถ
  • ๐Ÿ”ฅ Support Github action PR #231

0.9.6ยถ

Internalยถ
  • 3.10+ Support ๐Ÿ”ฅ PR #26

0.9.5ยถ

๐Ÿ› Fixesยถ
  • Refactor: tests using pytest, fix check method PR #208

0.9.4ยถ

๐Ÿ› Fixesยถ
  • i199 Refactor options & commands & Option color output PR #205
Internalยถ
  • ๐Ÿ”ฅ Build an Docker image PR #202

0.9.2ยถ

๐Ÿ› Fixesยถ
  • setup.py

0.9.1ยถ

๐Ÿ› Fixesยถ
  • EOLs not being respected in modified files per PR #193
  • Respect the fileโ€™s current EOL (LF/CRLF) instead of the platform default
  • Add unit and integration tests that EOLs are respected

0.9.0ยถ

๐Ÿ”ฅ Featuresยถ
  • Scope analyzer PR #189
  • Scope analyzer
  • Duplicate import feature has been enabled again.
๐Ÿ› Fixesยถ
  • Adding unnecessary rpar in vertical style PR #191

ฤฐnput

import sys
from typing import (
    List,
)

test_list: List[str] = ["spam", "eggs"]

Output

from typing import (
  List,

)

test_list: List[str] = ["spam", "eggs"]

0.8.4ยถ

๐Ÿ› Fixesยถ
  • Emoji issues PR #185

0.8.0ยถ

0.7.4ยถ

๐Ÿ› Fixesยถ
  • list_paths in utils PR #172

0.7.3ยถ

๐Ÿ”ฅ Featuresยถ
  • Add --ignore-init flag PR #169

0.7.2ยถ

๐Ÿ”ฅ Featuresยถ
  • Python3.9 Support PR #166

0.7.1ยถ

๐Ÿ› Fixesยถ

0.7.0ยถ

๐Ÿ”ฅ Featuresยถ
  • Star import more accurate suggestion PR #158
Internalยถ
  • %15 performance increase & remove show-error flag PR #159
๐Ÿ› Fixesยถ
  • Fix: scanner PR #157
  • PR #155
  • Configuration Bug Fix ( Configuration priority, reading and merge )
  • %136 - %150 performance increase

0.6.8ยถ

๐Ÿ› Fixesยถ

0.6.6ยถ

๐Ÿ”ฅ Featuresยถ
  • Support multiline skip import only py3.8 and plus PR #138
  • Support type variable PR #128
  • Support Windows OS coloring and encoding PR #116
๐Ÿ› Fixesยถ
  • Call attribute scanner PR #145
  • Requirements feature & star import suggestion PR #142
  • Initial imports from sys.modules PR #136
  • Import and name matcher PR #133
  • Type comment PR #130
  • Same line duplicates PR #125

0.3.0ยถ

๐Ÿ”ฅ Featuresยถ
  • Configuration extend and refactoring PR #111
  • General refactoring PR #108
  • Support append and extend __all__ list
  • Star import suggestions improved
  • Support .gitignore exclude patterns PR #102
  • Support async def Issue #92
๐Ÿ› Fixesยถ
  • Improve: Names, Imports and star suggestion PR #112
  • Unnecessary refactoring PR #107
Internalยถ
  • Optimize Python >=3.8 type comments support method PR #95
  • Improve test coverage PR #93

0.2.10ยถ

๐Ÿ”ฅ Featuresยถ
๐Ÿ› Fixesยถ
  • Vertical style issue PR #86
from foo import (
    Foo,
    Bar,
    FooBar,
)
Foo, Bar

0.2.9ยถ

๐Ÿ”ฅ Featuresยถ
  • Support for exit code and add some enhancement PR #81
๐Ÿ› Fixesยถ
  • Double underscore in builtins imports PR #82
  • Incorrect matching import and name PR #78

0.2.8ยถ

๐Ÿ”ฅ Featuresยถ
  • Support: file-wide skips PR #77
  • Now, you can skip a file by typing # unimport: skip_file anywhere in that file.
  • Support: requirements.txt file PR #75
  • Now, You can automatically delete unused modules from the requirements.txt file ( unimport --requirements --remove), see the difference ( unimport --requirements --diff), delete it by requesting permission ( unimport --requirements --permission), or just check ( unimport --requirements).
  • Support for type hints (#58) & string typing PR #71
from typing import List, TYPE_TEST
test: 'List[TYPE_TEST]'
from typing import List, TYPE_TEST
test: "List['TYPE_TEST']"
๐Ÿ› Fixesยถ
  • Preserve import styles PR #76
  • Match error between import name and name PR #74
  • get_suggestion_modules function fix for __all__ name when import is star PR #64

Last update: December 24, 2023
Created: December 24, 2023