Primary finding
State write proceeds with empty $state_parent and silently no-ops, but success summary still claims success
- scripts/postprocess-admanage-create.sh:177-195
When state_parent is empty, the warning prints and a SKIPPED summary line is appended, BUT the code then still runs jq with --arg parent "" which silently no-ops (matches no campaign), and then ALSO appends a second summary line 'adset → ID (under '')' and increments adset_success. The user sees two summary lines for the same ad set (one SKIPPED, one success) which is confusing/misleading. The state-file no-op was even called out in the comment as the thing they're guarding against, yet they then still execute the no-op jq write.
Recommendation
When state_parent is empty, `continue` after recording the warning (after writing the result JSON and moving the input file) instead of falling through to the jq state write and the additional success summary. Alternatively guard the jq invocation with `if [ -n "$state_parent" ]`.