Skip to content

Remove noexcept from line_sender::protocol_version() and line_sender::new_buffer()#130

Open
arghness wants to merge 1 commit intoquestdb:mainfrom
arghness:main
Open

Remove noexcept from line_sender::protocol_version() and line_sender::new_buffer()#130
arghness wants to merge 1 commit intoquestdb:mainfrom
arghness:main

Conversation

@arghness
Copy link

@arghness arghness commented Dec 9, 2025

These methods can both throw due to ensure_impl() throwing.

Fixes #131

Summary by CodeRabbit

  • Breaking Changes
    • Exception-safety guarantees have been removed from two core API methods. These methods may now throw exceptions in scenarios where exceptions were previously guaranteed not to occur. Applications relying on the previous no-throw behavior should be reviewed.

✏️ Tip: You can customize this high-level summary in your review settings.

These methods can both throw due to ensure_impl() throwing.
@coderabbitai
Copy link

coderabbitai bot commented Dec 9, 2025

📝 Walkthrough

Walkthrough

Two public methods in the line sender interface had their noexcept specifiers removed: protocol_version() and new_buffer(). This changes their exception-safety guarantees from no-throw to potentially-throwing.

Changes

Cohort / File(s) Summary
Exception-safety specification changes
include/questdb/ingress/line_sender.hpp
Removed noexcept specifier from protocol_version() const and new_buffer(size_t init_buf_size = 64 \* 1024) methods, permitting these methods to throw exceptions

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • Note: Verify that callers of these two methods are prepared to handle potential exceptions, and confirm that the removal of noexcept aligns with actual implementation behavior changes in the corresponding .cpp file(s).

Poem

🐰 The noexcept bonds have come undone,
Our methods now may throw with fun,
Exception-safe no more they'll be,
They leap and dance so wild and free!

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 50.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title directly and specifically describes the main change in the pull request: removing noexcept from two named methods.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
  • 📝 Generate docstrings

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

C++ API aborts due to incorrect noexcept specification

1 participant