Skip to content

Changelog

1.7.0 - 2025-08-13

Authors: Bruno Macedo

Changes:

  • Changed HTTP classes to use httpx instead of requests module.
  • Added OnsHttpHandler to connect to SAGER and SINAPSE.
  • Reorganized tests.

1.6.1 - 2025-07-12

Authors: Bruno Macedo

Changes:

  • Changed build backend to uv_build for better packaging and deployment.

1.6.0 - 2025-07-09

Authors: Bruno Macedo

Changes:

  • Added polars_to_sql method to PgSqlHandler.

1.5.3 - 2025-06-30

Authors: Bruno Macedo

Changes:

  • Fixed type hints for skip_row_check.

1.5.2 - 2025-06-24

Authors: Bruno Macedo

Changes:

  • Added compatibility for Path object in FtpHandler.

1.5.1 - 2025-06-23

Authors: Bruno Macedo

Changes:

  • Added option to allow empty strings (endpoint) in http requests.

1.5.0 - 2025-06-19

Authors: Bruno Macedo

Changes:

  • Added read_to_polars to SQL classes.
  • Added pydantic validate call to all methods.
  • Added ruff.toml file to configure ruff.

1.4.1 - 2025-04-28

Authors: Bruno Macedo

Changes:

  • Added headers argument to HttpConnProperties to allow for custom headers to be set in the session.
  • HttpHandler now allows for requests to be made to empty endpoints.

1.4.0 - 2025-04-10

Authors: Bruno Macedo

Changes:

  • Added option to specify payload_kwargs to be added to every request in any subclass of HttpHandler. This allows to add something that is fixed for every request, like api_key or credentials.

1.3.10 - 2025-02-18

Authors: Bruno Macedo

Changes:

  • Added option to select pymssql directly in MsSqlHandler to avoid errors when connecting to SCADA SQL servers.

1.3.9 - 2025-02-05

Authors: Bruno Macedo

Changes:

  • Changed API URL for bazefield password login.

1.3.8 - 2024-12-20

Authors: Bruno Macedo

Changes:

  • Added schema argument to SQL connection. In postgres, when this is set, the search path is set to the schema name.

1.3.7 - 2024-12-15

Authors: Bruno Macedo

Changes:

  • Removed unnecessary log messages when connections was successful.

1.3.6 - 2024-12-09

Authors: Bruno Macedo

Changes:

  • Added skip_row_check to if_exists in pandas_to_sql.

1.3.5 - 2024-10-14

Authors: Bruno Macedo

Changes:

  • Removed hard requirement of api key or credentials in HttpConnProperties.
  • Moved _connect from BazeHttpHandler to HttpHandler to allow for more flexibility in the connection process. Only authentication is now done in BazeHttpHandler.

1.3.4 - 2024-09-09

Authors: Bruno Macedo

Changes:

  • Added option to get columns from views and materialized views in PgSqlHandler.get_table_columns().

1.3.3 - 2024-09-02

Authors: Bruno Macedo

Changes:

  • Changed query to upsert eh values in PgSqlHandler.pandas_to_sql to avoid errors when there is a duplicate key in the data being inserted. Also broke the insert process in chunks of 100000 rows to avoid errors.

1.3.2 - 2024-09-02

Authors: Bruno Macedo

Changes:

  • Set SSL default requirement to False in HttpConnProperties to avoid errors when connecting to non-secure servers.

1.3.1 - 2024-08-27

Authors: Bruno Macedo

Changes:

  • Bug fix in upsert of SqlLiteHandler.pandas_to_sql.

1.3.0 - 2024-08-16

Authors: Bruno Macedo

Changes:

  • Major changes in documentation. Now we are using MkDocs to generate the documentation and Material for MkDocs as the theme.

1.2.1 - 2024-07-25

Authors: Bruno Macedo

Changes:

  • Added option to forcefully skip retries in SqlHandler read_to_pandas() and execute() methods, skipping the maximum number of retries set in the ConnProperties object.

1.2.0 - 2024-07-14

Authors: Bruno Macedo

Changes:

  • Added better support for time zone aware in SqlHandler, specially in read_to_pandas() method.

1.1.0 - 2024-07-09

Authors: Bruno Macedo

Changes:

  • Upgraded to python 3.12.

1.0.8 - 2024-06-30

Authors: Bruno Macedo

Changes:

  • In MsSqlHandler fixed TDS version when connecting using pymssql to allow upgrading pymssql to version higher than 2.2.8.

1.0.7 - 2024-05-23

Authors: Bruno Macedo

Changes:

  • Changed FtpHandler._close() to use FTP quit method instead of close method, to avoid errors when closing the connection.

1.0.6 - 2024-05-13

Authors: Bruno Macedo

Changes:

  • Minor bug fix in FtpHandler.delete_file().

1.0.5 - 2024-04-15

Authors: Bruno Macedo

Changes:

  • Changed to new Bazefield URL.

