Ahjo

Latest version: v3.7.0

Safety actively analyzes 629788 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 6

3.3.1

ahjo-upgrade bugfix
Due to refactoring related to v3.3.0 changes, parameter positioning in ahjo-upgrade execute_action call was incorrect. This caused ahjo-upgrade to fail. The bug is now fixed.

Non-interactive mode to ahjo-upgrade
Non-interactive mode is now supported in ahjo-upgrade command. With `-ni` or `--non-interactive` flag, confirmation messages are skipped.

3.3.0

Support for SQLALchemy transactions
Added ability to use SQLAlchemy transactions in ahjo actions and ahjo-upgrade. To enable transactions, set `context_connectable_type` to `connection` in project config file. The transaction management style can be defined with `transaction_mode` setting. If `transaction_mode` is set to `begin_once`, a transaction is started before running actions and committed after all actions are run. If `transaction_mode` is set to `commit_as_you_go`, a transaction is started before running actions but not committed automatically. Ahjo master actions support transactions, but custom actions need to be modified if transactions are used. See `ahjo.scripts.master_actions.py` for examples.

Database collation check
Ahjo displays database collation information before running actions. If the defined collation is different from the database collation, a warning is logged. The database collation check is enabled by default. The check can be disabled by setting `display_db_info` to `false` in project config file.

Non-interactive mode
Added ability to run ahjo actions in non-interactive mode. Non-interactive mode can be enabled with `-ni` or `--non-interactive` flag.

commentjson package dependency to optional
`commentjson` python package is now optional. If commentjson is not installed, only JSON config files are supported. To install ahjo with commentjson package, use `pip install ahjo[jsonc]` command.

Reload actions in ahjo-upgrade
In previous versions, `ahjo-upgrade` command did not reload actions from `ahjo_actions.py` file. This caused problems when ahjo actions were modified between different versions. `ahjo-upgrade` now reloads actions on each version upgrade.

Maximum execution time for Bitbucket Pipelines
Added maximum execution time for Bitbucket Pipelines. The maximum execution time is 5 minutes.

3.2.1

ahjo-upgrade hotfix
Fixed a bug where the search for upgradable versions of `ahjo-upgrade` script did not work in certain situations.

3.2.0

New command for database version updates
Database updates can be run with `ahjo-upgrade` command. See more info in README.md.

Running Ahjo commands without config parameter
Ahjo config file parameter is no longer mandatory if the config path is defined in environment variable `AHJO_CONFIG_PATH`:


ahjo retrieves the configuration file path from environment variable
ahjo <action>
ahjo-upgrade

configuration file path is specified to <config_filename>
ahjo <action> <config_filename>
ahjo-upgrade <config_filename>
)

Skip Ahjo actions
Ahjo actions can be skipped with a new config parameter: `skipped_actions`. See more info in README.md.

Python 3.11
Added Python 3.11 to tox envlist. Currently Ahjo supports Python versions 3.7, 3.8, 3.9, 3.10 and 3.11.

3.1.5

Update pyodbc version
A vulnerability was found in pyodbc that enables a buffer overflow when fetching over 100 numbers long value from database. This was fixed by updating pyodbc to version 4.0.39.

3.1.4

Not secure
Bulk insert fix
In SQLAlchemy 2.0, the parameters `insertmanyvalues` and `setinputsizes` of the function `create_engine` are set to `True` by default. These settings are not compatible with the bulk insert method in ahjo v3.1.3. In this update, these settings are changed back to `False` (when dialect is mssql+pyodbc). Full support for the [insertmanyvalues ](https://docs.sqlalchemy.org/en/20/core/connections.html#engine-insertmanyvalues) will come to ahjo in a later release.

Safety workflow update
Updated workflow to run Safety againts pip freeze.

Update package versions
New package version requirements:
- `alembic == 1.9.4`
- `SQLAlchemy == 2.0.4`

Page 2 of 6

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.