Skip to content

Commit

Permalink
Catch ConnectionError to skip enrichment when we cannot dowenload.
Browse files Browse the repository at this point in the history
  • Loading branch information
breyten committed Jul 15, 2024
1 parent 0c41ea9 commit 8505210
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -111,11 +111,11 @@ services:
# - reindex.remote.whitelist=elastic:9200
postgres:
image: "postgres:${POSTGRES_VERSION}"
command: -c config_file=/etc/postgresql.conf
#command: -c config_file=/etc/postgresql.conf
networks:
- ori
volumes:
- ./postgresql.conf:/etc/postgresql.conf
# - ./postgresql.conf:/etc/postgresql.conf
- pgdata:/var/lib/postgresql/data

volumes:
Expand Down
2 changes: 1 addition & 1 deletion ocd_backend/enrichers/text_enricher/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ def enrich_item(self, item):
identifier,
date_modified,
)
except requests.HTTPError as e:
except (ConnectionError, requests.HTTPError) as e:
raise SkipEnrichment(e)

item.content_type = resource.content_type
Expand Down

0 comments on commit 8505210

Please sign in to comment.