MCPcopy Create free account
hub / github.com/TimMcCool/scratchattach / issue_login_warning

Function issue_login_warning

scratchattach/site/session.py:1352–1364  ·  view source on GitHub ↗

Issue a login data warning.

()

Source from the content-addressed store, hash-verified

1350
1351
1352def issue_login_warning() -> None:
1353 """
1354 Issue a login data warning.
1355 """
1356 if getattr(suppressed_login_warning, "suppressed", 0):
1357 return
1358 warnings.warn(
1359 "IMPORTANT: If you included login credentials directly in your code (e.g. session_id, session_string, ...), "
1360 "then make sure to EITHER instead load them from environment variables or files OR remember to remove them before "
1361 "you share your code with anyone else. If you want to remove this warning, "
1362 "use `warnings.filterwarnings('ignore', category=scratchattach.LoginDataWarning)`",
1363 exceptions.LoginDataWarning,
1364 )
1365
1366
1367def login_by_id(session_id: str, *, username: Optional[str] = None, password: Optional[str] = None, xtoken=None) -> Session:

Callers 3

login_by_idFunction · 0.85
loginFunction · 0.85
login_by_session_stringFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected