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

fix: crash of file system when try to read cache dir file on android #13232

Merged
merged 2 commits into from
Jun 16, 2021

Conversation

numandev1
Copy link
Contributor

fixed #5408

Why

Should resolve to { exists: false } instead of throwing

How

getInfoAsync throws an error File <file path isn't readable>

Steps to Reproduce

try to read file from cacheDirectory it will throw an exception which this PR has fixed

Checklist

  • Documentation is up to date to reflect these changes (eg: https://docs.expo.io and README.md).
  • This diff will work correctly for expo build (eg: updated @expo/xdl).
  • This diff will work correctly for expo prebuild & EAS Build (eg: updated a module plugin).

Reproducible Demo

https://snack.expo.io/@charliecruzan/getinfoasyncerror

@numandev1 numandev1 requested a review from bbarthec as a code owner June 10, 2021 10:35
@expo-bot expo-bot added the bot: suggestions ExpoBot has some suggestions label Jun 10, 2021
Copy link
Collaborator

@expo-bot expo-bot left a comment

Choose a reason for hiding this comment

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

The review previously left here is no longer valid, jump to the latest one 👉 #13232 (review)

@numandev1 numandev1 changed the title fix: crash of file system when try to read cache dir for android fix: crash of file system when try to read cache dir file for android Jun 10, 2021
@numandev1 numandev1 changed the title fix: crash of file system when try to read cache dir file for android fix: crash of file system when try to read cache dir file on android Jun 10, 2021
@numandev1 numandev1 force-pushed the fix/crasah-filesystem-cache-dir branch from 85e5d27 to 67fe814 Compare June 10, 2021 10:53
Copy link
Collaborator

@expo-bot expo-bot left a comment

Choose a reason for hiding this comment

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

The review previously left here is no longer valid, jump to the latest one 👉 #13232 (review)

@brentvatne brentvatne requested a review from lukmccall June 10, 2021 18:28
Copy link
Contributor

@lukmccall lukmccall left a comment

Choose a reason for hiding this comment

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

Looks good to me 🚀
Please add a changelog entry and add a comment in the code why we need to strip the file scheme.

@numandev1 numandev1 force-pushed the fix/crasah-filesystem-cache-dir branch from 67fe814 to 82d02b9 Compare June 16, 2021 09:57
Copy link
Collaborator

@expo-bot expo-bot left a comment

Choose a reason for hiding this comment

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

The review previously left here is no longer valid, jump to the latest one 👉 #13232 (review)

@expo-bot expo-bot added bot: passed checks ExpoBot has nothing to complain about and removed bot: suggestions ExpoBot has some suggestions labels Jun 16, 2021
@numandev1 numandev1 force-pushed the fix/crasah-filesystem-cache-dir branch from 82d02b9 to 128e1ce Compare June 16, 2021 10:02
Copy link
Collaborator

@expo-bot expo-bot left a comment

Choose a reason for hiding this comment

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

The review previously left here is no longer valid, jump to the latest one 👉 #13232 (review)

@numandev1
Copy link
Contributor Author

@lukmccall i have done requested changes

Copy link
Collaborator

@expo-bot expo-bot left a comment

Choose a reason for hiding this comment

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

Hi there! 👋 I'm a bot whose goal is to ensure your contributions meet our guidelines.

Looks like I have nothing to complain about 👏 Keep up the good work! 💪

Generated by ExpoBot 🤖 against fef6804

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bot: passed checks ExpoBot has nothing to complain about
Projects
None yet
Development

Successfully merging this pull request may close these issues.

getInfoAsync throws when file doesn't exist
3 participants