internalfx / quickshot

A Shopify theme development tool.
ISC License
107 stars 18 forks source link

Add file path/name to error output #73

Closed rickydazla closed 2 years ago

rickydazla commented 4 years ago

Example error output on qs theme watch:

02:11:48 pm - Deleted theme/assets/blah
02:11:48 pm - 422 - {"errors":{"asset":["Invalid type value for block '1234567890'. Type must be defined in schema"]}}
=== START OF OUTPUT ===
{
  errors: {
    asset: [
      "Invalid type value for block '1234567890'. Type must be defined in schema"
    ]
  }
}
==== END OF OUTPUT ====
02:11:49 pm - Added/Updated theme/assets/blah

The issue I think was that I was uploading new settings_data.json file before a /sections liquid file, which includes the schema for an included setting.

What I noticed was, if I wasn't already aware of that error, it would have been hard for me to figure out which file caused the error, as that is not included in the particular output there. At least with the concurrency settings I have, the files each side aren't much help. In fact, they were both images that are in /assets directory rather that settings_data (in /config) or the related section (in sections/)

Related sidenote: on qs theme upload it is essential that /sections directory is uploaded before config. I assume this is the case, but just thought I would mention :)

internalfx commented 2 years ago

@rickydazla Is this still an issue? I'm following up on everything to make sure I don't waste time chasing problems that no longer matter.

rickydazla commented 2 years ago

Hmm… the side note is true but the error logging is good I think

internalfx commented 2 years ago

@rickydazla ok, I'll take a closer look at this then.

internalfx commented 2 years ago

Closed by 009540a5b4acd2e8c9cd3b45f8541fee7c2353f6