mirror of
https://github.com/astral-sh/ruff.git
synced 2025-09-29 05:15:12 +00:00

## Summary Resolves https://github.com/astral-sh/ruff/issues/9962 by allowing a configuration setting `allowed-unused-imports` TODO: - [x] Figure out the correct name and place for the setting; currently, I have added it top level. - [x] The comparison is pretty naive. I tried using `glob::Pattern` but couldn't get it to work in the configuration. - [x] Add tests - [x] Update documentations ## Test Plan `cargo test`
12 lines
236 B
Python
12 lines
236 B
Python
"""
|
|
Test: allowed-unused-imports
|
|
"""
|
|
|
|
# OK
|
|
import hvplot.pandas
|
|
import hvplot.pandas.plots
|
|
from hvplot.pandas import scatter_matrix
|
|
from hvplot.pandas.plots import scatter_matrix
|
|
|
|
# Errors
|
|
from hvplot.pandas_alias import scatter_matrix
|