1.0.4 - 2024-04-10

Authors: Bruno Macedo

Changes:

  • Fixed bug in SqlHandler._get_pandas_sql_dtypes().

1.0.3 - 2024-03-10

Authors: Bruno Macedo

Changes:

  • Added option to specify conflict_cols in pandas_to_sql method of SqlHandler subclasses. This allows to specify the columns to be used in the ON CONFLICT clause.

1.0.2 - 2024-03-06

Authors: Bruno Macedo

Changes:

  • Added notices attribute to PgSqlHandler to store the notices from the server. It allows to retrieve any notices from previous queries.
  • pyarrow as default dtype_backend in SqlHandler.read_to_pandas().
  • Added post_convert option to SqlHandler.read_to_pandas() for converting to pyarrow or Numpy nullable after reading that, which solves some issues when reading JSON columns from PostgreSQL.

1.0.1 - 2024-03-04

Authors: Bruno Macedo

Changes:

  • Added skip_connect option to ConnHandler constructor, enabling the creation of a handler without connecting to the server.

1.0.0 - 2024-03-03

Authors: Bruno Macedo

Changes:

  • Major changes to PgSqlHandler to add new functionality such as saving data from a pandas DataFrame to a table in the database.
  • SqlHandler._get_pandas_sql_dtypes() much improved, now checks for the columns data type and only falls to checking column values if could not infer the data type from the column dtype.
  • Added create_table and delete_table methods to PgSqlHandler and SqlLiteHandler.
  • More detailed README file.

0.4.8 - 2024-03-01

Authors: Bruno Macedo

Changes:

  • Moved installation to pyproject.toml.
  • Refactored considering ruff suggestions.

0.4.7 - 2024-02-07

Authors: Bruno Macedo

Changes:

  • Fixed retries in BazeHttpHandler.

0.4.6 - 2024-02-03

Authors: Bruno Macedo

Changes:

  • Adjusted pool_maxsize in BazeHttpHandler to 32 to allow concurrent requests to the Bazefield API.

0.4.5 - 2023-08-10

Authors: Bruno Macedo

Changes:

  • Forced use of pymssql 2.2.8 to avoid errors with newer versions when connecting to SCADA SQL servers.

0.4.4 - 2023-08-08

Authors: Bruno Macedo

Changes:

  • Changed functions in all core connection handlers to show the first error and not the last in case failed after multiple attempts.

0.4.3 - 2023-06-19

  • Added support to pyarrow pandas backend.

0.4.2 - 2023-06-15

  • Added type checks for all ConnProperties subclasses, avoiding errors when instantiating them. As they are data classes this was done using the __post_init__ method.
  • Changed chunk size in to_sql method of SqlLitHandler.pandas_to_sql to be dynamically set based on the input DataFrame.

0.4.1 - 2023-05-22

  • Minor bug fix when using ConnHandler in with statement.
  • Added custom dtype mapping to SqlLiteHandler.

0.4.0 - 2023-05-18

  • Added SqlLiteConnProperties and SqlLiteHandler classes.
  • Added class method _get_pandas_sql_dtypes to SqlHandler to convert Pandas dtypes to SQL dtypes.
  • Added many abstract methods to SqlHandler to be implemented by subclasses. These methods were already implemented in SqlLiteHandler but need to be implemented in MsSqlHandler and PgSqlHandler.

0.3.0 - 2023-05-11

  • Added capabilities to ConnHandler to be used in a with statement.

0.2.7 - 2023-05-07

  • Changed default retry_wait_time to a lower value in all modules.

0.2.6 - 2023-04-22

  • Added option to pass positional and keyword arguments to the execute method of SqlHandler.

0.2.5 - 2023-04-19

  • Added execute method to SqlHandler. This is used to execute queries using the cursor.

0.2.4 - 2023-04-19

  • Changed SqlHandler to do everything in read_to_pandas inside a try/except block to avoid erros if the connection is lost.

0.2.3 - 2023-04-18

  • Added Encrypt=no to the ODBC connection string of sql_ms.py to improve compatibility with older versions of SQL server.

0.2.2 - 2023-02-09

  • Made MsSqlHandler compatible with ODBC driver version 18.

0.2.1 - 2023-02-06

  • Changed FtpHandler to connect using passive mode.

0.2.0 - 2023-01-26

  • Added FtpConnProperties and FtpHandler classes.
  • ConnHandler.reconnect() now attempts to close the connection before connecting again.

0.1.1 - 2023-01-10

  • Added the cursor() method to SqlHandler class.

0.1.0 - 2023-01-09

  • Changed package name to echo_connhandler to allow for a more broader use.
  • Added HttpConnProperties and HttpHandler as abstract classes to handle connection to HTTP servers.
  • Added to BazeHttpHandler to connect to Bazefield.

0.0.2 - 2023-01-04

  • Minor bug fixes.

0.0.1 - 2023-01-04

  • Initial release.