After building on EAS for iOS using profile production, my SVG asset is failing to load. It appears to be failing to load from cloud front, but the asset is locally bundled.
Unfortunately, if I do a dev-client build the asset loads. I only see this problem with a full production build.
I downloaded the IPA from EAS and can see the asset in the package.
Contents of the asset in production according to Sentry
<?xml version="1.0" encoding="UTF-8"?>
<Error><Code>AccessDenied</Code><Message>Access Denied</Message><RequestId>1AG9BA8T0A244909</RequestId><HostId>JpVv+xOMRTepEDplL2LjIkKXx6fnbpYPBsokJHjUO56eqPo+bJcyAwMNqUHKou+fJscAuZlhGts=</HostId></Error>
In my config
packagerOpts: {
assetExts: ["min.svg"]
},
Usage
const svg = require("../../assets/svg/table.min.svg")
async function fetchLocalFile(setState) {
const file = Asset.fromModule(svg)
await file.downloadAsync() // Optional, saves file into cache
const asset = await fetch(file.uri)
const contents = await asset.text()
setState(contents);
}
What else should I be looking at? I’ve been scouring the docs trying to understand why this error is happening and what request is being made that is failing.