Unverified Commit 82577697 authored by Florent Chehab's avatar Florent Chehab
Browse files

style(backend): run black on entire backend

* fixes small style relica
parent 6436f3cb
Pipeline #60638 failed with stages
in 3 minutes and 5 seconds
......@@ -101,7 +101,7 @@ class ExchangeFeedbackViewSet(EssentialModuleViewSet):
"university",
"exchange__student_major",
"exchange__student_minor",
"untouched"
"untouched",
)
required_filterset_fields = ("university",)
pagination_class = CustomPagination
......@@ -90,4 +90,4 @@ class VersionViewSet(BaseModelViewSet):
ct = ContentType.objects.get_for_id(content_type_id)
model = ct.model_class()
obj = model.objects.get(pk=object_pk)
return Version.objects.get_for_object(obj).order_by('revision_id')
return Version.objects.get_for_object(obj).order_by("revision_id")
......@@ -49,7 +49,9 @@ class FixerData(object):
with transaction.atomic():
response = requests.get(
"http://data.fixer.io/api/latest?access_key={}".format(self.FIXER_API_TOKEN)
"http://data.fixer.io/api/latest?access_key={}".format(
self.FIXER_API_TOKEN
)
)
data = response.json()
......@@ -90,7 +92,8 @@ class UtcData(object):
self.__import_opened_destinations,
)
paged_data_walk(
"{}/exchanges".format(self.UTC_API_ENDPOINT), self.__import_exchange_data
"{}/exchanges".format(self.UTC_API_ENDPOINT),
self.__import_exchange_data,
)
paged_data_walk(
"{}/courses".format(self.UTC_API_ENDPOINT), self.__import_course_data
......@@ -228,7 +231,9 @@ class UtcData(object):
),
)
# Don't forget to update the destination open status
Partner.objects.filter(utc_id=utc_partner_id).update(is_destination_open=True)
Partner.objects.filter(utc_id=utc_partner_id).update(
is_destination_open=True
)
def __import_course_data(self, response_content):
logger.info("Importing courses data")
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment