Skip to main content

Twitter Clean-up GitHub Actions: Black workflow GitHub Actions: Tests workflow

🇧🇷 Versão em português do Brasil

Tiny script to clean-up your Twitter account:

  • Removing users that have not been tweeting for a while
  • Soft-blocking bots (blocks and immediately unblocks the account, so it stops following you)

Requirements

  • Python 3.6+
  • Set environment variables with your Twitter API keys and with Botometer API key:
    • TWITTER_CONSUMER_KEY
    • TWITTER_CONSUMER_SECRET
    • TWITTER_ACCESS_TOKEN_KEY
    • TWITTER_ACCESS_TOKEN_SECRET
    • BOTOMETER_MASHAPE_KEY

Installing

Install the package with:

$ pip install twitter-cleanup

Usage

Run the CLI with twitter-cleanup --help and follow the on screen instructions.

For example, unfollow everyone that hasn't tweeted in the last 30 days with:

$ twitter-cleanup inactive 30

Or soft-block every bot with:

$ twitter-cleanup bots

Contributing

Please, write and run tests locally, and format your code with Black:

$ python setup.py test
$ black .

Metadata

Release files for twitter-cleanup 0.0.7

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

Source distribution (sdist)

Source distribution for twitter-cleanup 0.0.7
File Size Uploaded Provenance Actions
twitter-cleanup-0.0.7.tar.gz 8.0 kB Without provenance Details for twitter-cleanup-0.0.7.tar.gz

Release files / twitter-cleanup-0.0.7.tar.gz

Download URL twitter-cleanup-0.0.7.tar.gz
Size 8.0 kB
Tags Source
SHA-256 checksum
How to use checksums
69c6a83e2538fe1628639d55eea9ee7eb448cc879cb69819cfef867d3e2e3f84
BLAKE2b-256 checksum
How to use checksums
086f3fa06321b6afb816251ac2da9bc1b6eb5027511a454a70f9d4a14e837aab
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.0.0 requests-toolbelt/0.9.1 tqdm/4.55.1 CPython/3.8.6

Security for twitter-cleanup 0.0.7

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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