ember-cli / ember-cli/broccoli-asset-rev

Multiple fingerprinted assetMap.json files with v2.6.0

Open
#122 5 comments 9 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
86
Forks
79
PR merge metrics
No merged PRs in 30d

Description

* ember-cli 2.11.1
* broccoli-asset-rev 2.6.0

I'm getting multiple `assetMap.json` files with v2.6.0 when I have `fingerprintAssetMap: true`. One file is correct, while the other is empty. Also of note is that the empty asset map file is included in the other.

**assetMap-cd33192964e8c20af9391de38dbf449b.json:**
```
{
"assets": {
},
"prepend": "/"
}
```

**assetMap-103a2cd1042363eeb87594e00d9ab623.json:**
```
{
"assets": {
"assets/app.css": "assets/app-d41d8cd98f00b204e9800998ecf8427e.css",
"assets/app.js": "assets/app-471ff2328e75d6c15e58dd5d046f5e9c.js",
"assets/assetMap.json": "assets/assetMap-cd33192964e8c20af9391de38dbf449b.json",
...
},
"prepend": "/"
}
```

Having two files results in some production builds breaking because the empty asset map might be included. I didn't look into how it determines which file to load, but my guess is it's pulling in the first asset map it finds alphabetically, so it depends on the hashes being generated for each file and explains why its differs build to build.

Downgrading to 2.5.0 generates one file as expected.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.