Skip to content

Commit

Permalink
Merge pull request #8 from GenomicDataInfrastructure/6-some-character…
Browse files Browse the repository at this point in the history
…s-are-not-properly-displayed

6 some characters are not properly displayed
  • Loading branch information
brunopacheco1 authored Jan 25, 2024
2 parents 25ea735 + 53c2a82 commit f714d83
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ckanext/fairdatapoint/harvesters/domain/fair_data_point.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import logging
import requests
import encodings

from rdflib import Graph, URIRef
from rdflib.exceptions import ParserError
Expand Down Expand Up @@ -44,6 +45,7 @@ def _get_data(path: Union[str, URIRef]) -> Union[str, None]:
}
try:
response = requests.request("GET", path, headers=headers)
response.encoding = encodings.utf_8.getregentry().name
response.raise_for_status()
return response.text
except (HTTPError, ConnectionError, Timeout, RequestException) as e:
Expand Down

0 comments on commit f714d83

Please sign in to comment.