Skip to content

Instantly share code, notes, and snippets.

View boonhapus's full-sized avatar

SN boonhapus

View GitHub Profile
@boonhapus
boonhapus / security_logs.py
Created December 1, 2023 19:06
Connection Event Logs
from __future__ import annotations
import datetime as dt
import json
import httpx # pip install httpx
class RESTAPIV1(httpx.Client):
"""It's just an HTTP client."""
@boonhapus
boonhapus / PY_UDF_PARSE_TS_COMMENT_TAG.sql
Last active February 10, 2024 16:34
Parse ThoughtSpot Query comment tag
CREATE OR REPLACE FUNCTION ts_query_tag_comment_json(query STRING)
returns variant not null
language python
runtime_version = '3.8'
handler = 'extract_query_tag_as_json'
AS
$$
from __future__ import annotations
import re