Skip to content

Commit 637cd65

Browse files
committed
Fix errors during merging latest code base
1 parent 1b02470 commit 637cd65

1 file changed

Lines changed: 5 additions & 8 deletions

File tree

‎instagram_monitor.py‎

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -781,7 +781,6 @@ def generate_config_with_current_values() -> str:
781781
TIME_FORMAT_12H = False
782782
PRIVACY_SUBSTITUTIONS = []
783783
mode_of_the_tool = "Unknown"
784-
SKIP_WRAP_MESSAGES = False
785784
HIDE_403_ERRORS = False
786785
USE_NIQUESTS = False
787786

@@ -827,7 +826,6 @@ def generate_config_with_current_values() -> str:
827826
START_TIME = 0
828827
NAME_COUNT = 1
829828
WRAPPER_COUNT = 0
830-
FETCH_TYPE = None
831829
pbar = None
832830

833831
# Global tracking for last/next check times
@@ -2906,6 +2904,7 @@ def session_label() -> str:
29062904
_IP_ADDRESS_RE = re.compile(r"(?<!://)\b(\d{1,3}\.){3}\d{1,3}\b(?!:\d+/?)")
29072905
_ACCOUNT_LIMIT_RE = re.compile(r"(\d+)\s+(accounts?)", re.IGNORECASE)
29082906

2907+
29092908
# Builds ANSI escape sequence from a style description string
29102909
def _build_ansi_sequence(style_str):
29112910
if not style_str:
@@ -3960,10 +3959,7 @@ def apply_privacy_substitutions(content: TPrivacyContent) -> TPrivacyContent:
39603959
content_str = content_str.replace(search, replace)
39613960
return cast(TPrivacyContent, content_str)
39623961
if isinstance(content, dict):
3963-
return cast(TPrivacyContent, {
3964-
apply_privacy_substitutions(k) if isinstance(k, str) else k: apply_privacy_substitutions(v)
3965-
for k, v in content.items()
3966-
})
3962+
return cast(TPrivacyContent, {k: apply_privacy_substitutions(v) for k, v in content.items()})
39673963
if isinstance(content, list):
39683964
return cast(TPrivacyContent, [apply_privacy_substitutions(item) for item in content])
39693965
return content
@@ -6134,7 +6130,7 @@ def print_check_timing(r_sleep_time, prefix="", user=None):
61346130

61356131
# Initializes and sets up a progress bar for displaying download progress
61366132
def setup_pbar(total_expected, title):
6137-
global START_TIME, NAME_COUNT, WRAPPER_COUNT, FETCH_TYPE, pbar
6133+
global START_TIME, NAME_COUNT, WRAPPER_COUNT, pbar
61386134

61396135
# Ensure request hooks are active so progress updates are tracked even without jitter or serialization
61406136
ensure_requests_monkey_patched()
@@ -6353,7 +6349,7 @@ def close_pbar():
63536349
def instagram_wrap_request(orig_request):
63546350
@wraps(orig_request)
63556351
def wrapper(*args, **kwargs):
6356-
global NAME_COUNT, START_TIME, WRAPPER_COUNT, FETCH_TYPE, pbar
6352+
global NAME_COUNT, START_TIME, WRAPPER_COUNT, pbar
63576353
method = kwargs.get("method") or (args[1] if len(args) > 1 else None)
63586354
if method and isinstance(method, str):
63596355
method = method.upper()
@@ -7363,6 +7359,7 @@ def _get_iphone_json(path, params, **kwargs):
73637359
err_str = f"Session account '{SESSION_USERNAME or '<anonymous>'}' has been flagged. Log into Instagram and clear warnings."
73647360
update_ui_data(targets={user: {'status': f'Paused: {err_str}'}})
73657361
print(f"* Error: {err_str}")
7362+
73667363
# Pause all other threads once the session account is flagged.
73677364
if WEB_DASHBOARD_ENABLED or DASHBOARD_ENABLED:
73687365
for other_user in list(WEB_DASHBOARD_STOP_EVENTS.keys()):

0 commit comments

Comments
 (0)