Deploy AIOS web (React glide grid + FastAPI slice)
Browse files- RELEASES.json +1 -1
- VERSION +1 -1
- api/automation_engine.py +27 -5
RELEASES.json
CHANGED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
{
|
| 2 |
-
"current": "
|
| 3 |
"releases": [
|
| 4 |
{
|
| 5 |
"version": "v24",
|
|
|
|
| 1 |
{
|
| 2 |
+
"current": "3c09d7c",
|
| 3 |
"releases": [
|
| 4 |
{
|
| 5 |
"version": "v24",
|
VERSION
CHANGED
|
@@ -1 +1 @@
|
|
| 1 |
-
|
|
|
|
| 1 |
+
3c09d7c
|
api/automation_engine.py
CHANGED
|
@@ -1426,7 +1426,7 @@ def clean_config(kind, raw, previous=None):
|
|
| 1426 |
return {"recordsLimit": limit, "predicates": preds,
|
| 1427 |
"operator": join,
|
| 1428 |
"targetTable": target,
|
| 1429 |
-
"targetLabel": _s(raw.get("targetLabel"), 60).strip() or
|
| 1430 |
# C6/R5: WHERE the conditions above came from, when they were derived. Stored so
|
| 1431 |
# the surface can say "these were filled in from the 'Florists' view, over 12
|
| 1432 |
# records" instead of presenting them as if somebody typed them.
|
|
@@ -2253,7 +2253,7 @@ def _presets_after_write(rt, defn, username):
|
|
| 2253 |
return
|
| 2254 |
try:
|
| 2255 |
if (defn.get("trigger") or {}).get("key") == "ig_profile_match":
|
| 2256 |
-
ut_ensure(rt, cfg.get("targetLabel") or
|
| 2257 |
key=target, flow_tag=str(defn.get("id") or ""), lock_fields=True)
|
| 2258 |
return
|
| 2259 |
enrich_actions = _actions_of_kind(((defn.get("flow") or {}).get("actions") or []),
|
|
@@ -2735,8 +2735,30 @@ from connectors_ig import ( # noqa: E402
|
|
| 2735 |
# `/customer/balance` answers 403 for our token β so there is no balance to read and no spend to
|
| 2736 |
# report. Every estimate below is derived from the PRICING PAGE and says so.
|
| 2737 |
|
| 2738 |
-
#: The table a discovery run writes
|
| 2739 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2740 |
#: A hard ceiling on one run's ask β and it is DERIVED, not chosen. A corpus row MEASURED at
|
| 2741 |
#: ~35 KB (`file_size` 175,617 for 5 rows), so 1,000 records β 33 MB would have crossed
|
| 2742 |
#: `BD_MAX_KB` and come back as a truncated document **after being billed**. 500 leaves real
|
|
@@ -5216,7 +5238,7 @@ def run_discover_instagram(rt, defn, username="automation", log=print, step=_no_
|
|
| 5216 |
# "the vendor delivered 3". It also catches the shape where an error document comes back
|
| 5217 |
# down the rows path and parses as one unusable row instead of an error.
|
| 5218 |
counts["dropped"] = max(0, len(rows) - len(incoming))
|
| 5219 |
-
label = cfg.get("targetLabel") or
|
| 5220 |
table_key = (ut_key_for(label, cfg.get("targetTable") or DISCOVER_TABLE) if dry
|
| 5221 |
else ut_ensure(rt, label, CANDIDATE_FIELDS, username,
|
| 5222 |
key=cfg.get("targetTable") or DISCOVER_TABLE,
|
|
|
|
| 1426 |
return {"recordsLimit": limit, "predicates": preds,
|
| 1427 |
"operator": join,
|
| 1428 |
"targetTable": target,
|
| 1429 |
+
"targetLabel": _s(raw.get("targetLabel"), 60).strip() or DISCOVER_LABEL,
|
| 1430 |
# C6/R5: WHERE the conditions above came from, when they were derived. Stored so
|
| 1431 |
# the surface can say "these were filled in from the 'Florists' view, over 12
|
| 1432 |
# records" instead of presenting them as if somebody typed them.
|
|
|
|
| 2253 |
return
|
| 2254 |
try:
|
| 2255 |
if (defn.get("trigger") or {}).get("key") == "ig_profile_match":
|
| 2256 |
+
ut_ensure(rt, cfg.get("targetLabel") or DISCOVER_LABEL, CANDIDATE_FIELDS, username,
|
| 2257 |
key=target, flow_tag=str(defn.get("id") or ""), lock_fields=True)
|
| 2258 |
return
|
| 2259 |
enrich_actions = _actions_of_kind(((defn.get("flow") or {}).get("actions") or []),
|
|
|
|
| 2735 |
# `/customer/balance` answers 403 for our token β so there is no balance to read and no spend to
|
| 2736 |
# report. Every estimate below is derived from the PRICING PAGE and says so.
|
| 2737 |
|
| 2738 |
+
#: The table a discovery run writes when the tenant has no Instagram profile database yet β the
|
| 2739 |
+
#: FIRST one, never a second (`discover_default_table` elects an existing one before this is
|
| 2740 |
+
#: reached). Upsert by handle, so re-finding a profile is free.
|
| 2741 |
+
#:
|
| 2742 |
+
#: β 2026-08-10 β RENAMED FROM `ut_ig_candidates` / "IG candidates" (owner: *"We only need ONE IG
|
| 2743 |
+
#: profile so it's not confusing"*). The old pair was two kinds of wrong at once. The KEY said
|
| 2744 |
+
#: `candidates` while every other table in the graph says what it holds (`ut_ig_posts`,
|
| 2745 |
+
#: `ut_ig_comments`, `ut_ig_snapshots`, `ut_ig_post_snapshots`) β and "candidate" was a concept
|
| 2746 |
+
#: W26/R6 retired when it deleted `tracked`: a row here is a PROFILE, and whether anyone wants it
|
| 2747 |
+
#: is a stage column's business, not the table's name. The LABEL then disagreed with the key on
|
| 2748 |
+
#: any tenant who renamed the table, which is exactly the mismatch the owner hit.
|
| 2749 |
+
#:
|
| 2750 |
+
#: β SAFE TO MOVE ONLY BECAUSE NOTHING HOLDS THE OLD KEY. Census 2026-08-10 across all three
|
| 2751 |
+
#: tenant stores: royal-imports ABSENT, gtmlab has no tables at all, and nurilab's was deleted the
|
| 2752 |
+
#: same day (0 rows, 0 views, 0 dependent automations). An automation that stored the old key
|
| 2753 |
+
#: explicitly still resolves to it β an explicit target is never rewritten β so a legacy tenant
|
| 2754 |
+
#: would keep working; there simply is not one.
|
| 2755 |
+
#: β A future rename is NOT this cheap. Once rows exist under a key, moving it is a migration
|
| 2756 |
+
#: touching rows, `link.table`, every stored `targetTable` and the `ut_<slug>_*` bucket family.
|
| 2757 |
+
DISCOVER_TABLE = "ut_ig_profile"
|
| 2758 |
+
#: The label that key is CREATED with. `ut_ensure` sets a label only on create and never relabels,
|
| 2759 |
+
#: so changing this can rename nothing that already exists. One constant because it was three
|
| 2760 |
+
#: copies of the same string literal, and a default spelled three times is one edit from drifting.
|
| 2761 |
+
DISCOVER_LABEL = "IG profile"
|
| 2762 |
#: A hard ceiling on one run's ask β and it is DERIVED, not chosen. A corpus row MEASURED at
|
| 2763 |
#: ~35 KB (`file_size` 175,617 for 5 rows), so 1,000 records β 33 MB would have crossed
|
| 2764 |
#: `BD_MAX_KB` and come back as a truncated document **after being billed**. 500 leaves real
|
|
|
|
| 5238 |
# "the vendor delivered 3". It also catches the shape where an error document comes back
|
| 5239 |
# down the rows path and parses as one unusable row instead of an error.
|
| 5240 |
counts["dropped"] = max(0, len(rows) - len(incoming))
|
| 5241 |
+
label = cfg.get("targetLabel") or DISCOVER_LABEL
|
| 5242 |
table_key = (ut_key_for(label, cfg.get("targetTable") or DISCOVER_TABLE) if dry
|
| 5243 |
else ut_ensure(rt, label, CANDIDATE_FIELDS, username,
|
| 5244 |
key=cfg.get("targetTable") or DISCOVER_TABLE,
|