Design of Version 5 #1046
Replies: 6 comments 2 replies
-
A very good discussion to have, thanks @mkleehammer . Here are a few initial thoughts of mine.
|
Beta Was this translation helpful? Give feedback.
-
Regarding (3), I always thought there should be a way to run a test if necessary and print out the settings. If there are some "standard" factories available like UTF8Factory, we could suggest them. Otherwise print out the necessary code to start with an empty factory and set the encodings. |
Beta Was this translation helpful? Give feedback.
-
I've always tried to keep to standard Python as much as possible, but I'd really like to switch to pytest. I don't see anything moving on that front in Python development that would make it obsolete anytime soon. |
Beta Was this translation helpful? Give feedback.
-
I just want to give a nudge to this discussion, specifically about dropping support for Python 2.7. I've been looking at ways of modernising the CICD pipelines, making them more PEP517 compliant, use of pytest, linting, etc., but that is being made difficult by having to deal with 2.7. To be honest, it's kind of a blocker at the moment. @mkleehammer @gordthompson I'd like to suggest we do one more release on version 4, which would include support for Python 2.7 and then we say goodbye to 2.7, and move on to version 5 of pyodbc. I think the sooner we can do this the better. How does that sound? |
Beta Was this translation helpful? Give feedback.
-
FYI, I've started a py3 branch for version 5 that drops 2.7 support. |
Beta Was this translation helpful? Give feedback.
-
Now that I've released 5.0.0 alpha2, I'm going to close this and we can have more specific discussions for the next couple of versions. |
Beta Was this translation helpful? Give feedback.
-
Hi all, there are lots of improvements we can make once we drop support for the older versions. It's well past time, so I'd like to gather the ideas here: new Python features, problems with the current design, etc.
One of the most important would be what minimum Python version to support.
I'd really like to use the stable API to eliminate the coordination with new versions of Python.
There is quite a bit of metadata pyodbc captures per connection, stored in a "connection info" that is not exposed. These are stored by connection-string hash. It might be useful to expose this as a connection factory object, that also holds user configuration like encodings. We could even provide pre-configured ones for common databases.
Currently pyodbc is all C. Would it help maintenance if the outer shell were Python and we dropped into C for the major work? The language transition is expensive, so we'd probably want most of the data structures in Python so that small functions don't require it.
Thoughts?
Beta Was this translation helpful? Give feedback.
All reactions