You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't wan't that i must do this every restart because // I Use Cronjob before Update it has worked
==> No open ports detected, continuing to scan...
==> Docs on specifying a port: https://render.com/docs/web-services#port-binding
27/10/24 11:11:32 - INFO - [login_flow]: You'll have to login to Twitch!
27/10/24 11:11:32 - INFO - [login_flow]: Trying the TV login method..
27/10/24 11:11:33 - INFO - [login_flow]: Open https://www.twitch.tv/activate
27/10/24 11:11:33 - INFO - [login_flow]: and enter this code: GFWZZXHT
27/10/24 11:11:33 - INFO - [login_flow]: Hurry up! It will expire in 30 minutes!
Steps to reproduce
Expected behavior
I don't want to have to do that with twitch.tv/activate
Operating system
Render / cron-job
Python version
3.11.9
Miner version
1.9.9
Other relevant software versions
No response
Logs
-- coding: utf-8 --
import logging
from colorama import Fore
from TwitchChannelPointsMiner import TwitchChannelPointsMiner
from TwitchChannelPointsMiner.logger import LoggerSettings, ColorPalette
from TwitchChannelPointsMiner.classes.Chat import ChatPresence
from TwitchChannelPointsMiner.classes.Discord import Discord
from TwitchChannelPointsMiner.classes.Webhook import Webhook
from TwitchChannelPointsMiner.classes.Telegram import Telegram
from TwitchChannelPointsMiner.classes.Matrix import Matrix
from TwitchChannelPointsMiner.classes.Pushover import Pushover
from TwitchChannelPointsMiner.classes.Gotify import Gotify
from TwitchChannelPointsMiner.classes.Settings import Priority, Events, FollowersOrder
from TwitchChannelPointsMiner.classes.entities.Bet import Strategy, BetSettings, Condition, OutcomeKeys, FilterCondition, DelayMode
from TwitchChannelPointsMiner.classes.entities.Streamer import Streamer, StreamerSettings
twitch_miner = TwitchChannelPointsMiner(
username="------------------------------",
password="-------------------------------", # If no password will be provided, the script will ask interactively
claim_drops_startup=True, # If you want to auto claim all drops from Twitch inventory on the startup
priority=[ # Custom priority in this case for example:
Priority.STREAK, # - We want first of all to catch all watch streak from all streamers
Priority.DROPS, # - When we don't have anymore watch streak to catch, wait until all drops are collected over the streamers
Priority.ORDER # - When we have all of the drops claimed and no watch-streak available, use the order priority (POINTS_ASCENDING, POINTS_DESCENDING)
],
enable_analytics=False, # Disables Analytics if False. Disabling it significantly reduces memory consumption
disable_ssl_cert_verification=False, # Set to True at your own risk and only to fix SSL: CERTIFICATE_VERIFY_FAILED error
disable_at_in_nickname=True, # Set to True if you want to check for your nickname mentions in the chat even without @ sign
logger_settings=LoggerSettings(
save=True, # If you want to save logs in a file (suggested)
console_level=logging.INFO, # Level of logs - use logging.DEBUG for more info
console_username=False, # Adds a username to every console log line if True. Also adds it to Telegram, Discord, etc. Useful when you have several accounts
auto_clear=True, # Create a file rotation handler with interval = 1D and backupCount = 7 if True (default)
time_zone="Etc/GMT-1", # Set a specific time zone for console and file loggers. Use tz database names. Example: "America/Denver"
file_level=logging.DEBUG, # Level of logs - If you think the log file it's too big, use logging.INFO
emoji=True, # On Windows, we have a problem printing emoji. Set to false if you have a problem
less=False, # If you think that the logs are too verbose, set this to True
colored=True, # If you want to print colored text
color_palette=ColorPalette( # You can also create a custom palette color (for the common message).
STREAMER_online="GREEN", # Don't worry about lower/upper case. The script will parse all the values.
streamer_offline="red", # Read more in README.md
BET_wiN=Fore.MAGENTA # Color allowed are: [BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE, RESET].
),
telegram=Telegram( # You can omit or set to None if you don't want to receive updates on Telegram
chat_id=123456789, # Chat ID to send messages @getmyid_bot
token="123456789:shfuihreuifheuifhiu34578347", # Telegram API token @Botfather
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.CHAT_MENTION], # Only these events will be sent to the chat
disable_notification=True, # Revoke the notification (sound/vibration)
),
discord=Discord(
webhook_api="--------------------------------------------------", # Discord Webhook URL
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.BET_WIN, Events.CHAT_MENTION], # Only these events will be sent to the chat
),
webhook=Webhook(
endpoint="https://example.com/webhook", # Webhook URL
method="GET", # GET or POST
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.CHAT_MENTION], # Only these events will be sent to the endpoint
),
matrix=Matrix(
username="twitch_miner", # Matrix username (without homeserver)
password="...", # Matrix password
homeserver="matrix.org", # Matrix homeserver
room_id="...", # Room ID
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE, Events.BET_LOSE], # Only these events will be sent
),
pushover=Pushover(
userkey="YOUR-ACCOUNT-TOKEN", # Login to https://pushover.net/, the user token is on the main page
token="YOUR-APPLICATION-TOKEN", # Create a application on the website, and use the token shown in your application
priority=0, # Read more about priority here: https://pushover.net/api#priority
sound="pushover", # A list of sounds can be found here: https://pushover.net/api#sounds
events=[Events.CHAT_MENTION, Events.DROP_CLAIM], # Only these events will be sent
),
gotify=Gotify(
endpoint="https://example.com/message?token=TOKEN",
priority=8,
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.CHAT_MENTION],
)
),
streamer_settings=StreamerSettings(
make_predictions=True, # If you want to Bet / Make prediction
follow_raid=True, # Follow raid to obtain more points
claim_drops=True, # We can't filter rewards base on stream. Set to False for skip viewing counter increase and you will never obtain a drop reward from this script. Issue #21
claim_moments=True, # If set to True, https://help.twitch.tv/s/article/moments will be claimed when available
watch_streak=True, # If a streamer go online change the priority of streamers array and catch the watch screak. Issue #11
community_goals=True, # If True, contributes the max channel points per stream to the streamers' community challenge goals
chat=ChatPresence.ONLINE, # Join irc chat to increase watch-time [ALWAYS, NEVER, ONLINE, OFFLINE]
bet=BetSettings(
strategy=Strategy.SMART, # Choose you strategy!
percentage=5, # Place the x% of your channel points
percentage_gap=20, # Gap difference between outcomesA and outcomesB (for SMART strategy)
max_points=2000, # If the x percentage of your channel points is gt bet_max_points set this value
stealth_mode=False, # If the calculated amount of channel points is GT the highest bet, place the highest value minus 1-2 points Issue Tkd-Alex#33
delay_mode=DelayMode.FROM_END, # When placing a bet, we will wait until delay seconds before the end of the timer
delay=6,
minimum_points=2000, # Place the bet only if we have at least 20k points. Issue #113
filter_condition=FilterCondition(
by=OutcomeKeys.TOTAL_USERS, # Where apply the filter. Allowed [PERCENTAGE_USERS, ODDS_PERCENTAGE, ODDS, TOP_POINTS, TOTAL_USERS, TOTAL_POINTS]
where=Condition.LTE, # 'by' must be [GT, LT, GTE, LTE] than value
value=800
)
)
)
)
You can customize the settings for each streamer. If not settings were provided, the script would use the streamer_settings from TwitchChannelPointsMiner.
If no streamer_settings are provided in TwitchChannelPointsMiner the script will use default settings.
The streamers array can be a String -> username or Streamer instance.
The settings priority are: settings in mine function, settings in TwitchChannelPointsMiner instance, default settings.
For example, if in the mine function you don't provide any value for 'make_prediction' but you have set it on TwitchChannelPointsMiner instance, the script will take the value from here.
If you haven't set any value even in the instance the default one will be used
#twitch_miner.analytics(host="127.0.0.1", port=5000, refresh=5, days_ago=7) # Start the Analytics web-server
], # Array of streamers (order = priority)
followers=False, # Automatic download the list of your followers
followers_order=FollowersOrder.ASC # Sort the followers list by follow date. ASC or DESC
)
Additional context
No response
The text was updated successfully, but these errors were encountered:
Describe the bug
I don't wan't that i must do this every restart because // I Use Cronjob before Update it has worked
==> No open ports detected, continuing to scan...
==> Docs on specifying a port: https://render.com/docs/web-services#port-binding
27/10/24 11:11:32 - INFO - [login_flow]: You'll have to login to Twitch!
27/10/24 11:11:32 - INFO - [login_flow]: Trying the TV login method..
27/10/24 11:11:33 - INFO - [login_flow]: Open https://www.twitch.tv/activate
27/10/24 11:11:33 - INFO - [login_flow]: and enter this code: GFWZZXHT
27/10/24 11:11:33 - INFO - [login_flow]: Hurry up! It will expire in 30 minutes!
Steps to reproduce
Expected behavior
I don't want to have to do that with twitch.tv/activate
Operating system
Render / cron-job
Python version
3.11.9
Miner version
1.9.9
Other relevant software versions
No response
Logs
-- coding: utf-8 --
import logging
from colorama import Fore
from TwitchChannelPointsMiner import TwitchChannelPointsMiner
from TwitchChannelPointsMiner.logger import LoggerSettings, ColorPalette
from TwitchChannelPointsMiner.classes.Chat import ChatPresence
from TwitchChannelPointsMiner.classes.Discord import Discord
from TwitchChannelPointsMiner.classes.Webhook import Webhook
from TwitchChannelPointsMiner.classes.Telegram import Telegram
from TwitchChannelPointsMiner.classes.Matrix import Matrix
from TwitchChannelPointsMiner.classes.Pushover import Pushover
from TwitchChannelPointsMiner.classes.Gotify import Gotify
from TwitchChannelPointsMiner.classes.Settings import Priority, Events, FollowersOrder
from TwitchChannelPointsMiner.classes.entities.Bet import Strategy, BetSettings, Condition, OutcomeKeys, FilterCondition, DelayMode
from TwitchChannelPointsMiner.classes.entities.Streamer import Streamer, StreamerSettings
twitch_miner = TwitchChannelPointsMiner(
username="------------------------------",
password="-------------------------------", # If no password will be provided, the script will ask interactively
claim_drops_startup=True, # If you want to auto claim all drops from Twitch inventory on the startup
priority=[ # Custom priority in this case for example:
Priority.STREAK, # - We want first of all to catch all watch streak from all streamers
Priority.DROPS, # - When we don't have anymore watch streak to catch, wait until all drops are collected over the streamers
Priority.ORDER # - When we have all of the drops claimed and no watch-streak available, use the order priority (POINTS_ASCENDING, POINTS_DESCENDING)
],
enable_analytics=False, # Disables Analytics if False. Disabling it significantly reduces memory consumption
disable_ssl_cert_verification=False, # Set to True at your own risk and only to fix SSL: CERTIFICATE_VERIFY_FAILED error
disable_at_in_nickname=True, # Set to True if you want to check for your nickname mentions in the chat even without @ sign
logger_settings=LoggerSettings(
save=True, # If you want to save logs in a file (suggested)
console_level=logging.INFO, # Level of logs - use logging.DEBUG for more info
console_username=False, # Adds a username to every console log line if True. Also adds it to Telegram, Discord, etc. Useful when you have several accounts
auto_clear=True, # Create a file rotation handler with interval = 1D and backupCount = 7 if True (default)
time_zone="Etc/GMT-1", # Set a specific time zone for console and file loggers. Use tz database names. Example: "America/Denver"
file_level=logging.DEBUG, # Level of logs - If you think the log file it's too big, use logging.INFO
emoji=True, # On Windows, we have a problem printing emoji. Set to false if you have a problem
less=False, # If you think that the logs are too verbose, set this to True
colored=True, # If you want to print colored text
color_palette=ColorPalette( # You can also create a custom palette color (for the common message).
STREAMER_online="GREEN", # Don't worry about lower/upper case. The script will parse all the values.
streamer_offline="red", # Read more in README.md
BET_wiN=Fore.MAGENTA # Color allowed are: [BLACK, RED, GREEN, YELLOW, BLUE, MAGENTA, CYAN, WHITE, RESET].
),
telegram=Telegram( # You can omit or set to None if you don't want to receive updates on Telegram
chat_id=123456789, # Chat ID to send messages @getmyid_bot
token="123456789:shfuihreuifheuifhiu34578347", # Telegram API token @Botfather
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.CHAT_MENTION], # Only these events will be sent to the chat
disable_notification=True, # Revoke the notification (sound/vibration)
),
discord=Discord(
webhook_api="--------------------------------------------------", # Discord Webhook URL
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.BET_WIN, Events.CHAT_MENTION], # Only these events will be sent to the chat
),
webhook=Webhook(
endpoint="https://example.com/webhook", # Webhook URL
method="GET", # GET or POST
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.CHAT_MENTION], # Only these events will be sent to the endpoint
),
matrix=Matrix(
username="twitch_miner", # Matrix username (without homeserver)
password="...", # Matrix password
homeserver="matrix.org", # Matrix homeserver
room_id="...", # Room ID
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE, Events.BET_LOSE], # Only these events will be sent
),
pushover=Pushover(
userkey="YOUR-ACCOUNT-TOKEN", # Login to https://pushover.net/, the user token is on the main page
token="YOUR-APPLICATION-TOKEN", # Create a application on the website, and use the token shown in your application
priority=0, # Read more about priority here: https://pushover.net/api#priority
sound="pushover", # A list of sounds can be found here: https://pushover.net/api#sounds
events=[Events.CHAT_MENTION, Events.DROP_CLAIM], # Only these events will be sent
),
gotify=Gotify(
endpoint="https://example.com/message?token=TOKEN",
priority=8,
events=[Events.STREAMER_ONLINE, Events.STREAMER_OFFLINE,
Events.BET_LOSE, Events.CHAT_MENTION],
)
),
streamer_settings=StreamerSettings(
make_predictions=True, # If you want to Bet / Make prediction
follow_raid=True, # Follow raid to obtain more points
claim_drops=True, # We can't filter rewards base on stream. Set to False for skip viewing counter increase and you will never obtain a drop reward from this script. Issue #21
claim_moments=True, # If set to True, https://help.twitch.tv/s/article/moments will be claimed when available
watch_streak=True, # If a streamer go online change the priority of streamers array and catch the watch screak. Issue #11
community_goals=True, # If True, contributes the max channel points per stream to the streamers' community challenge goals
chat=ChatPresence.ONLINE, # Join irc chat to increase watch-time [ALWAYS, NEVER, ONLINE, OFFLINE]
bet=BetSettings(
strategy=Strategy.SMART, # Choose you strategy!
percentage=5, # Place the x% of your channel points
percentage_gap=20, # Gap difference between outcomesA and outcomesB (for SMART strategy)
max_points=2000, # If the x percentage of your channel points is gt bet_max_points set this value
stealth_mode=False, # If the calculated amount of channel points is GT the highest bet, place the highest value minus 1-2 points Issue Tkd-Alex#33
delay_mode=DelayMode.FROM_END, # When placing a bet, we will wait until
delay
seconds before the end of the timerdelay=6,
minimum_points=2000, # Place the bet only if we have at least 20k points. Issue #113
filter_condition=FilterCondition(
by=OutcomeKeys.TOTAL_USERS, # Where apply the filter. Allowed [PERCENTAGE_USERS, ODDS_PERCENTAGE, ODDS, TOP_POINTS, TOTAL_USERS, TOTAL_POINTS]
where=Condition.LTE, # 'by' must be [GT, LT, GTE, LTE] than value
value=800
)
)
)
)
You can customize the settings for each streamer. If not settings were provided, the script would use the streamer_settings from TwitchChannelPointsMiner.
If no streamer_settings are provided in TwitchChannelPointsMiner the script will use default settings.
The streamers array can be a String -> username or Streamer instance.
The settings priority are: settings in mine function, settings in TwitchChannelPointsMiner instance, default settings.
For example, if in the mine function you don't provide any value for 'make_prediction' but you have set it on TwitchChannelPointsMiner instance, the script will take the value from here.
If you haven't set any value even in the instance the default one will be used
#twitch_miner.analytics(host="127.0.0.1", port=5000, refresh=5, days_ago=7) # Start the Analytics web-server
twitch_miner.mine(
[
Streamer("akatimmyone", settings=StreamerSettings(make_predictions=True , follow_raid=True , claim_drops=True , watch_streak=True , community_goals=True , bet=BetSettings(strategy=Strategy.SMART , percentage=5 , stealth_mode=True, percentage_gap=20 , max_points=2000 , filter_condition=FilterCondition(by=OutcomeKeys.ODDS, where=Condition.LTE, value=800 ) ) )),
Streamer("BastiGHG", settings=StreamerSettings(make_predictions=True , follow_raid=True , claim_drops=True , watch_streak=True , community_goals=True , bet=BetSettings(strategy=Strategy.SMART , percentage=5 , stealth_mode=True, percentage_gap=20 , max_points=2000 , filter_condition=FilterCondition(by=OutcomeKeys.ODDS, where=Condition.LTE, value=800 ) ) )),
Streamer("Papaplatte", settings=StreamerSettings(make_predictions=True , follow_raid=True , claim_drops=True , watch_streak=True , community_goals=True , bet=BetSettings(strategy=Strategy.SMART , percentage=5 , stealth_mode=True, percentage_gap=20 , max_points=2000 , filter_condition=FilterCondition(by=OutcomeKeys.ODDS, where=Condition.LTE, value=800 ) ) )),
)
Additional context
No response
The text was updated successfully, but these errors were encountered: