Skip to content

refresh: unresolved cross-reference for call_asset.call_conversion_action #22

@chrmod

Description

@chrmod

Summary

bidsmith refresh renders a google_ads_call_asset resource whose call_conversion_action field is left as a literal placeholder string instead of being resolved to a sibling google_ads_conversion_action resource address. The output is valid HCL but semantically broken — bidsmith validate accepts it (the field type is a string), but bidsmith apply against this file would fail because the placeholder is not a real resource reference.

Version

```
bidsmith 0.5.0
```

Reproduce

  1. Have a live Google Ads account with:
    • At least one `conversion_action` with category `PHONE_CALL_LEAD` (e.g. "Rezolutnie - Phone").
    • One `call_asset` whose `call_conversion_reporting_state` is `USE_ACCOUNT_LEVEL_CALL_CONVERSION_ACTION` and whose `call_conversion_action` points at that conversion action.
  2. Run:

```sh
bidsmith refresh -d /tmp/snapshot
```

  1. Open `/tmp/snapshot/account.bid`.

Expected

```hcl
resource "google_ads_call_asset" "call_pl_510_019_081" {
country_code = "PL"
phone_number = "510 019 081"
call_conversion_reporting_state = "USE_ACCOUNT_LEVEL_CALL_CONVERSION_ACTION"
call_conversion_action = google_ads_conversion_action.rezolutnie_phone.id
}
```

Actual

```hcl
resource "google_ads_call_asset" "call_pl_510_019_081" {
country_code = "PL"
phone_number = "510 019 081"
call_conversion_reporting_state = "USE_ACCOUNT_LEVEL_CALL_CONVERSION_ACTION"
call_conversion_action = "<unresolved conversion_action 179>"
}
```

The integer in the placeholder (`179` here) does not match the live Google Ads conversion action ID (which was `7612931403` in this case) — looks like an internal index.

Notes

  • The conversion action target is rendered in the same `account.bid` file by the same refresh pass, so the resolver has the information it needs — it just doesn't wire the cross-reference.
  • Workaround is straightforward: edit the file by hand, replace the placeholder with `google_ads_conversion_action..id`. `bidsmith validate` passes after that and `bidsmith plan` reports the resource as `no-op`.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions