fix: Python 3.9 compatibility for union type hints
Use Optional[T] + from __future__ import annotations instead of T | None syntax which requires Python 3.10+. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -1,13 +1,15 @@
|
||||
"""Oracle ADB connection pool and CRUD operations for knowledge_queue."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
import json
|
||||
import os
|
||||
from contextlib import contextmanager
|
||||
from typing import Generator
|
||||
from typing import Generator, Optional
|
||||
|
||||
import oracledb
|
||||
|
||||
_pool: oracledb.ConnectionPool | None = None
|
||||
_pool: Optional[oracledb.ConnectionPool] = None
|
||||
|
||||
|
||||
def _get_pool() -> oracledb.ConnectionPool:
|
||||
|
||||
Reference in New Issue
Block a user