When using Feeds with Feeds: Facebook parser module to get events from a Facebook page the cover photos of the event cannot be saved on the website.

When importing the events, the following error occurs:

The specified file https://scontent.xx.fbcdn.net/v/t31.0-8/s720x720/16903348_11025435732083... could not be copied, because no file by that name exists. Please check that you supplied the correct filename.

On the Recent log messages page the following error for type of File occurs:

File https://scontent.xx.fbcdn.net/v/t31.0-8/s720x720/16903348_11025435732083... (https://scontent.xx.fbcdn.net/v/t31.0-8/s720x720/16903348_11025435732083...) could not be copied because it does not exist.

as well as a log message of Feeds type:

Invalid enclosure https://scontent.xx.fbcdn.net/v/t31.0-8/s720x720/16903348_11025435732083...

The node gets created, but the image doesn't get saved, thus doesn't get displayed.

Comments

zoltan.tudlik created an issue. See original summary.

zoltan.tudlik’s picture

Title: Error copying Facebook event covers » Error fetching Facebook event covers
zoltan.tudlik’s picture

Status: Active » Needs review
StatusFileSize
new642 bytes

Attached the solution, which has been tested and working on our website.

This is a suggested change in any case, since drupal_realpath() is deprecated from in Drupal 8.0.x-dev+.

Status: Needs review » Needs work

The last submitted patch, 3: feeds-facebook-cover-2856478-0.patch, failed testing.

megachriz’s picture

@zoltan.tudlik
Can you provide an export of your importer and a sample source file? This will make it easier to reproduce the problem.

zoltan.tudlik’s picture

StatusFileSize
new3.97 KB
new9.97 KB

@MegaChriz
I've uploaded the export of my importer. Please also find attached the parser, which I use during parsing, since it's a costume, so the error might be caused there.

Do you also need a link to the Facebook page feed?

megachriz’s picture

@zoltan.tudlik
Yes, an import source to test with would also be needed. You can provide the link, but since a link can die, please also attach the source file to this issue. I've other stuff to do on Feeds first, so it may take a while before I will take a closer look at this issue (by that time the link could have died).

By glancing through the code of the attached module, it doesn't look like the issue is caused by that module: it doesn't use file functions or make HTTP calls.

Do you know how to write automated tests or would you like help to write one? If so, it would be helpful if you could write a test that demonstrates the issue.

bluegeek9’s picture

Status: Needs work » Closed (outdated)

Drupal 7 reached end of life and the D7 version of Feeds is no longer being developed. To keep the issue queue focused on supported versions, we’re closing older D7 issues.

If you still have questions about using Feeds on Drupal 7, feel free to ask. While we won’t fix D7 bugs anymore, we’re happy to offer guidance to help you move forward. You can do so by opening (or reopening) a D7 issue, or by reaching out in the #feeds channel on Drupal Slack.

If this issue is still relevant for Drupal 10+, please open a follow-up issue or merge request with proposed changes. Contributions are always welcome!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.