Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style(python-sdk): fix import order in client and configuration file templates #266

Merged
merged 1 commit into from
Jan 2, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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 @@ -30,15 +39,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
Loading