From 31f7e07c6e70e0fd733370665d38c9b65240200f Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Mon, 25 Aug 2025 23:47:33 +0200 Subject: [PATCH 1/8] [BUILD] Use -dev versions in main branch --- MODULE.bazel | 2 +- api/include/opentelemetry/version.h | 4 ++-- docs/public/conf.py | 2 +- exporters/ostream/test/ostream_log_test.cc | 12 ++++++------ sdk/include/opentelemetry/sdk/version/version.h | 2 +- sdk/src/version/version.cc | 12 ++++++------ 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/MODULE.bazel b/MODULE.bazel index f0597b59e0..09d6cc00bc 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -3,7 +3,7 @@ module( name = "opentelemetry-cpp", - version = "1.22.0", + version = "1.23.0", compatibility_level = 0, repo_name = "io_opentelemetry_cpp", ) diff --git a/api/include/opentelemetry/version.h b/api/include/opentelemetry/version.h index ab69ca02f2..e8747af9a1 100644 --- a/api/include/opentelemetry/version.h +++ b/api/include/opentelemetry/version.h @@ -10,9 +10,9 @@ # define OPENTELEMETRY_ABI_VERSION_NO 1 #endif -#define OPENTELEMETRY_VERSION "1.22.0" +#define OPENTELEMETRY_VERSION "1.23.0" #define OPENTELEMETRY_VERSION_MAJOR 1 -#define OPENTELEMETRY_VERSION_MINOR 22 +#define OPENTELEMETRY_VERSION_MINOR 23 #define OPENTELEMETRY_VERSION_PATCH 0 #define OPENTELEMETRY_ABI_VERSION OPENTELEMETRY_STRINGIFY(OPENTELEMETRY_ABI_VERSION_NO) diff --git a/docs/public/conf.py b/docs/public/conf.py index 0eda6e9e39..365cbe09c4 100644 --- a/docs/public/conf.py +++ b/docs/public/conf.py @@ -24,7 +24,7 @@ author = 'OpenTelemetry authors' # The full version, including alpha/beta/rc tags -release = "1.22.0" +release = "1.23.0-dev" # Run sphinx on subprojects and copy output # ----------------------------------------- diff --git a/exporters/ostream/test/ostream_log_test.cc b/exporters/ostream/test/ostream_log_test.cc index 6c7028ed16..8b8063f6d4 100644 --- a/exporters/ostream/test/ostream_log_test.cc +++ b/exporters/ostream/test/ostream_log_test.cc @@ -125,7 +125,7 @@ TEST(OstreamLogExporter, DefaultLogRecordToCout) " severity_text : INVALID\n", " body : \n", " resource : \n", - std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_VERSION + "\n", + std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_SDK_VERSION + "\n", " telemetry.sdk.name: opentelemetry\n", " telemetry.sdk.language: cpp\n", " attributes : \n", @@ -199,7 +199,7 @@ TEST(OStreamLogRecordExporter, SimpleLogToCout) " severity_text : TRACE\n" " body : Message\n", " resource : \n", - std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_VERSION + "\n", + std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_SDK_VERSION + "\n", " telemetry.sdk.name: opentelemetry\n", " telemetry.sdk.language: cpp\n", " attributes : \n", @@ -270,7 +270,7 @@ TEST(OStreamLogRecordExporter, LogWithStringAttributesToCerr) " severity_text : INVALID\n", " body : \n", " resource : \n", - std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_VERSION + "\n", + std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_SDK_VERSION + "\n", " telemetry.sdk.name: opentelemetry\n", " telemetry.sdk.language: cpp\n", " service.name: unknown_service\n", @@ -352,7 +352,7 @@ TEST(OStreamLogRecordExporter, LogWithVariantTypesToClog) " body : \n", " resource : \n", " service.name: unknown_service\n", - std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_VERSION + "\n", + std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_SDK_VERSION + "\n", " telemetry.sdk.name: opentelemetry\n", " telemetry.sdk.language: cpp\n", " res1: [1,2,3]\n", @@ -425,7 +425,7 @@ TEST(OStreamLogRecordExporter, IntegrationTest) " severity_text : DEBUG\n", " body : Hello\n", " resource : \n", - std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_VERSION + "\n", + std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_SDK_VERSION + "\n", " service.name: unknown_service\n", " telemetry.sdk.name: opentelemetry\n", " telemetry.sdk.language: cpp\n", @@ -496,7 +496,7 @@ TEST(OStreamLogRecordExporter, IntegrationTestWithEventId) " severity_text : DEBUG\n", " body : Hello {key1} {key2}\n", " resource : \n", - std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_VERSION + "\n", + std::string{" telemetry.sdk.version: "} + OPENTELEMETRY_SDK_VERSION + "\n", " service.name: unknown_service\n", " telemetry.sdk.name: opentelemetry\n", " telemetry.sdk.language: cpp\n", diff --git a/sdk/include/opentelemetry/sdk/version/version.h b/sdk/include/opentelemetry/sdk/version/version.h index 1b31852ca2..c96ce7f3e7 100644 --- a/sdk/include/opentelemetry/sdk/version/version.h +++ b/sdk/include/opentelemetry/sdk/version/version.h @@ -3,7 +3,7 @@ #pragma once -#define OPENTELEMETRY_SDK_VERSION "1.22.0" +#define OPENTELEMETRY_SDK_VERSION "1.23.0-dev" #include "opentelemetry/version.h" diff --git a/sdk/src/version/version.cc b/sdk/src/version/version.cc index 451f7d38ed..2ce5434320 100644 --- a/sdk/src/version/version.cc +++ b/sdk/src/version/version.cc @@ -12,13 +12,13 @@ namespace sdk namespace version { const int major_version = 1; -const int minor_version = 22; +const int minor_version = 23; const int patch_version = 0; -const char *pre_release = "NONE"; -const char *build_metadata = "NONE"; -const char *short_version = "1.22.0"; -const char *full_version = "1.22.0-NONE-NONE"; -const char *build_date = "Fri Jul 11 08:13:24 PM UTC 2025"; +const char *pre_release = "dev"; +const char *build_metadata = "none"; +const char *short_version = "1.23.0-dev"; +const char *full_version = "1.23.0-dev-none"; +const char *build_date = "MAIN BRANCH"; } // namespace version } // namespace sdk OPENTELEMETRY_END_NAMESPACE From 74e23d551db0bd36aa53e105e974fb4597765c56 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Tue, 26 Aug 2025 00:05:55 +0200 Subject: [PATCH 2/8] Changelog --- CHANGELOG.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 416ee21a81..3b79f94cba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -30,11 +30,22 @@ Increment the: * [SDK] View should not have a unit [#3552](https://github.com/open-telemetry/opentelemetry-cpp/pull/3552) +* [BUILD] Use -dev versions in main branch + [#3609](https://github.com/open-telemetry/opentelemetry-cpp/pull/3609) + Important changes: * [CMAKE] Upgrade CMake minimum version to 3.16 [#3599](https://github.com/open-telemetry/opentelemetry-cpp/pull/3599) +* [BUILD] Use -dev versions in main branch + [#3609](https://github.com/open-telemetry/opentelemetry-cpp/pull/3609) + * The version number in the main branch has changed, + to better differentiate with the latest release. + * For example: + * With a latest release 1.22.0, the main branch is 1.23.0-dev + * Upon release of 1.23.0, the main branch becomes 1.24.0-dev + Breaking changes: * [SDK] View should not have a unit From b480fdff3c629227ce30cda638805ddfd6dadd94 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Tue, 26 Aug 2025 21:53:51 +0200 Subject: [PATCH 3/8] Code review comments. --- api/include/opentelemetry/version.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/include/opentelemetry/version.h b/api/include/opentelemetry/version.h index e8747af9a1..d87b7b2e4f 100644 --- a/api/include/opentelemetry/version.h +++ b/api/include/opentelemetry/version.h @@ -10,7 +10,7 @@ # define OPENTELEMETRY_ABI_VERSION_NO 1 #endif -#define OPENTELEMETRY_VERSION "1.23.0" +#define OPENTELEMETRY_VERSION "1.23.0-dev" #define OPENTELEMETRY_VERSION_MAJOR 1 #define OPENTELEMETRY_VERSION_MINOR 23 #define OPENTELEMETRY_VERSION_PATCH 0 From 5711b71eebb554d9405f321218272cc170cf0488 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Tue, 26 Aug 2025 22:04:42 +0200 Subject: [PATCH 4/8] Fix test with -dev version --- api/test/core/version_test.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/api/test/core/version_test.cc b/api/test/core/version_test.cc index 1ceb68602b..4b63490123 100644 --- a/api/test/core/version_test.cc +++ b/api/test/core/version_test.cc @@ -14,5 +14,7 @@ TEST(VersionTest, Consistency) OPENTELEMETRY_VERSION_MINOR, OPENTELEMETRY_VERSION_PATCH); std::string actual = OPENTELEMETRY_VERSION; - EXPECT_EQ(actual, expected); + /* OPENTELEMETRY_VERSION may contain a -dev suffix */ + std::string prefix = actual.substr(0, strlen(expected)); + EXPECT_EQ(prefix, expected); } From 41a5ade4e4e5156fbb23d0e4f4efaf0acf32cb81 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Thu, 28 Aug 2025 20:29:38 +0200 Subject: [PATCH 5/8] Cleanup --- MODULE.bazel | 2 +- api/test/core/version_test.cc | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/MODULE.bazel b/MODULE.bazel index 09d6cc00bc..b2c115d0bc 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -3,7 +3,7 @@ module( name = "opentelemetry-cpp", - version = "1.23.0", + version = "1.23.0-dev", compatibility_level = 0, repo_name = "io_opentelemetry_cpp", ) diff --git a/api/test/core/version_test.cc b/api/test/core/version_test.cc index 4b63490123..9d9e06eb9b 100644 --- a/api/test/core/version_test.cc +++ b/api/test/core/version_test.cc @@ -3,6 +3,7 @@ #include #include +#include #include #include "opentelemetry/version.h" From b5f3bda042e3b9b50354ac3c61b9c34f4633be03 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Fri, 29 Aug 2025 00:22:37 +0200 Subject: [PATCH 6/8] cleanup --- sdk/src/version/version.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sdk/src/version/version.cc b/sdk/src/version/version.cc index 2ce5434320..798b44780e 100644 --- a/sdk/src/version/version.cc +++ b/sdk/src/version/version.cc @@ -16,8 +16,8 @@ const int minor_version = 23; const int patch_version = 0; const char *pre_release = "dev"; const char *build_metadata = "none"; -const char *short_version = "1.23.0-dev"; -const char *full_version = "1.23.0-dev-none"; +const char *short_version = "1.23.0"; +const char *full_version = "1.23.0-dev"; const char *build_date = "MAIN BRANCH"; } // namespace version } // namespace sdk From 163aa2efa286463fc2c9f7160cd5e8f150e02520 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Fri, 29 Aug 2025 18:56:10 +0200 Subject: [PATCH 7/8] cleanup --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e8ea2001af..7b197fd2ff 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,7 +16,7 @@ if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.20.0") endif() set(OPENTELEMETRY_VERSION_NUMBER "1.22.0") -set(OPENTELEMETRY_VERSION_SUFFIX "") +set(OPENTELEMETRY_VERSION_SUFFIX "-dev") set(OPENTELEMETRY_VERSION "${OPENTELEMETRY_VERSION_NUMBER}${OPENTELEMETRY_VERSION_SUFFIX}") From 9fb44c5d749009a2e3d968249086afbea9a48a67 Mon Sep 17 00:00:00 2001 From: Marc Alff Date: Fri, 29 Aug 2025 20:35:43 +0200 Subject: [PATCH 8/8] Fix cmake version --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 7b197fd2ff..d6203408a0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -15,7 +15,7 @@ if(CMAKE_VERSION VERSION_GREATER_EQUAL "3.20.0") cmake_policy(SET CMP0117 NEW) endif() -set(OPENTELEMETRY_VERSION_NUMBER "1.22.0") +set(OPENTELEMETRY_VERSION_NUMBER "1.23.0") set(OPENTELEMETRY_VERSION_SUFFIX "-dev") set(OPENTELEMETRY_VERSION "${OPENTELEMETRY_VERSION_NUMBER}${OPENTELEMETRY_VERSION_SUFFIX}")