Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a debugging guide #89

Open
chasenlehara opened this issue Nov 15, 2017 · 0 comments

Comments

Projects
None yet
1 participant
@chasenlehara
Copy link
Contributor

commented Nov 15, 2017

TLDR: add a guide that explains how to debug issues that aren’t covered by steal’s awesome error messages.

This was discussed on a recent live stream (8:15).

Motivation

Steal’s error messages are really useful in debugging common issues. However, sometimes a file doesn’t load or exist, or there’s an error from something other than steal, or no error is shown at all.

Here are some examples of issues that people would hopefully be able to figure out on their own if they had a debugging guide to reference:

Solution

Let’s create a debugging guide that:

  1. Explains how to debug specific scenarios.
  2. Includes steps to debug generic steal & steal-tools issues.

This would serve as a catch-all for debugging steal issues for which we can’t show a better error message. The “generic” debugging section would include all the things that Manuel & Matthew know to try / look for when debugging issues.

The initial guide could have enough information to debug the issues above, then we could add to it over time (just like with error messages) as other questions/issues arise.

Inspiration

I originally filed this issue in 2017 with the following text:

I just paired with Manuel on an issue and he gave me some helpful tips for debugging a production build.

First, we set bundlePromisePolyfill, minify, sourceMaps, and sourceMapsContent to false in the steal-tools build options:

var buildPromise = stealTools.build({
    config: __dirname + "/package.json!npm"
}, {
    bundlePromisePolyfill: false,
    minify: false,
    sourceMaps: false,
    sourceMapsContent: false,
    dest: __dirname + "/target"
});

Second, we used the production.html in the project and changed the script tag to:

<script src="./node_modules/steal/steal-sans-promises.js" env="production" main="steal-canjs-example/app" bundles-path="target/bundles"></script>

This got us to the point where we could see what was throwing the error. It’d be helpful if these starter tips were in a guide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.