Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a way to pass pgoptions when establishing the connection #44

Merged
merged 1 commit into from
Mar 31, 2021

Conversation

mderoy
Copy link
Contributor

@mderoy mderoy commented Mar 30, 2021

Add code for passing pgoptions when establishing a database connection

Testing:

  • Tried to do testing with python2, but there seems to be sytax errors unrelated to my changes
  • Tested with python3...one failed test, but seems unrelated 'FAILED test_typeconversion.py::test_xml_roundtrip - nzpy.core.ProgrammingError: ERROR: Function 'XMLPARSE(UNKNOWN)' does not exist'
  • Used interactive python shell to ensure that my pgoption was passed, and the effect was correctly taken by the database

@mderoy mderoy changed the title WIP: Add a way to pass pgoptions when establishing the connection Add a way to pass pgoptions when establishing the connection Mar 30, 2021
@mderoy mderoy marked this pull request as ready for review March 30, 2021 17:04
Copy link
Contributor

@aniket-s-kulkarni aniket-s-kulkarni left a comment

Choose a reason for hiding this comment

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

@mderoy can we change pgOptions to accept enums rather than free form. That way caller doesn't need to know about engine internals.

@mderoy
Copy link
Contributor Author

mderoy commented Mar 30, 2021

@mderoy can we change pgOptions to accept enums rather than free form. That way caller doesn't need to know about engine internals.

The intention was to keep it opaque...adding enums for this would publicly document things most users have no business setting. (after reviewing the options that can be passed I don't see why a user would ever set any of these)

@mderoy
Copy link
Contributor Author

mderoy commented Mar 30, 2021

@shabbir10july I've left it undocumented in our README....do you think we should document it as 'for internal use only' or just leave undocumented? (me and aniket aren't sure)

@mderoy
Copy link
Contributor Author

mderoy commented Mar 30, 2021

forgot to push init.py changes.... should be there now.

Copy link
Contributor

@aniket-s-kulkarni aniket-s-kulkarni left a comment

Choose a reason for hiding this comment

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

👍

@abhishekjog abhishekjog merged commit e62d781 into IBM:master Mar 31, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants