SERVER-85440 Support MONGO_UNIMPLEMENTED_TASSERT in errorcodes.py (#18177)

GitOrigin-RevId: cab185dfa4430aaca4fd2647978db3096c12fd11
This commit is contained in:
Ivan Fefer 2024-01-21 10:06:09 +01:00 committed by MongoDB Bot
parent 90fe2f3028
commit 43d4feb04e
4 changed files with 4 additions and 3 deletions

View File

@ -43,7 +43,7 @@ _CODE_PATTERNS = [
r"(?:StatusOK)?" r"(?:StatusOK)?"
r"(?:WithContext)?" r"(?:WithContext)?"
r"\s*\(", r"\s*\(",
r"MONGO_UNREACHABLE_TASSERT\(", r"MONGO_UN(?:REACHABLE|IMPLEMENTED)_TASSERT\(",
# DBException and AssertionException constructors # DBException and AssertionException constructors
r"(?:DB|Assertion)Exception\s*[({]", r"(?:DB|Assertion)Exception\s*[({]",
# Calls to all LOGV2* variants # Calls to all LOGV2* variants

View File

@ -33,3 +33,4 @@ iasserted(28, "words");
iassertNoTrace(29, "words"); iassertNoTrace(29, "words");
iassertedNoTrace(30, "words"); iassertedNoTrace(30, "words");
MONGO_UNREACHABLE_TASSERT(31); MONGO_UNREACHABLE_TASSERT(31);
MONGO_UNIMPLEMENTED_TASSERT(32);

View File

@ -26,7 +26,7 @@ class TestErrorcodes(unittest.TestCase):
captured_error_codes.append(code) captured_error_codes.append(code)
errorcodes.parse_source_files(accumulate_files, TESTDATA_DIR + 'regex_matching/') errorcodes.parse_source_files(accumulate_files, TESTDATA_DIR + 'regex_matching/')
self.assertEqual(31, len(captured_error_codes)) self.assertEqual(32, len(captured_error_codes))
def test_dup_checking(self): def test_dup_checking(self):
"""Test dup checking.""" """Test dup checking."""

View File

@ -558,7 +558,7 @@ public:
private: private:
void unimplementedTasserted() const { void unimplementedTasserted() const {
MONGO_UNIMPLEMENTED_TASSERT(6968504); MONGO_UNIMPLEMENTED_TASSERT(6968506);
} }
struct SharedState { struct SharedState {