Skip to content

Rename internal key-value store records to the APIFY_UPPER_SNAKE_CASE convention #1210

In progress

Description

@vdusek

Part of https://github.com/apify/apify-core/issues/31956.

Rename the internal records in the default key-value store to the APIFY_UPPER_SNAKE_CASE convention, the same one the JS SDK uses since apify/apify-sdk-js#893:

Record Current key New key
Storage alias mapping __STORAGE_ALIASES_MAPPING APIFY_STORAGE_ALIASES_MAPPING
Charging state __ACTOR_CHARGING_STATE APIFY_ACTOR_CHARGING_STATE
Child runs record __ACTOR_CHILD_RUNS APIFY_ACTOR_CHILD_RUNS

Actor.use_state() keeps APIFY_GLOBAL_STATE, which already follows the convention.

The child runs record is experimental, so its rename ships in #1270. The alias mapping and the charging state are in stable releases. A run reads them back only from its own default key-value store, which a metamorph passes to the target Actor. So the SDK also reads the alias mapping from the old key when the new key has no record. A missing charging state only makes the SDK fall back to the charged event counts from the environment variable.

✍️ Drafted by Claude Code

Activity

  1. added
    t-tooling
    on Oct 29, 2026
  2. added this to the 5.0 milestone on Oct 29, 2026
  3. changed the title [-]Rename internal key-value store records to the `__UPPER_SNAKE` convention[/-] [+]Rename internal key-value store records to the `SDK_UPPER_SNAKE_CASE` convention[/+] on Nov 4, 2026
  4. changed the title [-]Rename internal key-value store records to the `SDK_UPPER_SNAKE_CASE` convention[/-] [+]Rename internal key-value store records to the `APIFY_UPPER_SNAKE_CASE` convention[/+] on Nov 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    t-tooling

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions