Skip to content

[Bug]: Failed to upload file config/settings_data.json without a good reason #5242

@DawidKopys

Description

@DawidKopys

Please confirm that you have:

  • Searched existing issues to see if your issue is a duplicate. (If you’ve found a duplicate issue, feel free to add additional information in a comment on it.)
  • Reproduced the issue in the latest CLI version.

In which of these areas are you experiencing a problem?

Theme

Expected behavior

The CLI should push both settings_data.json and settings_schema.json config files without any issues.
It should work since the new settings in the settings_data.json file meet new settings' schema defined in the settings_schema.json.

Actual behavior

The CLI pushes only settings_schema.json, and provides a warining in the command output:

╭─ warning ────────────────────────────────────────────────────────────────────╮
│                                                                              │
│  The theme 'Development (d7dc3d-Dawids-MacBook-Pro)' (#177681236314) was     │
│  pushed with errors                                                          │
│                                                                              │
│  Next steps                                                                  │
│    • View your theme [1]                                                     │
│    • Customize your theme at the theme editor [2]                            │
│                                                                              │
╰──────────────────────────────────────────────────────────────────────────────╯

Verbose output

I can't paste the verbose output here as github shows "Field can not be longer than 65536 characters" error...

So, here is the file instead:

push-output.txt

Reproduction steps

  1. Initialize a fresh theme: shopify theme init
  2. Push the theme to a dev store shopify push --store=<some_dev_store>
  3. In the config/settings_schema.json file, change logo_width setting's:
  • step value to 4,
  • min value to 52 (so that it is divisable by the new step)
Image
  1. In the config/settings_data.json file, change logo_width value to 84 (it fit's into new step we set in the previous step!)
Image
  1. Run shopify theme push, result - you get ann error:
Image

Error's text:

╭─ error ──────────────────────────────────────────────────────────────────────╮
│                                                                              │
│  config/settings_data.json                                                   │
│                                                                              │
│  Setting 'logo_width' must be a step in the range                            │
│                                                                              │
╰──────────────────────────────────────────────────────────────────────────────╯

╭─ error ──────────────────────────────────────────────────────────────────────╮
│                                                                              │
│  config/settings_schema.json                                                 │
│                                                                              │
│  New schema is incompatible with the current setting value. Setting          │
│  'logo_width' must be a step in the range                                    │
│                                                                              │


╭─ warning ────────────────────────────────────────────────────────────────────╮
│                                                                              │
│  The theme 'futuristic-style-theme' (#179287621978) was pushed with errors   │
│                                                                              │
│  Next steps                                                                  │
│    • View your theme                                                         │
│    • Customize your theme at the theme editor                                │
│                                                                              │
╰──────────────────────────────────────────────────────────────────────────────╯

This issue happens both on my local machine and in gitlab's CI.I am using Shopify CLI 3.74.0 on my local machine and 3.72.1 in the Gitlab CI.
Above reproduction presents the issue when using shopify cli on my local machine for ease of reproduction only. In reality, the issue appears in our Gitlab CI pipeline when we try to push to a live theme in a production store.

Operating System

MacOS Sonoma AND GitLab CI based on node:20 image

Shopify CLI version (shopify --version)

3.74.0

Shell

iTerm2

Node version (run node -v if you're not sure)

v20.18.0

What language and version are you using in your application?

No response

Metadata

Metadata

Assignees

Labels

Type

No fields configured for Bug.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions