Skip to content

Commit

Permalink
feat: udf v2 (#25642)
Browse files Browse the repository at this point in the history
  • Loading branch information
aspicer authored Oct 17, 2024
1 parent 532ecc6 commit a9b5a60
Show file tree
Hide file tree
Showing 6 changed files with 625 additions and 0 deletions.
9 changes: 9 additions & 0 deletions posthog/user_scripts/v2/aggregate_funnel
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/sh

DIR_NAME=$(dirname "$0")

case $( uname -m ) in
aarch64) $DIR_NAME/aggregate_funnel_aarch64 "$@";;
*) $DIR_NAME/aggregate_funnel_x86_64 "$@";;
esac

Binary file added posthog/user_scripts/v2/aggregate_funnel_aarch64
Binary file not shown.
13 changes: 13 additions & 0 deletions posthog/user_scripts/v2/aggregate_funnel_array_trends_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
#!/usr/bin/python3

import sys
import json

if __name__ == "__main__":
for line in sys.stdin:
try:
print(json.dumps({"result": line})) # noqa: T201
# calculate_funnel_trends_from_user_events(*parse_args(line))
except Exception as e:
print(json.dumps({"result": json.dumps(str(e))}), end="\n") # noqa: T201
sys.stdout.flush()
14 changes: 14 additions & 0 deletions posthog/user_scripts/v2/aggregate_funnel_test.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/usr/bin/python3
import json

import sys
import traceback

if __name__ == "__main__":
for line in sys.stdin:
try:
# calculate_funnel_from_user_events(*parse_args(line))
print(json.dumps({"result": line})) # noqa: T201
except Exception as e:
print(json.dumps({"result": json.dumps(str(e) + traceback.format_exc())}), end="\n") # noqa: T201
sys.stdout.flush()
Binary file added posthog/user_scripts/v2/aggregate_funnel_x86_64
Binary file not shown.
Loading

0 comments on commit a9b5a60

Please sign in to comment.