-
Notifications
You must be signed in to change notification settings - Fork 24.4k
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
Image headers unsupported when an array of sources is provided #13697
Comments
0.45 Android still not working |
Summary: A copy of #7791 because of our very imperfect tools that mirror the changes from pull requests in the fb monorepo. The internal Phabricator revision for #7791 is in an 'abandoned' state (by foghina probably because of changing teams) and Phabricator doesn't allow me to claim that revision and merge it. Therefore I'm creating a new one. (It's not foghina's fault, no one probably knew about this "abandoned Phabricator revision" edge case, don't remember we hit it before.) Will try to keep attribution (git blame) to rigdern when merging. Closes #12448 Differential Revision: D4584743 Pulled By: mkonicek fbshipit-source-id: 66e5b88134fca1980adc4cd8a2ff17c42e10022c
As far as I can tell, this is not currently supported. You may want to submit a PR that adds support for per-source headers. |
I am working on this, any guidance would be gladly welcome |
@facebook-github-bot no-template |
Hey, thanks for reporting this issue! It looks like your description is missing some necessary information, or the list of reproduction steps is not complete. Can you please add all the details specified in the Issue Template? This is necessary for people to be able to understand and reproduce the issue being reported. I am going to close this, but feel free to open a new issue with the additional information provided. Thanks! See "What to Expect from Maintainers" to learn more. |
Looks like #16155 was merged, thanks @phillip055 |
Summary: This sync includes the following changes: - **[d83601080](facebook/react@d83601080)**: Wrap retrySuspendedRoot using SchedulerTracing (#13776) //<Sophie Alpert>// - **[40a521aa7](facebook/react@40a521aa7)**: Terminology: Functional -> Function Component (#13775) //<Dan Abramov>// - **[605ab10a4](facebook/react@605ab10a4)**: Add envify transform to scheduler package (#13766) //<Michael Ridgway>// - **[acc7f404c](facebook/react@acc7f404c)**: Restart from root if promise pings before end of render phase (#13774) //<Andrew Clark>// - **[cbc224028](facebook/react@cbc224028)**: fix - small misspelling (#13768) //<Spencer Davies>// - **[4eabeef11](facebook/react@4eabeef11)**: Rename ReactSuspenseWithTestRenderer-test -> ReactSuspense-test //<Andrew Clark>// - **[95a3e1c2e](facebook/react@95a3e1c2e)**: Rename ReactSuspense-test -> ReactSuspenseWithNoopRenderer-test //<Andrew Clark>// - **[96bcae9d5](facebook/react@96bcae9d5)**: Jest + test renderer helpers for concurrent mode (#13751) //<Andrew Clark>// - **[5c783ee75](facebook/react@5c783ee75)**: Remove unreachable code (#13762) //<Heaven>// - **[36c5d69ca](facebook/react@36c5d69ca)**: Always warn about legacy context within StrictMode tree (#13760) //<Brian Vaughn>// - **[3e9a5de88](facebook/react@3e9a5de88)**: UMD react-cache build (#13761) //<Maksim Markelov>// - **[8315a30b9](facebook/react@8315a30b9)**: --save is no longer needed (#13756) //<Joe Cortopassi>// - **[ce96e2df4](facebook/react@ce96e2df4)**: Rename simple-cache-provider to react-cache (#13755) //<Andrew Clark>// - **[c5212646f](facebook/react@c5212646f)**: Removed extra typeof checks for contextType.unstable_read (#13736) //<Brian Vaughn>// - **[806eebdae](facebook/react@806eebdae)**: Enable getDerivedStateFromError (#13746) //<Brian Vaughn>// - **[a0733fe13](facebook/react@a0733fe13)**: pure (#13748) //<Andrew Clark>// - **[4d17c3f05](facebook/react@4d17c3f05)**: [scheduler] Improve naive fallback version used in non-DOM environments //<Andrew Clark>// - **[469005d87](facebook/react@469005d87)**: Revise `AttributeType` React Native Flow Type (#13737) //<Timothy Yung>// - **[0dc0ddc1e](facebook/react@0dc0ddc1e)**: Rename AsyncMode -> ConcurrentMode (#13732) //<Dominic Gannaway>// - **[7601c3765](facebook/react@7601c3765)**: Ensure "addEventListener" exists on "window" for "scheduler" package (#13731) //<Dominic Gannaway>// - **[d0c0ec98e](facebook/react@d0c0ec98e)**: Added a PureComponent contextType test (#13729) //<Brian Vaughn>// - **[4b68a6498](facebook/react@4b68a6498)**: Support class component static contextType attribute (#13728) //<Brian Vaughn>// - **[f305d2a48](facebook/react@f305d2a48)**: [scheduler] Priority levels, continuations, and wrapped callbacks (#13720) //<Andrew Clark>// - **[970a34bae](facebook/react@970a34bae)**: Bump babel-eslint and remove flow supressions (#13727) //<Brian Ng>// - **[13965b4d3](facebook/react@13965b4d3)**: Interaction tracking ref-counting bug fixes (WIP) (#13590) //<Brian Vaughn>// - **[17e703cb9](facebook/react@17e703cb9)**: Restore global window.event after event dispatching (#13688) (#13697) //<Sergei Startsev>// - **[a775a767a](facebook/react@a775a767a)**: Remove redundant logic (#13502) //<Heaven>// - **[e1a067dea](facebook/react@e1a067dea)**: Fix circular dependency in TracingSubscriptions (#13689) //<Maksim Markelov>// - **[518812eeb](facebook/react@518812eeb)**: Clarify comment (#13684) //<Heaven>// - **[eeb817785](facebook/react@eeb817785)**: Remove some old files from stats //<Dan>// - **[7ea3ca1d1](facebook/react@7ea3ca1d1)**: Rename schedule to scheduler (#13683) //<Dan Abramov>// - **[bec2ddaf1](facebook/react@bec2ddaf1)**: Update bundle sizes for 16.5.2 release //<Brian Vaughn>// - **[4269fafb0](facebook/react@4269fafb0)**: Updating package versions for release 16.5.2 //<Brian Vaughn>// - **[4380f9ba1](facebook/react@4380f9ba1)**: Revert "Updating package versions for release 16.6.0-alpha.0" //<Brian Vaughn>// - **[72fad84e7](facebook/react@72fad84e7)**: Revert "Updating dependencies for react-noop-renderer" //<Brian Vaughn>// - **[c3fad5acf](facebook/react@c3fad5acf)**: Revert "Update bundle sizes for 16.6.0-alpha.0 release" //<Brian Vaughn>// - **[dd9120561](facebook/react@dd9120561)**: Kepp calling peformWork consistent (#13596) //<Heaven>// - **[42d12317a](facebook/react@42d12317a)**: Update bundle sizes for 16.6.0-alpha.0 release //<Brian Vaughn>// - **[489614c4f](facebook/react@489614c4f)**: Updating dependencies for react-noop-renderer //<Brian Vaughn>// - **[351c9015c](facebook/react@351c9015c)**: Updating package versions for release 16.6.0-alpha.0 //<Brian Vaughn>// - **[a210b5b44](facebook/react@a210b5b44)**: Revert "Do not bind topLevelType to dispatch" (#13674) //<Dan Abramov>// - **[1d8a75fef](facebook/react@1d8a75fef)**: remove flow typings from Schedule.js (#13662) //<Alexey Raspopov>// - **[d92114b98](facebook/react@d92114b98)**: Resubmit: Fix updateWrapper causing re-render textarea, even though their data (#13643) //<Nathan Hunzaker>// - **[0c9c591bf](facebook/react@0c9c591bf)**: Do not bind topLevelType to dispatch (#13618) //<Nathan Hunzaker>// - **[9f819a5ea](facebook/react@9f819a5ea)**: [schedule] Refactor Schedule, remove React-isms (#13582) //<Andrew Clark>// - **[9c961c0a2](facebook/react@9c961c0a2)**: Fix some iframe edge cases (#13650) //<Jérôme Steunou>// - **[8bc0bcabe](facebook/react@8bc0bcabe)**: Add UMD production+profiling entry points (#13642) //<Brian Vaughn>// - **[b488a5d9c](facebook/react@b488a5d9c)**: Fix test comment typo (#13568) //<Heaven>// - **[4bcee5621](facebook/react@4bcee5621)**: Rename "tracking" API to "tracing" (#13641) //<Brian Vaughn>// - **[72217d081](facebook/react@72217d081)**: Update bundle sizes for 16.5.1 release //<Dan Abramov>// - **[8b93a60c5](facebook/react@8b93a60c5)**: Updating package versions for release 16.5.1 //<Dan Abramov>// - **[ecbf7af40](facebook/react@ecbf7af40)**: Enhance dev warnings for forwardRef render function (#13627) (#13636) //<Andres Rojas>// - **[228240085](facebook/react@228240085)**: Delete TapEventPlugin (#13630) //<Dan Abramov>// - **[a079011f9](facebook/react@a079011f9)**: ð Stop syncing the value attribute on inputs (behind a feature flag) (#13526) //<Nathan Hunzaker>// - **[a7bd7c3c0](facebook/react@a7bd7c3c0)**: Allow reading default feature flags from bundle tests (#13629) //<Dan Abramov>// - **[d3bbfe09c](facebook/react@d3bbfe09c)**: Fix IE version in comment //<Dan Abramov>// - **[1b2646a40](facebook/react@1b2646a40)**: Fix warning without stack for ie9 (#13620) //<Aliaksandr Manzhula>// - **[e49f3ca08](facebook/react@e49f3ca08)**: honor displayName set on ForwardRef if available (#13615) //<Evan Jacobs>// Release Notes: [GENERAL] [FEATURE] [React] - React sync for revisions ade5e69...d836010 Reviewed By: bvaughn Differential Revision: D10118547 fbshipit-source-id: ecde7ada80331abdc8bd7d279e0f3dbe9acde071
Summary: This sync includes the following changes: - **[d83601080](facebook/react@d83601080)**: Wrap retrySuspendedRoot using SchedulerTracing (#13776) //<Sophie Alpert>// - **[40a521aa7](facebook/react@40a521aa7)**: Terminology: Functional -> Function Component (#13775) //<Dan Abramov>// - **[605ab10a4](facebook/react@605ab10a4)**: Add envify transform to scheduler package (#13766) //<Michael Ridgway>// - **[acc7f404c](facebook/react@acc7f404c)**: Restart from root if promise pings before end of render phase (#13774) //<Andrew Clark>// - **[cbc224028](facebook/react@cbc224028)**: fix - small misspelling (#13768) //<Spencer Davies>// - **[4eabeef11](facebook/react@4eabeef11)**: Rename ReactSuspenseWithTestRenderer-test -> ReactSuspense-test //<Andrew Clark>// - **[95a3e1c2e](facebook/react@95a3e1c2e)**: Rename ReactSuspense-test -> ReactSuspenseWithNoopRenderer-test //<Andrew Clark>// - **[96bcae9d5](facebook/react@96bcae9d5)**: Jest + test renderer helpers for concurrent mode (#13751) //<Andrew Clark>// - **[5c783ee75](facebook/react@5c783ee75)**: Remove unreachable code (#13762) //<Heaven>// - **[36c5d69ca](facebook/react@36c5d69ca)**: Always warn about legacy context within StrictMode tree (#13760) //<Brian Vaughn>// - **[3e9a5de88](facebook/react@3e9a5de88)**: UMD react-cache build (#13761) //<Maksim Markelov>// - **[8315a30b9](facebook/react@8315a30b9)**: --save is no longer needed (#13756) //<Joe Cortopassi>// - **[ce96e2df4](facebook/react@ce96e2df4)**: Rename simple-cache-provider to react-cache (#13755) //<Andrew Clark>// - **[c5212646f](facebook/react@c5212646f)**: Removed extra typeof checks for contextType.unstable_read (#13736) //<Brian Vaughn>// - **[806eebdae](facebook/react@806eebdae)**: Enable getDerivedStateFromError (#13746) //<Brian Vaughn>// - **[a0733fe13](facebook/react@a0733fe13)**: pure (#13748) //<Andrew Clark>// - **[4d17c3f05](facebook/react@4d17c3f05)**: [scheduler] Improve naive fallback version used in non-DOM environments //<Andrew Clark>// - **[469005d87](facebook/react@469005d87)**: Revise `AttributeType` React Native Flow Type (#13737) //<Timothy Yung>// - **[0dc0ddc1e](facebook/react@0dc0ddc1e)**: Rename AsyncMode -> ConcurrentMode (#13732) //<Dominic Gannaway>// - **[7601c3765](facebook/react@7601c3765)**: Ensure "addEventListener" exists on "window" for "scheduler" package (#13731) //<Dominic Gannaway>// - **[d0c0ec98e](facebook/react@d0c0ec98e)**: Added a PureComponent contextType test (#13729) //<Brian Vaughn>// - **[4b68a6498](facebook/react@4b68a6498)**: Support class component static contextType attribute (#13728) //<Brian Vaughn>// - **[f305d2a48](facebook/react@f305d2a48)**: [scheduler] Priority levels, continuations, and wrapped callbacks (#13720) //<Andrew Clark>// - **[970a34bae](facebook/react@970a34bae)**: Bump babel-eslint and remove flow supressions (#13727) //<Brian Ng>// - **[13965b4d3](facebook/react@13965b4d3)**: Interaction tracking ref-counting bug fixes (WIP) (#13590) //<Brian Vaughn>// - **[17e703cb9](facebook/react@17e703cb9)**: Restore global window.event after event dispatching (#13688) (#13697) //<Sergei Startsev>// - **[a775a767a](facebook/react@a775a767a)**: Remove redundant logic (#13502) //<Heaven>// - **[e1a067dea](facebook/react@e1a067dea)**: Fix circular dependency in TracingSubscriptions (#13689) //<Maksim Markelov>// - **[518812eeb](facebook/react@518812eeb)**: Clarify comment (#13684) //<Heaven>// - **[eeb817785](facebook/react@eeb817785)**: Remove some old files from stats //<Dan>// - **[7ea3ca1d1](facebook/react@7ea3ca1d1)**: Rename schedule to scheduler (#13683) //<Dan Abramov>// - **[bec2ddaf1](facebook/react@bec2ddaf1)**: Update bundle sizes for 16.5.2 release //<Brian Vaughn>// - **[4269fafb0](facebook/react@4269fafb0)**: Updating package versions for release 16.5.2 //<Brian Vaughn>// - **[4380f9ba1](facebook/react@4380f9ba1)**: Revert "Updating package versions for release 16.6.0-alpha.0" //<Brian Vaughn>// - **[72fad84e7](facebook/react@72fad84e7)**: Revert "Updating dependencies for react-noop-renderer" //<Brian Vaughn>// - **[c3fad5acf](facebook/react@c3fad5acf)**: Revert "Update bundle sizes for 16.6.0-alpha.0 release" //<Brian Vaughn>// - **[dd9120561](facebook/react@dd9120561)**: Kepp calling peformWork consistent (#13596) //<Heaven>// - **[42d12317a](facebook/react@42d12317a)**: Update bundle sizes for 16.6.0-alpha.0 release //<Brian Vaughn>// - **[489614c4f](facebook/react@489614c4f)**: Updating dependencies for react-noop-renderer //<Brian Vaughn>// - **[351c9015c](facebook/react@351c9015c)**: Updating package versions for release 16.6.0-alpha.0 //<Brian Vaughn>// - **[a210b5b44](facebook/react@a210b5b44)**: Revert "Do not bind topLevelType to dispatch" (#13674) //<Dan Abramov>// - **[1d8a75fef](facebook/react@1d8a75fef)**: remove flow typings from Schedule.js (#13662) //<Alexey Raspopov>// - **[d92114b98](facebook/react@d92114b98)**: Resubmit: Fix updateWrapper causing re-render textarea, even though their data (#13643) //<Nathan Hunzaker>// - **[0c9c591bf](facebook/react@0c9c591bf)**: Do not bind topLevelType to dispatch (#13618) //<Nathan Hunzaker>// - **[9f819a5ea](facebook/react@9f819a5ea)**: [schedule] Refactor Schedule, remove React-isms (#13582) //<Andrew Clark>// - **[9c961c0a2](facebook/react@9c961c0a2)**: Fix some iframe edge cases (#13650) //<Jérôme Steunou>// - **[8bc0bcabe](facebook/react@8bc0bcabe)**: Add UMD production+profiling entry points (#13642) //<Brian Vaughn>// - **[b488a5d9c](facebook/react@b488a5d9c)**: Fix test comment typo (#13568) //<Heaven>// - **[4bcee5621](facebook/react@4bcee5621)**: Rename "tracking" API to "tracing" (#13641) //<Brian Vaughn>// - **[72217d081](facebook/react@72217d081)**: Update bundle sizes for 16.5.1 release //<Dan Abramov>// - **[8b93a60c5](facebook/react@8b93a60c5)**: Updating package versions for release 16.5.1 //<Dan Abramov>// - **[ecbf7af40](facebook/react@ecbf7af40)**: Enhance dev warnings for forwardRef render function (#13627) (#13636) //<Andres Rojas>// - **[228240085](facebook/react@228240085)**: Delete TapEventPlugin (#13630) //<Dan Abramov>// - **[a079011f9](facebook/react@a079011f9)**: ð Stop syncing the value attribute on inputs (behind a feature flag) (#13526) //<Nathan Hunzaker>// - **[a7bd7c3c0](facebook/react@a7bd7c3c0)**: Allow reading default feature flags from bundle tests (#13629) //<Dan Abramov>// - **[d3bbfe09c](facebook/react@d3bbfe09c)**: Fix IE version in comment //<Dan Abramov>// - **[1b2646a40](facebook/react@1b2646a40)**: Fix warning without stack for ie9 (#13620) //<Aliaksandr Manzhula>// - **[e49f3ca08](facebook/react@e49f3ca08)**: honor displayName set on ForwardRef if available (#13615) //<Evan Jacobs>// Release Notes: [GENERAL] [FEATURE] [React] - React sync for revisions ade5e69...d836010 Reviewed By: bvaughn Differential Revision: D10118547 fbshipit-source-id: ecde7ada80331abdc8bd7d279e0f3dbe9acde071
I'm trying to use the new
headers
prop on images in Android. I've managed to get it working on Android but it didn't behave as expected (and I believe its undocumented so was guessing on how to use it).For a simple image source it works fine, something like this:
But in my case I want to pass an array of different sized images. I assumed this would be the correct approach:
But that doesn't work (and the error message that comes back when my auth fails does seem to have any information in it). Looking at this code, I noticed that it always expects the
headers
prop to be at the top level, so one headers prop for all images (unlike thecache
prop which is one per uri). As the source object is an array, so I ended up with something like this:Is this by design? It doesn't feel quite right to me - I was expecting the
headers
prop to be treated more the thecache
prop. Having said that, I can't see any evidence of thecache
header being implemented in android.The text was updated successfully, but these errors were encountered: