Skip to content

Commit

Permalink
fix: Fix load_oauth & Bump version to 0.10.2 (#165)
Browse files Browse the repository at this point in the history
  • Loading branch information
chyroc authored Jan 16, 2025
1 parent 137922d commit de6e8b4
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 5 deletions.
4 changes: 1 addition & 3 deletions cozepy/auth/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import abc
import json
import time
from typing import List, Optional, Union
from urllib.parse import quote_plus, urlparse
Expand Down Expand Up @@ -661,8 +660,7 @@ async def refresh_access_token(self, refresh_token: str) -> OAuthToken:
return await self._arefresh_access_token(refresh_token)


def load_oauth_app_from_config(conf: str) -> Union[PKCEOAuthApp, JWTOAuthApp, DeviceOAuthApp, WebOAuthApp]:
config = json.loads(conf)
def load_oauth_app_from_config(config: dict) -> Union[PKCEOAuthApp, JWTOAuthApp, DeviceOAuthApp, WebOAuthApp]:
client_id = config.get("client_id", "")
client_type = config.get("client_type", "")
coze_api_base = config.get("coze_api_base", "")
Expand Down
2 changes: 1 addition & 1 deletion cozepy/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import sys
from functools import lru_cache

VERSION = "0.10.1"
VERSION = "0.10.2"


def get_os_version() -> str:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "cozepy"
version = "0.10.1"
version = "0.10.2"
description = "OpenAPI SDK for Coze(coze.com/coze.cn)"
authors = ["chyroc <[email protected]>"]
readme = "README.md"
Expand Down

0 comments on commit de6e8b4

Please sign in to comment.