Plots2: Broken Image Links

Created on 26 May 2021  路  8Comments  路  Source: publiclab/plots2

Please describe the problem (or idea)

Posts without images have broken image links

Screenshot 2021-05-26 at 09 41 16

What did you expect to see that you didn't?

Rounded circles for posts without images

Please show us where to look

https://stable.publiclab.org/v2/dashboard

What's your PublicLab.org username?

mathildaudufo


Thank you!

Your help makes Public Lab better! We deeply appreciate your helping refine and improve this site.

To learn how to write really great issues, which increases the chances they'll be resolved, see:

https://publiclab.org/wiki/developers#Contributing+for+non-coders

bug

Most helpful comment

@cgrkzlkn I played around with the code and didn't see anything wrong with it. The image upload allows any kind of file so sometimes a user might add a wrong file or a broken image. If you look at the image pasted above you'll notice that they are from the same user.

@cgrkzlkn @ahcodes Thank you for all the help 鉂わ笍

All 8 comments

Hi! I can try working on this but I might need some guidance since I'm a newbie.

@ahcodes Sure happy to help.

A good place to start would be here.
https://github.com/publiclab/plots2/blob/596ff0c8c81d459857cd9e758b26ec419e0ee4a5/app/views/dashboard_v2/_topicCard.html.erb#L36

For some reason the image being returned by the scraped_image method is broken. Try to find out what src that method is returning.
https://github.com/publiclab/plots2/blob/596ff0c8c81d459857cd9e758b26ec419e0ee4a5/app/models/node.rb#L353-L356

If this is confusing or you need more help, don't hesitate to ask. Thanks!

@TildaDares I would like to work on this too, i couldn't manage to debug the project with byebug. Any help would be great!

@cgrkzlkn Let's give @ahcodes sometime to work on this. You can search for other issues to work on for now. Thanks!

@TildaDares Thanks for giving me time to go over this but I think it's a bit too advanced for me. Especially since I don't know any Ruby. I think @cgrkzlkn would love to be assigned to this in my place.

Thanks for trying @ahcodes 鉂わ笍. @cgrkzlkn you can go ahead and try.

@TildaDares I would like to work on this too, i couldn't manage to debug the project with byebug. Any help would be great!

Thanks @TildaDares , any help with this? I need to debug to find out what is returned from the method.

@cgrkzlkn I played around with the code and didn't see anything wrong with it. The image upload allows any kind of file so sometimes a user might add a wrong file or a broken image. If you look at the image pasted above you'll notice that they are from the same user.

@cgrkzlkn @ahcodes Thank you for all the help 鉂わ笍

Was this page helpful?
0 / 5 - 0 ratings

Related issues

first-timers[bot] picture first-timers[bot]  路  3Comments

divyabaid16 picture divyabaid16  路  3Comments

keshavsethi picture keshavsethi  路  3Comments

grvsachdeva picture grvsachdeva  路  3Comments

noi5e picture noi5e  路  3Comments