long2ice / asynch

An asyncio ClickHouse Python Driver with native (TCP) interface support.
https://github.com/long2ice/asynch
Apache License 2.0
186 stars 43 forks source link

Remove the `strict` option from the `parse_dsn` function and make the function stricter on URL validation #113

Closed stankudrow closed 1 month ago

stankudrow commented 2 months ago

@long2ice , this is urgent. Before stabilising the asynch library and releasing the version 0.2.5, please consider this PR. I found that DSN parsing can be stricter concerning URL validation (reducing amount of ways of leg-shooting). Also I changed my mind about the strict option in the function signature: without it the function is simpler and more deterministic.

I guess it is sort of a bugfix and avoiding an ugly arch solution to be exposed as a part of library API. A lesson of "keeping it simple".

stankudrow commented 2 months ago

@pufit , could you possibly review, discuss and approve this PR? I don't want the mess I committed to sneak in the v0.2.5, please help.

stankudrow commented 2 months ago

@long2ice , sorry for pinging, I just want to be sure this PR will be approved and merged before releasing the v0.2.5. DSN parsing may be improved I guess, but now I want to fix my arch mistake about introducing strict option - this one shall not pass. Moreover, the related tests got simplified which is a good sign.

stankudrow commented 1 month ago

@long2ice , hello, shall we finish with this PR? Really wanna have it merged before the new version release.