Skip to content

Commit 1f98394

Browse files
authored
Use absolute imports (#57)
* use absolute imports
1 parent cc9b307 commit 1f98394

File tree

9 files changed

+12
-12
lines changed

9 files changed

+12
-12
lines changed

centml/cli/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
from .main import cli, ccluster
1+
from centml.cli.main import cli, ccluster

centml/cli/cluster.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import platform_api_client
55
from platform_api_client.models.endpoint_ready_state import EndpointReadyState
66
from platform_api_client.models.deployment_status import DeploymentStatus
7-
from ..sdk import api
7+
from centml.sdk import api
88

99

1010
# Custom class to parse key-value pairs for env variables for inference deployment

centml/cli/login.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import click
22

3-
from ..sdk import auth, config
3+
from centml.sdk import auth, config
44

55

66
@click.command(help="Login to CentML")

centml/cli/main.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import click
22

3-
from .login import login, logout
4-
from .cluster import ls, get, create, delete, pause, resume
3+
from centml.cli.login import login, logout
4+
from centml.cli.cluster import ls, get, create, delete, pause, resume
55

66

77
@click.group()
@@ -15,7 +15,7 @@ def cli():
1515

1616
@cli.command(help="Start remote compilation server")
1717
def server():
18-
from ..compiler.server import run
18+
from centml.compiler.server import run
1919

2020
run()
2121

centml/compiler/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import torch._dynamo
22

3-
from .backend import centml_dynamo_backend
3+
from centml.compiler.backend import centml_dynamo_backend
44

55

66
# Register centml compiler backend to torch dynamo

centml/sdk/api.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
import platform_api_client
33
from platform_api_client.models.deployment_status import DeploymentStatus
44

5-
from . import auth
6-
from .config import Config
7-
from .utils import client_certs
5+
from centml.sdk import auth
6+
from centml.sdk.config import Config
7+
from centml.sdk.utils import client_certs
88

99

1010
@contextlib.contextmanager

centml/sdk/auth.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
import requests
66
import jwt
77

8-
from .config import Config
8+
from centml.sdk.config import Config
99

1010

1111
def refresh_centml_token(refresh_token):

centml/sdk/utils/__init__.py

Whitespace-only changes.

centml/sdk/utils/client_certs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import os
2-
import click
32
from dataclasses import dataclass
43
from datetime import datetime, timedelta
54

5+
import click
66
from cryptography import x509
77
from cryptography.hazmat.primitives import hashes, serialization
88
from cryptography.hazmat.primitives.asymmetric import ec

0 commit comments

Comments
 (0)