Skip to content

Conversation

@stockholmux
Copy link
Member

@stockholmux stockholmux commented Aug 26, 2025

As per #2459, this PR removes deprecation and deprecated_since
element and DEPRECATED doc flag from commands. Closes #2459.

Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
@codecov
Copy link

codecov bot commented Aug 26, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.22%. Comparing base (9d682ba) to head (ae19ac6).
⚠️ Report is 19 commits behind head on unstable.

Additional details and impacted files
@@             Coverage Diff              @@
##           unstable    #2546      +/-   ##
============================================
+ Coverage     72.20%   72.22%   +0.02%     
============================================
  Files           126      126              
  Lines         70615    70662      +47     
============================================
+ Hits          50985    51036      +51     
+ Misses        19630    19626       -4     
Files with missing lines Coverage Δ
src/commands.def 100.00% <ø> (ø)

... and 26 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@enjoy-binbin enjoy-binbin added release-notes This issue should get a line item in the release notes major-decision-approved Major decision approved by TSC team labels Aug 26, 2025
@enjoy-binbin enjoy-binbin moved this to In Progress in Valkey 9.0 Aug 26, 2025
Copy link
Member

@enjoy-binbin enjoy-binbin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so we are removing the DEPRECATED flag but will keep the replaced_by? So how do we render (describe) them in our doc now?

@zuiderkwast
Copy link
Contributor

so we are removing the DEPRECATED flag but will keep the replaced_by?

I agree replaced_by is strange without deprecated. I think it's better to change it to something more descriptive. Ideas: equivalent_to, similar_to. Do you have any other ideas?

So how do we render (describe) them in our doc now?

In the website repo, it seems that we don't use this replaced_by field at all. I don't find anything when I do git grep replaced_by in the valkey-io.github.io repo.

In the doc repo we have scripts to build man pages. Here, we show replaced_by only if deprecated_since is present. Here's the Python code that generates this markdown text:

utils/preprocess-markdown.py-
utils/preprocess-markdown.py-        if self.deprecated_since:
utils/preprocess-markdown.py-            print("# NOTES", end="\n\n")
utils/preprocess-markdown.py:            if self.replaced_by:
utils/preprocess-markdown.py-                print("This command is deprecated (since %s) and replaced by %s." %
utils/preprocess-markdown.py:                      (self.deprecated_since, self.replaced_by), end="\n\n")
utils/preprocess-markdown.py-            else:
utils/preprocess-markdown.py-                print("This command is deprecated since %s." % self.deprecated_since, end="\n\n")
utils/preprocess-markdown.py-

We can easily change this later to match whatever we decide in this PR.

@stockholmux
Copy link
Member Author

@zuiderkwast / @enjoy-binbin

So how do we render (describe) them in our doc now?

In the website repo, it seems that we don't use this replaced_by field at all. I don't find anything when I do git grep replaced_by in the valkey-io.github.io repo.

Yeah, so we do use replaced_by
https://github.com/valkey-io/valkey-io.github.io/blob/main/templates/command-page.html#L175

It is rendered on the docs like this:

Screenshot 2025-08-27 at 9 34 55 AM

That said, it's trivial to sub replaced_by to alternative in the JSON the heading to something like "Alternative"

@ranshid
Copy link
Member

ranshid commented Aug 27, 2025

@zuiderkwast / @enjoy-binbin

So how do we render (describe) them in our doc now?

In the website repo, it seems that we don't use this replaced_by field at all. I don't find anything when I do git grep replaced_by in the valkey-io.github.io repo.

Yeah, so we do use replaced_by https://github.com/valkey-io/valkey-io.github.io/blob/main/templates/command-page.html#L175

It is rendered on the docs like this:

Screenshot 2025-08-27 at 9 34 55 AM That said, it's trivial to sub `replaced_by` to `alternative` in the JSON the heading to something like "Alternative"

I think we should do this. Having a deprecation advise seems weird.

@stockholmux
Copy link
Member Author

The plot thickens. alternative might not be so trivial.

replaced_by is used in server.c for the COMMAND DOCS command:

127.0.0.1:6379> COMMAND DOCS BRPOPLPUSH
1) "brpoplpush"
...
    9) "replaced_by"
   10) "`BLMOVE` with the `RIGHT` and `LEFT` arguments"

It's also used in a couple python scripts: generate-command-code.py and generate-commands-json.py

So would wholesale substituting replaced_by with alternative would constitute a breaking change since the response now is different?

I see three options:

  1. Leave the replaced_by alone: odd wording when the commands are not deprecated, but no real code changes
  2. Have replaced_by for the remaining deprecated commands and alternative for un-deprecated commands - COMMAND DOCS returns either
  3. Get rid of replaced_by entirely in lieu of alternative code changes are search/replace but anyone relying on COMMANDS DOCS to have replaced_by might be in trouble.

stockholmux and others added 21 commits September 3, 2025 11:14
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Kyle J. Davis <[email protected]>
@madolson madolson merged commit 811a644 into valkey-io:unstable Sep 3, 2025
53 checks passed
@github-project-automation github-project-automation bot moved this from In Progress to Done in Valkey 9.0 Sep 3, 2025
zuiderkwast pushed a commit to valkey-io/valkey-doc that referenced this pull request Sep 4, 2025
See valkey-io/valkey#2546. 

This moves the `replaced_by` information from the command json files in
valkey-io/valkey into the docs for non-deprecated commands.

Signed-off-by: Kyle J. Davis <[email protected]>
rjd15372 pushed a commit to rjd15372/valkey that referenced this pull request Sep 19, 2025
As per valkey-io#2459, this PR removes deprecation and `deprecated_since`
element and `DEPRECATED` doc flag from commands. Closes valkey-io#2459.

---------

Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
rjd15372 pushed a commit that referenced this pull request Sep 23, 2025
As per #2459, this PR removes deprecation and `deprecated_since`
element and `DEPRECATED` doc flag from commands. Closes #2459.

---------

Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
hpatro pushed a commit to hpatro/valkey that referenced this pull request Oct 3, 2025
As per valkey-io#2459, this PR removes deprecation and `deprecated_since`
element and `DEPRECATED` doc flag from commands. Closes valkey-io#2459.

---------

Signed-off-by: Kyle J. Davis <[email protected]>
Co-authored-by: Madelyn Olson <[email protected]>
Signed-off-by: Harkrishn Patro <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

major-decision-approved Major decision approved by TSC team release-notes This issue should get a line item in the release notes

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[NEW] The great un-deprecation

5 participants