prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Suspicious point coordinates from moneygram spider.
  Found this in alltheplaces.xyz 2023-06-17, `moneygram` spider.
  
  
  <img width="1281" alt="image" src="https://github.com/alltheplaces/alltheplaces/assets/35237910/fbdccf94-5e1f-46c4-96a5-e24d6982b55c">
  
  
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `locations/spiders/moneygram.py`
  Content:
  ```
  1 from locations.hours import OpeningHours
  2 from locations.storefinders.where2getit import Where2GetItSpider
  3 
  4 
  5 class MoneyGramSpider(Where2GetItSpider):
  6     name = "moneygram"
  7     item_attributes = {"brand": "MoneyGram", "brand_wikidata": "Q1944412"}
  8     api_brand_name = "moneygram"
  9     api_key = "46493320-D5C3-11E1-A25A-4A6F97B4DA77"
  10     separate_api_call_per_country = True
  11 
  12     def parse_item(self, item, location):
  13         hours_string = ""
  14         for day_name in ["mon", "tue", "wed", "thu", "fri", "sat", "sun"]:
  15             if location.get(day_name + "_hours"):
  16                 hours_string = f"{hours_string} {day_name}: " + location.get(day_name + "_hours")
  17         item["opening_hours"] = OpeningHours()
  18         item["opening_hours"].add_ranges_from_string(hours_string)
  19         yield item
  20
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/locations/spiders/moneygram.py b/locations/spiders/moneygram.py
  --- a/locations/spiders/moneygram.py
  +++ b/locations/spiders/moneygram.py
  @@ -1,3 +1,5 @@
  +import reverse_geocoder
  +
   from locations.hours import OpeningHours
   from locations.storefinders.where2getit import Where2GetItSpider
   
  @@ -10,10 +12,25 @@
       separate_api_call_per_country = True
   
       def parse_item(self, item, location):
  +        # MoneyGram compiles location information provided by
  +        # franchises that provide MoneyGram services. Some of these
  +        # franchises are providing bad location information which
  +        # should be ignored.
  +        #
  +        # 1. Ignore Polish post office locations outside of Poland.
  +        if item["country"] == "PL" and item["name"][:3] == "UP ":
  +            if result := reverse_geocoder.get(
  +                (float(location["latitude"]), float(location["longitude"])), mode=1, verbose=False
  +            ):
  +                if result["cc"] != "PL":
  +                    item.pop("lat")
  +                    item.pop("lon")
  +
           hours_string = ""
           for day_name in ["mon", "tue", "wed", "thu", "fri", "sat", "sun"]:
               if location.get(day_name + "_hours"):
                   hours_string = f"{hours_string} {day_name}: " + location.get(day_name + "_hours")
           item["opening_hours"] = OpeningHours()
           item["opening_hours"].add_ranges_from_string(hours_string)
  +
           yield item
  
verification_info: {"golden_diff": "diff --git a/locations/spiders/moneygram.py b/locations/spiders/moneygram.py\n--- a/locations/spiders/moneygram.py\n+++ b/locations/spiders/moneygram.py\n@@ -1,3 +1,5 @@\n+import reverse_geocoder\n+\n from locations.hours import OpeningHours\n from locations.storefinders.where2getit import Where2GetItSpider\n \n@@ -10,10 +12,25 @@\n     separate_api_call_per_country = True\n \n     def parse_item(self, item, location):\n+        # MoneyGram compiles location information provided by\n+        # franchises that provide MoneyGram services. Some of these\n+        # franchises are providing bad location information which\n+        # should be ignored.\n+        #\n+        # 1. Ignore Polish post office locations outside of Poland.\n+        if item[\"country\"] == \"PL\" and item[\"name\"][:3] == \"UP \":\n+            if result := reverse_geocoder.get(\n+                (float(location[\"latitude\"]), float(location[\"longitude\"])), mode=1, verbose=False\n+            ):\n+                if result[\"cc\"] != \"PL\":\n+                    item.pop(\"lat\")\n+                    item.pop(\"lon\")\n+\n         hours_string = \"\"\n         for day_name in [\"mon\", \"tue\", \"wed\", \"thu\", \"fri\", \"sat\", \"sun\"]:\n             if location.get(day_name + \"_hours\"):\n                 hours_string = f\"{hours_string} {day_name}: \" + location.get(day_name + \"_hours\")\n         item[\"opening_hours\"] = OpeningHours()\n         item[\"opening_hours\"].add_ranges_from_string(hours_string)\n+\n         yield item\n", "issue": "Suspicious point coordinates from moneygram spider.\nFound this in alltheplaces.xyz 2023-06-17, `moneygram` spider.\r\n\r\n\r\n<img width=\"1281\" alt=\"image\" src=\"https://github.com/alltheplaces/alltheplaces/assets/35237910/fbdccf94-5e1f-46c4-96a5-e24d6982b55c\">\r\n\r\n\n", "before_files": [{"content": "from locations.hours import OpeningHours\nfrom locations.storefinders.where2getit import Where2GetItSpider\n\n\nclass MoneyGramSpider(Where2GetItSpider):\n    name = \"moneygram\"\n    item_attributes = {\"brand\": \"MoneyGram\", \"brand_wikidata\": \"Q1944412\"}\n    api_brand_name = \"moneygram\"\n    api_key = \"46493320-D5C3-11E1-A25A-4A6F97B4DA77\"\n    separate_api_call_per_country = True\n\n    def parse_item(self, item, location):\n        hours_string = \"\"\n        for day_name in [\"mon\", \"tue\", \"wed\", \"thu\", \"fri\", \"sat\", \"sun\"]:\n            if location.get(day_name + \"_hours\"):\n                hours_string = f\"{hours_string} {day_name}: \" + location.get(day_name + \"_hours\")\n        item[\"opening_hours\"] = OpeningHours()\n        item[\"opening_hours\"].add_ranges_from_string(hours_string)\n        yield item\n", "path": "locations/spiders/moneygram.py"}], "after_files": [{"content": "import reverse_geocoder\n\nfrom locations.hours import OpeningHours\nfrom locations.storefinders.where2getit import Where2GetItSpider\n\n\nclass MoneyGramSpider(Where2GetItSpider):\n    name = \"moneygram\"\n    item_attributes = {\"brand\": \"MoneyGram\", \"brand_wikidata\": \"Q1944412\"}\n    api_brand_name = \"moneygram\"\n    api_key = \"46493320-D5C3-11E1-A25A-4A6F97B4DA77\"\n    separate_api_call_per_country = True\n\n    def parse_item(self, item, location):\n        # MoneyGram compiles location information provided by\n        # franchises that provide MoneyGram services. Some of these\n        # franchises are providing bad location information which\n        # should be ignored.\n        #\n        # 1. Ignore Polish post office locations outside of Poland.\n        if item[\"country\"] == \"PL\" and item[\"name\"][:3] == \"UP \":\n            if result := reverse_geocoder.get(\n                (float(location[\"latitude\"]), float(location[\"longitude\"])), mode=1, verbose=False\n            ):\n                if result[\"cc\"] != \"PL\":\n                    item.pop(\"lat\")\n                    item.pop(\"lon\")\n\n        hours_string = \"\"\n        for day_name in [\"mon\", \"tue\", \"wed\", \"thu\", \"fri\", \"sat\", \"sun\"]:\n            if location.get(day_name + \"_hours\"):\n                hours_string = f\"{hours_string} {day_name}: \" + location.get(day_name + \"_hours\")\n        item[\"opening_hours\"] = OpeningHours()\n        item[\"opening_hours\"].add_ranges_from_string(hours_string)\n\n        yield item\n", "path": "locations/spiders/moneygram.py"}]}