Approach to semver for breaking changes

Open
#1,703 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
25/100
Issue type
Documentation
Clarity
Needs clarification
Activity status
Stale
Tech stack
php
Domain
release

Research direction

The issue names WPCS 2.1, the Composer constraint ^2, and semver but no files or tests. Start by reviewing the project’s release and versioning guidance and how breaking sniff changes are documented. Done means the project’s semver policy and the handling of such changes are clearly decided and recorded.

Written by the indexing model from the issue text.

Description

Type: Question

I was surprised to see that WPCS 2.1 introduced a new sniff and moved some sniffs out of Extra and into Core. These are breaking changes because, for example, code that previously used ini_set( ... ) without consequence now gets flagged as an error.

I would have expected these changes to be released as 3.0.0 according to semver rules, so that a package that requires wp-coding-standards/wpcs ^2 would not receive breaking change updates.

Does WPCS follow semver or should packages assume that minor version updates can contain breaking changes? Or was this just an oversight?

Cheers!

Dominant language
PHP
Stars
2.8k
Forks
521
Avg merge
5d 20h
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from WordPress/WordPress-Coding-Standards

All issues in WordPress/WordPress-Coding-Standards

Similar issues

More PHP issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.