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

upgrade assetgraph-builder with fixes #3412

Closed
wants to merge 7 commits into from

Conversation

boneskull
Copy link
Contributor

@boneskull boneskull added area: documentation anything involving docs or mochajs.org type: chore generally involving deps, tooling, configuration, etc. semver-patch implementation requires increase of "patch" version number; "bug fixes" labels Jun 8, 2018
@jsf-clabot
Copy link

jsf-clabot commented Jun 8, 2018

CLA assistant check
All committers have signed the CLA.

@papandreou
Copy link
Contributor

@boneskull, I tried to update the lockfile, but it produces a huge number of changes: papandreou@17ebed1

I used npm@5.6.0 to update it -- do you remember which version the lockfile was generated with? Maybe it'll help if I use that.

Copy link
Contributor

@outsideris outsideris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't know assetgraph well.

docs/_site/index.html is fine, but there is a broken link indocs/_dist/index.html.

2018-06-09 16 48 27

undefined-1.d41d8cd98f can be found in build result like:

       Html 74   1.7 MB
        Ico  2  29.5 KB
.d41d8cd98f  2     0 bytes
        Png  8 225.0 KB
        Svg  2   7.3 KB
        Css  5  50.9 KB
 JavaScript  4  24.0 KB
     Total: 97   2.0 MB

@outsideris
Copy link
Contributor

Additioanally, buildProduction took much longer than before this PR in my local.

before:

 ✔ 0.006 secs: reviewSubResourceIntegrity
 ✔ 47.618 secs: buildProduction
 ✔ 1.595 secs: writeAssetsToDisc

after:

 ✔ 2.965 secs: reviewSubResourceIntegrity
 ✔ 307.252 secs: buildProduction
 ✔ 2.071 secs: writeAssetsToDisc

@outsideris
Copy link
Contributor

I didn't test it with @papandreou 's commit.

@papandreou
Copy link
Contributor

@outsideris, thanks, will look into the undefined thing.

I'm aware that it's still slower than ag-b 5. I will get around to trace down the remaining performance regressions.

papandreou added a commit to assetgraph/assetgraph-builder that referenced this pull request Jun 9, 2018
Tweak handling of redirects to address the problem mentioned here:
mochajs/mocha#3412 (review)
@papandreou
Copy link
Contributor

I've fixed the problem with the bogus undefined-1.d41d8cd98f file now.

Will get back to the performance regressions at some point. If you find it too slow, you're welcome to just keep this open and wait.

@outsideris
Copy link
Contributor

I confirmed undefined-1.d41d8cd98f is fixed.

However, it doesn't make static directory at all. So, every references under static/ are broken.

@papandreou
Copy link
Contributor

@outsideris, you're right, I can reproduce that. It's a problem with the --canonicalroot switch. Looking into it.

papandreou added a commit to assetgraph/assetgraph-builder that referenced this pull request Jun 10, 2018
@papandreou
Copy link
Contributor

@outsideris, fixed now. Thanks for letting me know.

@outsideris
Copy link
Contributor

CI is failed.

npm ERR! cipm can only install packages when your package.json and package-lock.json or npm-shrinkwrap.json are in sync. Please update your lock file with `npm install` before continuing.
npm ERR! 
npm ERR! 
npm ERR! Invalid: lock file's assetgraph-builder@5.9.1 does not satisfy assetgraph-builder@^6.3.4
npm ERR! Invalid: lock file's svgo@0.7.2 does not satisfy svgo@^1.0.5

@papandreou
Copy link
Contributor

@outsideris, I also ran into that and commented: #3412 (comment)

@outsideris
Copy link
Contributor

@papandreou I missed that comment.
The precache job ran under node v10, so npm version is 6.1.0.

You can see it in the job logs.

$ npm --version
6.1.0

In my local, npm ci --ignore-scripts is works with npm@6.1.0.

@papandreou
Copy link
Contributor

@outsideris, ah, thanks. I've updated package-lock.json now by running a fresh npm install with npm 6.1.0.

Still seems like an awful lot of changes, though.

@coveralls
Copy link

coveralls commented Jun 11, 2018

Coverage Status

Coverage increased (+0.3%) to 90.289% when pulling 811f9bc on papandreou:fix/ag-b into eeccd05 on mochajs:master.

@papandreou
Copy link
Contributor

papandreou commented Jun 30, 2018

Improved the performance further in assetgraph-builder 6.4.1, here's the current build time on my laptop:

 ✔ 117.447 secs: buildProduction

Edit: And when connected to power and no world cup matches streaming in the background:

 ✔ 82.750 secs: buildProduction

Copy link
Contributor

@outsideris outsideris left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my local, it still slow:

 ✔ 3.298 secs: reviewSubResourceIntegrity
 ✔ 301.102 secs: buildProduction
 ✔ 2.478 secs: writeAssetsToDisc

But netify build is ok.

@papandreou
Copy link
Contributor

@outsideris, weird that it didn't improve more on your machine. I can't explain that.

@outsideris
Copy link
Contributor

@papandreou I tried it multiple time that delete node_modules and reinstall it. I will try to find the solution if I have time.

@papandreou
Copy link
Contributor

@outsideris, thanks for trying. I guess that just means I'm not done yet ;)

@plroebuck
Copy link
Contributor

@Munter, self-assign this one.

@Munter Munter self-assigned this Oct 11, 2018
@plroebuck
Copy link
Contributor

@papandreou, any status update on where this stands?

@papandreou
Copy link
Contributor

I haven't really been able to allocate time to do more profiling specifically targeting this particular build, sorry. Please consider using another build tool.

@plroebuck
Copy link
Contributor

Assuming actual time is closer to what you see (than Outsider), my question was to see if there were any other related bugs to shake out?

@papandreou
Copy link
Contributor

I'm not aware of any other issues, no.

@boneskull
Copy link
Contributor Author

I'm going to close this and retry with the latest version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: documentation anything involving docs or mochajs.org semver-patch implementation requires increase of "patch" version number; "bug fixes" type: chore generally involving deps, tooling, configuration, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants