Fix bug on -Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production && Enhance Configuration && Optimize Test Command#14
Merged
danielmeppiel merged 3 commits intodanielmeppiel:mainfrom May 10, 2025
Conversation
….example and updating related code in main.py, db_context, and README for Oracle client library directory support.
… MCP server with additional options for event subscription and message sending.
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds support for specifying the Oracle client library directory via an environment variable, updates the database connector to accept and forward this directory when initializing in thick mode, and refines the async pool creation. It also updates configuration examples (including .env.example and README.md) and adds a Chinese translation of the README.
- Introduce
ORACLE_CLIENT_LIB_DIRenv var and pass it toDatabaseConnector - Extend
DatabaseConnectorandDatabaseContextsignatures to acceptlib_dir - Update
oracledb.create_pool_asyncinvocation and refresh documentation/examples
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| main.py | Read ORACLE_CLIENT_LIB_DIR and pass it into the application lifespan |
| db_context/database.py | Extend connector init with lib_dir, conditionally call init_oracle_client, and adjust pool creation |
| db_context/init.py | Forward lib_dir from DatabaseContext to DatabaseConnector |
| README.md | Add references for advanced run commands |
| README-zh.md | Add Chinese documentation |
| .env.example | Document the new ORACLE_CLIENT_LIB_DIR variable |
Comments suppressed due to low confidence (2)
db_context/database.py:20
- Consider adding unit tests for
DatabaseConnectorto verify thatoracledb.init_oracle_clientis called both with and withoutlib_dirwhenthick_modeis enabled.
if lib_dir:
db_context/database.py:44
- The
awaitkeyword was removed when creating the async pool, causing_poolto be assigned a coroutine instead of the actual pool instance. Please restoreawaitbeforeoracledb.create_pool_async(...).
self._pool = oracledb.create_pool_async(
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Version:
Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
PL/SQL Release 11.2.0.4.0 - Production
"CORE 11.2.0.4.0 Production"
TNS for Linux: Version 11.2.0.4.0 - Production
NLSRTL Version 11.2.0.4.0 - Production