nebius/SWE-bench-extra huggingface dataset:
Repository: MycroftAI/lingua-franca

Issue:
extract_datetime(" ") returns today not None
Clearly this is my favourite method looking at the issues list :yum: 

An empty string passed to `extract_datetime("")` correctly returns `None`.
However a non-empty string that does not contain a date eg `extract_datetime(" ")` returns a datetime of the current day at midnight.

Documentation for the method:
https://mycroft-core.readthedocs.io/en/stable/source/mycroft.util.html#extract-datetime

Comments:

Patch:
diff --git a/lingua_franca/lang/parse_en.py b/lingua_franca/lang/parse_en.py
index 872c478..2136423 100644
--- a/lingua_franca/lang/parse_en.py
+++ b/lingua_franca/lang/parse_en.py
@@ -1363,7 +1363,7 @@ def extract_datetime_en(string, dateNow, default_time):
             idx += used - 1
             found = True
     # check that we found a date
-    if not date_found:
+    if not date_found():
         return None
 
     if dayOffset is False:


Test patch:
diff --git a/test/test_parse.py b/test/test_parse.py
index a6533cf..c1510d9 100644
--- a/test/test_parse.py
+++ b/test/test_parse.py
@@ -481,6 +481,10 @@ class TestNormalize(unittest.TestCase):
         morning = datetime(2017, 6, 27, 8, 1, 2)
         evening = datetime(2017, 6, 27, 20, 1, 2)
         noonish = datetime(2017, 6, 27, 12, 1, 2)
+        self.assertEqual(
+            extract_datetime('feed the fish'), None)
+        self.assertEqual(
+            extract_datetime(' '), None)
         self.assertEqual(
             extract_datetime('feed fish at 10 o\'clock', morning)[0],
             datetime(2017, 6, 27, 10, 0, 0))
Repository: MycroftAI/lingua-franca

Issue:
Multiples of ten describing other multiples of ten require an intermediary number. I.e "twenty thousand" doesn't work
"twenty thousand" returns "20". The only way I have found to get this sort of situation to work is to add an extra number. "twenty four thousand" properly returns "24000".

Comments:

Patch:
diff --git a/lingua_franca/lang/parse_en.py b/lingua_franca/lang/parse_en.py
index 58207de..ef0f93d 100644
--- a/lingua_franca/lang/parse_en.py
+++ b/lingua_franca/lang/parse_en.py
@@ -444,7 +444,11 @@ def _extract_whole_number_with_text_en(tokens, short_scale, ordinals):
                 current_val = val
 
         else:
-            if prev_word in _SUMS and word not in _SUMS and current_val >= 10:
+            if all([
+                prev_word in _SUMS,
+                word not in _SUMS,
+                word not in multiplies,
+                current_val >= 10]):
                 # Backtrack - we've got numbers we can't sum.
                 number_words.pop()
                 val = prev_val


Test patch:
diff --git a/test/test_parse.py b/test/test_parse.py
index 01aec52..f5718ae 100644
--- a/test/test_parse.py
+++ b/test/test_parse.py
@@ -123,6 +123,18 @@ class TestNormalize(unittest.TestCase):
                                         short_scale=False), 1e12)
         self.assertEqual(extract_number("this is the billionth test",
                                         short_scale=False), 1e-12)
+
+        # Verify non-power multiples of ten no longer discard
+        # adjacent multipliers
+        self.assertEqual(extract_number("twenty thousand"), 20000)
+        self.assertEqual(extract_number("fifty million"), 50000000)
+
+        # This test fails due to 
+        # self.assertEqual(extract_number("twenty billion three hundred million \
+        #                                 nine hundred fifty thousand six hundred \
+        #                                 seventy five point eight six"),
+        #                                 20300950675.86)
+
         # TODO handle this case
         # self.assertEqual(
         #    extract_number("6 dot six six six"),
Repository: MycroftAI/mycroft-messagebus-client

Issue:
message.response should use message.reply internally
to account for proper message routing https://github.com/JarbasHiveMind/HiveMind-core/wiki/Mycroft-Messages + https://github.com/MycroftAI/mycroft-core/pull/2461

Comments:

Patch:
diff --git a/mycroft_bus_client/message.py b/mycroft_bus_client/message.py
index 48351ca..037e3e3 100644
--- a/mycroft_bus_client/message.py
+++ b/mycroft_bus_client/message.py
@@ -146,9 +146,7 @@ class Message:
         Returns
             (Message) message with the type modified to match default response
         """
-        response_message = Message(self.msg_type + '.response', data or {},
-                                   context or self.context)
-        return response_message
+        return self.reply(self.msg_type + '.response', data, context)
 
     def publish(self, msg_type, data, context=None):
         """


Test patch:
diff --git a/test/test_message.py b/test/test_message.py
index b1f2077..67d2939 100644
--- a/test/test_message.py
+++ b/test/test_message.py
@@ -40,6 +40,23 @@ class TestMessage(TestCase):
         self.assertEqual(response_msg.data, {})
         self.assertEqual(response_msg.context, source.context)
 
+    def test_reply(self):
+        """Assert that the source and destination are swapped"""
+        source = Message('test_type',
+                         data={'robot': 'marvin', 'android': 'data'},
+                         context={'source': 'earth',
+                                  'destination': 'alpha centauri'})
+
+        reply_msg = source.reply('reply_type')
+        self.assertEqual(reply_msg.context["source"],
+                         source.context["destination"])
+        self.assertEqual(reply_msg.context["destination"],
+                         source.context["source"])
+
+        # assert that .response calls .reply internally as stated in docstrings
+        response_msg = source.response()
+        self.assertEqual(response_msg.context, reply_msg.context)
+
     def test_dig_for_message_simple(self):
         test_msg = Message("test message", {"test": "data"}, {"time": time()})
         self.assertEqual(test_msg, get_message_standard(test_msg))