Repository navigation
[SCAL-338917] chore: rename @version placeholder <TBD> to %NEXT_SDK_VERSION% - #751
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request renames the version placeholder from <TBD> to %NEXT_SDK_VERSION% across documentation, scripts, and tests, and adds validation to reject the legacy <TBD> placeholder. The reviewer suggests improving the placeholder detection and replacement logic in scripts/resolve-version-placeholders.js by utilizing standard string methods like includes and replaceAll instead of regular expressions, given the Node.js 18.x requirement. Additionally, the reviewer recommends validating the entire codebase for blocking issues before performing any file writes to ensure transactional safety.
commit: |
sastaachar
reviewed
Nov 16, 2026
…ERSION% <TBD> is a common abbreviation and was matched case-insensitively, so the release bump could stamp a version onto a tag nobody meant to resolve. The placeholder is now %NEXT_SDK_VERSION%, matched exactly. A leftover <TBD> anywhere on a @Version line now blocks lint, resolve and publish with a rename hint, so PRs on the old convention fail loudly instead of slipping through. Docs and workflow comments updated.
Add an explicit check-versions step to publishToNPM, before npm publish, so a release fails by name if a %NEXT_SDK_VERSION% is still unresolved (e.g. a PR with one merged after the release bump). Match the placeholder with includes/replaceAll instead of a global RegExp, removing the lastIndex reset, and escape the token in the SDK format pattern. Migrate the <TBD> tag added on main by #746.
jitendra-bhati-ts
force-pushed
the
SCAL-338917-unique-version-placeholder
branch
from
November 16, 2026 09:25
478228a to
0fdb85b
Compare
sastaachar
approved these changes
Nov 16, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Jira: SCAL-338917
Follow-up to #676
The problem
The release bump replaces the
@versionplaceholder with the version being cut. That placeholder was<TBD>, matched case-insensitively.<TBD>is a word people write on their own ("not decided yet"), so a tag like@version SDK: <TBD>could get stamped with the next release even when the author never meant it to be resolved.The fix
The placeholder is now
%NEXT_SDK_VERSION%, matched exactly and case-sensitively:It's defined once (
PLACEHOLDER_TOKENinscripts/resolve-version-placeholders.js), and the replace pattern, the format check and every message are built from it. Near misses such as%next_sdk_version%or a missing%fail as malformed instead of being rewritten.A leftover
<TBD>anywhere on a@versionline is now its own blocking problem (LEGACY_PLACEHOLDER) in lint, resolve and publish, with a hint that says what to write instead:The release rewrite never touches a
<TBD>.Publish is blocked while a placeholder is unresolved
publishToNPMnow runsnpm run check-versionsas its own step, beforenpm publish. If a PR with%NEXT_SDK_VERSION%merges after the release bump, the publish fails at that step, naming the file and line and saying to re-runbump-version-and-pr. The same check already ran insidenpm publishviaprepublishOnly; this makes it a visible step instead of a line in the publish log. Pre-releases still only warn about a pending SDK placeholder.Notes for review
srcchange. [SCAL-351825] Add isProgrammaticFilterParameterUpdateEnabled flag #746 merged a new@version SDK: <TBD>(src/types.ts,isProgrammaticFilterParameterUpdateEnabled) after this branch was cut, and the new check failed it on this PR. It's migrated to%NEXT_SDK_VERSION%. Everything older was already resolved by the v1.54.1 release.<TBD>tags fail rather than being accepted alongside the new token, because accepting both keeps the ambiguity this removes. Open PRs [SCAL-349233] Add DataAppEmbed and enableDataApps #734 and SCAL-349735: Ability to load a specific conversation #739 still use<TBD>and will need to rename it.<TBD>on the ThoughtSpot side. With the token changed,SDK: 1.54.0 | ThoughtSpot: <TBD>would have started passing, so the legacy check covers both sides.includesand resolved withreplaceAll, so there's no global-RegExplastIndexstate to reset. The token is escaped in the one pattern that still needs it, the SDK format check.TBD_THOUGHTSPOTtoPLACEHOLDER_THOUGHTSPOT(internal to the script).Contributing.md,CLAUDE.mdand the comments inbumpVersion.yml/pr-checks.ymlnow use the new token.%spellings,<TBD>on either side, the rename hint in--lintoutput, and resolve leaving a<TBD>file untouched.