Skip to main content

Alfred the butler

Build Status PyPI version

Alfred is a flake8 plugin to warn on unsafe/obsolete symbols. You can use it as a transition tool to eliminate functions, modules, variables you don't want in existing project or you want to avoid in new ones. This plugin requires Python 3.6.

Getting Started

First, install Alfred using pip:

$ pip install flake8-alfred

Then, enable the plugin by configuring a blacklist of Python symbols that should be flagged by flake8. Here is an example of configuration in your project's setup.cfg:

[flake8]
enable-extensions = B1
warn-symbols =
    obsolete_module = Warning! This module is obsolete!
    module.obsolete_function = Warning! This function is obsolete!
    module.submodule.constant = Warning! this variable will be removed!

Here enable-extensions tells flake8 to enable this plugin and warn-symbols is the list of symbols we want to flag in our project, with the associated warning. By default, this plugin doesn't warn about any other symbol.

If you just want to test/run once, you can also pass the configuration directly to flake8:

$ flake8 --enable-extensions=B1 --warn-symbols=$'obsolete_module=Warning!\nmodule.obsolete_function=Warning!'

Local Development

First, clone the repository:

git clone https://github.com/datatheorem/alfred-checker.git

The project uses pipenv to manage dependencies:

$ pipenv install --dev

Then, the test suite can be run:

$ pipenv run pytest

Release files for flake8-alfred 1.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for flake8-alfred 1.1.2
File Size Uploaded
flake8_alfred-1.1.2.tar.gz 8.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for flake8-alfred 1.1.2
File Interpreter ABI Platform
flake8_alfred-1.1.2-py3-none-any.whl Python 3 none any Details

Total release size:16.3 kB

Release files / flake8_alfred-1.1.2.tar.gz

Download URL flake8_alfred-1.1.2.tar.gz
Size 8.3 kB
Tags Source
SHA-256 checksum
How to use checksums
ccd77e103a9748c530ee0a56edb88d1e0efe7373b04c60c9c3fee0807e46e1b6
BLAKE2b-256 checksum
How to use checksums
2a204c4a9b15b32273e2d1c17f574237bbf7455aa9bda7c4aa50ddc073149006
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.0

Release files / flake8_alfred-1.1.2-py3-none-any.whl

Download URL flake8_alfred-1.1.2-py3-none-any.whl
Size 8.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
96073d7f07c8642c53a9845577cf2b5a5bc316d1921d33d4767c9def6540bd48
BLAKE2b-256 checksum
How to use checksums
617ca264e86b064611142c3f6701c0546f3a625376d16568a32057688cb6ba84
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.0

Release history Release notifications | RSS feed

This release

1.1.2 This release

2 release files

1.1.1

2 release files

1.0.2

3 release files

1.0.1

2 release files

1.0.0

3 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page