Registry / aws / cdk-tweet-queue

cdk-tweet-queue

JSON →
library2.0.949pypypi✓ verified 88d ago

An AWS CDK construct that creates an SQS queue populated with tweets from a search query. Version 2.0.949, released weekly.

pip install cdk-tweet-queue
INSTALL
IMPORT
SIG · CDK-TWEET-QUEUE
C
cdk-tweet-queue
awspythonv2.0.949
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

TweetQueue
✓ from cdk_tweet_queue import TweetQueue
✗ from tweet_queue import TweetQueue
Package name uses underscores, not hyphens

Create an SQS queue that streams tweets matching a search query.

from aws_cdk import App, Stack from aws_cdk import aws_sqs as sqs from cdk_tweet_queue import TweetQueue app = App() stack = Stack(app, "MyStack") queue = TweetQueue( stack, "MyTweetQueue", query="#python", consumer_timeout=300, max_receive_count=3, retry_attempts=3, ) app.synth()
Debug
Known issues
breakingThe construct creates an SQS queue internally; do not provide your own queue – use the exposed queue attribute.
fix
Access the queue via `queue.queue` after construction.
affects: >=2.0.0
deprecatedThe `query` parameter previously supported Twitter API v1.1 endpoints; migrate to v2 if using OAuth 2.0.
fix
Ensure your Twitter developer credentials are for API v2. See changelog for migration.
affects: >=2.0.0
gotchaThe `consumer_timeout` must be a positive integer (in seconds). Negative or zero values cause deployment failure.
fix
Set `consumer_timeout` to a value >= 60 seconds, e.g., 300.
affects: >=2.0.0
Errors
Common errors & fixes
ModuleNotFoundError: No module named 'tweet_queue'
Import path uses incorrect hyphenated name instead of underscores.
fix
Use `from cdk_tweet_queue import TweetQueue`
jsii.errors.JSIIError: Cannot resolve resource 'arn:aws:sqs:...'
Trying to pass an existing SQS queue to the construct which creates its own.
fix
Do not provide a queue; use `queue.queue` to reference the created queue.
AttributeError: 'TweetQueue' object has no attribute 'queue_arn'
Old property name before v2 update.
fix
Use `queue.queue.queue_arn` or the `queue` attribute.
Upgrade
Version history
2.0.949latest on PyPI · released May 4, 2026
Audit
Dependencies
aws-cdk-librequiredCDK library integration
constructsrequiredCore construct class
Agent activity
18 hits · last 30 days
node
18
Resources