ember-cli / ember-cli/ember-cli-htmlbars

Parallel compilations appears to troll hash-for-dep cache

未关闭
#623 6 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
JavaScript
星标
77
派生
65
PR 合并指标
30 天内没有已合并 PR

描述

I noticed that rebuild time for a particular addon (with a lot of handlebars AST transforms) recently ballooned from a few seconds to 80-90 seconds.

It appears that something (I'm guessing the parallel compile) is causing `hash-for-dep` to be invoked as multiple modules, instead of a single module. Since the `hash-for-dep` cache [is module scoped](https://github.com/stefanpenner/hash-for-dep/blob/master/index.js#L10), invoking as multiple modules means that the cache is effectively useless.

EDIT: The cache was only created once in `ember-cli-htmlbars-inline-precompile@1.0.2`. When I upgraded to `1.0.3` is when the multiple caches thing happened. There were other things also upgraded though at the same time.

cc @stefanpenner

贡献指南

这个仓库没有索引到贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。