Skip to content

release: 0.5.0 - #15

Merged
andremsouza merged 1 commit into
masterfrom
release/0.5.0
Jul 30, 2026
Merged

release: 0.5.0#15
andremsouza merged 1 commit into
masterfrom
release/0.5.0

Conversation

@andremsouza

Copy link
Copy Markdown
Owner

Version bump and changelog for 0.5.0. One change, no results move.

What it is

Plain-string options now emit DeprecationWarning:

Passing mode='batch' as a plain string is deprecated and will stop working in 1.0.0.
Use TrainingMode.BATCH instead.

That is the whole release. Deliberately single-purpose, so the one behaviour change is easy to see
and easy to revert if it turns out to be noisy in practice.

Why it has to exist

1.0.0 was blocked on it. The stated policy is that anything removed in a major release warns for
at least one minor release first. 0.4.0 deprecated strings in writing only, because mode="batch"
was what every documentation page showed at the time. Without this release, 1.0.0 removing strings
would breach the policy the project set for itself.

Nothing else moves

No numerical change, no API removal, no dependency change. Anything that worked in 0.4.0 works here
and produces identical output. The only observable difference is the warning, which names the exact
replacement so migrating is a substitution you read off the message.

To silence it while migrating:

import warnings
warnings.filterwarnings("ignore", category=DeprecationWarning, module="python_som")

Verified from the built wheel

installed set:   numpy==2.5.1, python-som==0.5.0
enums:           train under -W error::DeprecationWarning, no warning
plain strings:   warn, naming the replacement

Plus 384 tests at 100% coverage, ruff / ruff format / mypy --strict clean, mkdocs build --strict exits 0, twine check passes both artifacts.

After merge

Tag v0.5.0, then the workflow builds and waits on the pypi environment's required reviewer. The
upload is irreversible
— I will ask before approving it.

Plain-string options now emit DeprecationWarning. Nothing else changes and no numerical results move.

This is the release 1.0.0 was waiting on: the policy is that anything removed in a major release
warns for at least one minor release first, so strings could not be removed until this shipped.

Verified from the built wheel in a clean environment: numpy alone, enums train under
-W error::DeprecationWarning without warning, and a plain string warns.
@andremsouza
andremsouza merged commit be0ed5c into master Jul 30, 2026
8 checks passed
@andremsouza
andremsouza deleted the release/0.5.0 branch July 31, 2026 12:30
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.

1 participant