Skip to content

Conversation

@bewithgaurav
Copy link
Collaborator

@bewithgaurav bewithgaurav commented Jan 9, 2026

Work Item / Issue Reference

AB#41750


Summary

This pull request removes unused helper functions related to connection string manipulation from the mssql_python.helpers module. The primary focus is on cleaning up the codebase by eliminating the add_driver_to_connection_str and add_driver_name_to_app_parameter functions, as well as their import and usage.

Code cleanup and removal of unused functions:

  • Removed the import of add_driver_to_connection_str from mssql_python/helpers.py in connection.py, as it is no longer used.
  • Deleted the add_driver_to_connection_str function, which previously handled injecting a default ODBC driver into the connection string.
  • Deleted the add_driver_name_to_app_parameter function, which previously ensured the APP parameter was set in the connection string.

@github-actions github-actions bot added the pr-size: medium Moderate update size label Jan 9, 2026
@github-actions
Copy link

github-actions bot commented Jan 10, 2026

📊 Code Coverage Report

🔥 Diff Coverage

100%


🎯 Overall Coverage

76%


📈 Total Lines Covered: 5431 out of 7084
📁 Project: mssql-python


Diff Coverage

Diff: main...HEAD, staged and unstaged changes

No lines with coverage information in this diff.


📋 Files Needing Attention

📉 Files with overall lowest coverage (click to expand)
mssql_python.pybind.logger_bridge.hpp: 58.8%
mssql_python.pybind.logger_bridge.cpp: 59.2%
mssql_python.row.py: 66.2%
mssql_python.pybind.ddbc_bindings.cpp: 69.4%
mssql_python.pybind.ddbc_bindings.h: 69.7%
mssql_python.pybind.connection.connection.cpp: 73.6%
mssql_python.ddbc_bindings.py: 79.6%
mssql_python.pybind.connection.connection_pool.cpp: 79.6%
mssql_python.connection.py: 84.1%
mssql_python.cursor.py: 84.7%

🔗 Quick Links

⚙️ Build Summary 📋 Coverage Details

View Azure DevOps Build

Browse Full Coverage Report

@bewithgaurav bewithgaurav marked this pull request as ready for review January 20, 2026 05:19
Copilot AI review requested due to automatic review settings January 20, 2026 05:19
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request removes unused helper functions from the mssql_python.helpers module as part of a code cleanup effort. The removed functions previously handled connection string manipulation but are no longer used in the codebase.

Changes:

  • Removed add_driver_to_connection_str function that previously injected ODBC driver into connection strings
  • Removed add_driver_name_to_app_parameter function that previously ensured APP parameter was set
  • Removed unused import of add_driver_to_connection_str from connection.py

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
mssql_python/helpers.py Removed two unused helper functions related to connection string manipulation
mssql_python/connection.py Removed unused import of add_driver_to_connection_str

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@bewithgaurav bewithgaurav changed the title CHORE: Remove Dead Code CHORE: Remove Dead Code & Fix PR Description Jan 20, 2026
@bewithgaurav bewithgaurav changed the title CHORE: Remove Dead Code & Fix PR Description CHORE: Remove unused methods from helpers.py & Fix PR Description Jan 20, 2026
Copy link
Contributor

@gargsaumya gargsaumya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-size: medium Moderate update size

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants