Sway DevX - Error Reporting

As I’ve used the Fuel tech stack more and more, I’ve feel like I’ve made steps to make the following process faster and faster:

  1. Make code change
  2. Compile code
  3. Identify error to target

There is an issue that developers will face if they try to compile everything (i.e. multiple modules) at once.

If there is a module dependency which fails to compile, the compiler will act as if that type doesn’t exist from that module.

Then every use of that type will print an error to the console.

1 simple error in a dependency file can result in 100s of downstream errors for files that rely on an upstream dependency.

Even within the same file it will still the remaining even though a dependency has errors within it, flagging it as type "{unknown}".

I’m having trouble reproducing the exact scenario where there are cascading errors that really pile up.

If anyone has encountered something similar or can reproduce the exact scenario of cascading errors, please feel free to comment below.

Excited to be apart of the Fuel dev community and thanks to the Fuel Labs team for all their support.

  • alphak3y
1 Like

Hey @alphaK3Y, what you mention is common with various compilers (if not all). You get a stack trace of some sort (with some errors that make no sense :smiley: ) , Just for missing something small like END IF or a semi-colon.

The error message that usually matters is just the last one on the console. I wouldn’t stress too much about that