Issue a login data warning.
()
| 1350 | |
| 1351 | |
| 1352 | def 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 | |
| 1367 | def login_by_id(session_id: str, *, username: Optional[str] = None, password: Optional[str] = None, xtoken=None) -> Session: |
no outgoing calls
no test coverage detected