Skip to content

Commit

Permalink
style(python-sdk): fix import order in client and configuration file …
Browse files Browse the repository at this point in the history
…templates (#266)
  • Loading branch information
rhamzeh authored Jan 2, 2024
2 parents 21d92cc + dae682e commit b8618f3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
18 changes: 9 additions & 9 deletions config/clients/python/template/client/client.mustache
Original file line number Diff line number Diff line change
@@ -1,6 +1,15 @@
# coding: utf-8
{{>partial_header}}

{{#asyncio}}
import asyncio
{{/asyncio}}
{{^asyncio}}
import time
{{/asyncio}}
import uuid
from typing import List

from {{packageName}}.api_client import ApiClient
from {{packageName}}.api.open_fga_api import OpenFgaApi
from {{packageName}}.client.configuration import ClientConfiguration
Expand Down Expand Up @@ -31,15 +40,6 @@ from {{packageName}}.models.write_authorization_model_request import WriteAuthor
from {{packageName}}.models.write_request import WriteRequest
from {{packageName}}.validation import is_well_formed_ulid_string

{{#asyncio}}
import asyncio
{{/asyncio}}
{{^asyncio}}
import time
{{/asyncio}}
import uuid
from typing import List

CLIENT_METHOD_HEADER = "X-OpenFGA-Client-Method"
CLIENT_BULK_REQUEST_ID_HEADER = "X-OpenFGA-Client-Bulk-Request-Id"

Expand Down
5 changes: 3 additions & 2 deletions config/clients/python/template/configuration.mustache
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,12 @@ import logging
import multiprocessing
{{/asyncio}}
import sys
import urllib3
from urllib.parse import urlparse

import urllib3
import six
from six.moves import http_client as httplib
from urllib.parse import urlparse

from {{packageName}}.exceptions import FgaValidationException, ApiValueError
from {{packageName}}.validation import is_well_formed_ulid_string

Expand Down

0 comments on commit b8618f3

Please sign in to comment.