library-pals / bookmark-action

🔖 A GitHub action to bookmark websites to a JSON file
https://katydecorah.com/code/bookmark-action/
MIT License
30 stars 6 forks source link

Process completed with exit code 3. #138

Closed flamedfury closed 1 year ago

flamedfury commented 1 year ago

Hello @katydecorah, me again.

I recently tried to save a bunch of bookmarks that failed with the error: Process completed with exit code 3.

It appears to be an issue with the download of the thumbnail image:

Download the thumbnail image

1s
Run curl "" -o "img/"
  curl "" -o "img/"
  shell: /bin/bash -e {0}
  env:
    DateBookmarked: 2023-07-02
    BookmarkTitle: How Websites Die
curl: (3) URL rejected: No host part in the URL
Error: Process completed with exit code 3.

Examples:

katydecorah commented 1 year ago

@flamedfury Looks like some of these URLs don't have images, so they fail at that step. Try adding the following if statement to your workflow:

https://github.com/katydecorah/bookmark-action/blob/c39bd1ac8121a5d461a4fbb7ac3224fa161edfb8/.github/workflows/bookmarks.yml#L32-L34

This will skip the download step and prevent the build from failing when there is no image to download.

flamedfury commented 1 year ago

Thanks, have run back through most of them. I think they've successfully run.

I'll have to go in and manually add some images for them.

This has given me a new idea...

katydecorah commented 1 year ago

Great! Closing here, please re-open if this didn't fix it :)