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

Errors when opening a post from hashtag search #262

Open
fedeolto opened this issue Feb 3, 2025 · 1 comment
Open

Errors when opening a post from hashtag search #262

fedeolto opened this issue Feb 3, 2025 · 1 comment
Labels
ui user interface

Comments

@fedeolto
Copy link

fedeolto commented Feb 3, 2025

When tapping a blurred image that stays blurred no matter how much you wait, you land on a page showing undefined Nan, Nan (see screenshots down)

For the case happened to me I investigated which url is related to the problematic image and it's a pubeurope.com image that returns 403 once you try to fetch it.

My idea is to submit a PR where in the onError callback of FastImage in [id].tsx the problem is catched and the image is not returned in the grid, kinda like this (see the last but one line).

Would it be an acceptable solution?

<FastImage
          source={{
            uri: item.media_attachments[0].url,
          }}
          style={{
            width: IMAGE_WIDTH,
            height: IMAGE_WIDTH,
          }}
          resizeMode={FastImage.resizeMode.cover}


          onError={() => doSomethingToPreventTheRenderOfThisInstance()}


/>

Image

Image

@Simon-Laux Simon-Laux added the bug Something isn't working label Feb 3, 2025
@Kwasow
Copy link
Collaborator

Kwasow commented Feb 4, 2025

Sounds like a good idea! We welcome all contributions, so feel free to open a PR with your changes.

Maybe we could show an error like in #237? That would mean you probably have to wait until it's merged before you submit your PR. If you like that idea I'll try to get it merged faster.

Edit: Oh, wait. You meant we could not show the image at all right? That's probably a better solution, feel free to implement it.

@Simon-Laux Simon-Laux added ui user interface and removed bug Something isn't working labels Feb 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ui user interface
Projects
None yet
Development

No branches or pull requests

3 participants