Skip to main content

A Python wrapper for tweakers.net

Project description

Tweakers

Build codecov PyPI PyPI - Python Version

A Python wrapper for tweakers.net

Install

pip install tweakers

Usage

import tweakers

Gathering

With the tweakers.gathering module you can access the forum.

Active topics

for topic in tweakers.gathering.active_topics():
    print(topic.title)

Search

for topic in tweakers.gathering.search('tweakers.net'):
    print(topic.title)

Topic

Get comments for a specific topic

topic = Topic("https://gathering.tweakers.net/forum/list_messages/1551828")
for comment in topic.comments(page=1):
    print(comment.user.name, comment.text)

Generate new comments as they are added

for comment in topic.comment_stream():
    print(comment.user.name, comment.text)

Login

tweakers.login("YOUR_USERNAME", "YOUR_PASSWORD")

Now you can access pages that are unavailable for logged out users:

for topic in tweakers.gathering.bookmarks():
    print(topic.name)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tweakers-0.4.0.tar.gz (7.0 kB view hashes)

Uploaded Source

Built Distribution

tweakers-0.4.0-py3-none-any.whl (9.2 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page