Skip to content

[breaking] move BenchmarkTools.jl to a package extension#2982

Merged
odow merged 1 commit intomasterfrom
od/benchmark-tools
Mar 27, 2026
Merged

[breaking] move BenchmarkTools.jl to a package extension#2982
odow merged 1 commit intomasterfrom
od/benchmark-tools

Conversation

@odow
Copy link
Copy Markdown
Member

@odow odow commented Mar 26, 2026

This is a breaking change because it requires the user to install and load BenchmarkTools.jl.

We justify releasing it in a minor release of MathOptInterface because we assess that there are very few users of it, and because it should be used only during package development by advanced users.

We reserve the right to revert this commit in a future release of MOI if it causes problems in the ecosystem.

Closes #2728

This is a breaking change because it requires the user to install
and load BenchmarkTools.jl.

We justify releasing it in a minor release of MathOptInterface
because we assess that there are very few users of it, and because
it should be used only during package development by advanced users.

We reserve the right to revert this commit in a future release of MOI
if it causes problems in the ecosystem.
@odow odow mentioned this pull request Mar 26, 2026
@odow
Copy link
Copy Markdown
Member Author

odow commented Mar 27, 2026

Merging so I can rebase #2967 which will have some conflicts. There's no rush to tag a new version once this is merged.

@odow odow merged commit f9e0ab9 into master Mar 27, 2026
30 checks passed
@odow odow deleted the od/benchmark-tools branch March 27, 2026 01:56
@franckgaga
Copy link
Copy Markdown
Contributor

franckgaga commented Mar 27, 2026

Why not bump the major if it is theoretically breaking?

edit: To elaborate my point a little bit: developers are a bit too scared to bump the major number. From my point of view, if you are aware that something is breaking you should bump the major, that's a feature of SemVer, that's not something to be scared of.

@odow
Copy link
Copy Markdown
Member Author

odow commented Mar 27, 2026

See

https://www.youtube.com/watch?v=M31xoZGyj9w&t=2535s

See also the discussion in #2728, and #2180.

I am not going to release MathOptInterface@2.0, almost without exception. I'd rather live for 10 years with some annoying parts of MOI than release a breaking change. Changing from v1 to v2 just because of BenchmarkTools requires us to change the compat bounds of 195 direct dependencies. That's a massive ecosystem cost, and it's why my starting point is "no breaking changes".

We discussed that removing BenchmarkTools is perhaps the only exception we will ever make to this because:

  • It shouldn't ever be used by "normal" users
  • It's most likely to be used by package developers who are advanced users
  • There's very little evidence it is being used by package developers
  • It probably shouldn't have been a submodule in the first place
  • There a favourable trade-off between inconveniencing a small number (~0) advanced users against making the package smaller for >10,000 users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

BenchmarkTools dependency

2 participants