prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  Spider dominos_pizza_jp is broken
  During the global build at 2021-06-30-14-42-26, spider **dominos_pizza_jp** failed with **0 features** and **0 errors**.
  
  Here's [the log](https://data.alltheplaces.xyz/runs/2021-06-30-14-42-26/logs/dominos_pizza_jp.txt) and [the output](https://data.alltheplaces.xyz/runs/2021-06-30-14-42-26/output/dominos_pizza_jp.geojson) ([on a map](https://data.alltheplaces.xyz/map.html?show=https://data.alltheplaces.xyz/runs/2021-06-30-14-42-26/output/dominos_pizza_jp.geojson))
  
  </issue>
  <code>
  [start of locations/spiders/dominos_pizza_jp.py]
  1 # -*- coding: utf-8 -*-
  2 import re
  3 
  4 import scrapy
  5 
  6 from locations.items import GeojsonPointItem
  7 
  8 
  9 class DominosPizzaJPSpider(scrapy.Spider):
  10     name = "dominos_pizza_jp"
  11     item_attributes = {"brand": "Domino's", "brand_wikidata": "Q839466"}
  12     allowed_domains = ["dominos.jp"]
  13     start_urls = [
  14         "https://www.dominos.jp/sitemap.aspx",
  15     ]
  16     download_delay = 0.3
  17 
  18     def parse(self, response):
  19         response.selector.remove_namespaces()
  20         store_urls = response.xpath('//url/loc/text()[contains(.,"/store/")]').extract()
  21         for url in store_urls:
  22             yield scrapy.Request(url, callback=self.parse_store)
  23 
  24     def parse_store(self, response):
  25         ref = re.search(r".+/(.+?)/?(?:\.html|$)", response.url).group(1)
  26 
  27         properties = {
  28             "ref": ref,
  29             "name": response.xpath(
  30                 'normalize-space(//div[@class="storetitle"][1]/text())'
  31             ).extract_first(),
  32             "addr_full": response.xpath(
  33                 'normalize-space(//span[@id="store-address-info"]/p/a/text())'
  34             ).extract_first(),
  35             "postcode": re.search(
  36                 r"([\d-]*)$",
  37                 response.xpath(
  38                     'normalize-space(//div[@class="store-details-text"][1]/p/text())'
  39                 ).extract_first(),
  40             ).group(1),
  41             "country": "JP",
  42             "lat": response.xpath(
  43                 'normalize-space(//input[@id="store-lat"]/@value)'
  44             ).extract_first(),
  45             "lon": response.xpath(
  46                 'normalize-space(//input[@id="store-lon"]/@value)'
  47             ).extract_first(),
  48             "phone": re.search(
  49                 r"\s([\d-]*)$",
  50                 response.xpath('//div[@id="store-tel"]/a/text()').extract_first(),
  51             ).group(1),
  52             "website": response.url,
  53         }
  54 
  55         yield GeojsonPointItem(**properties)
  56
  [end of locations/spiders/dominos_pizza_jp.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/locations/spiders/dominos_pizza_jp.py b/locations/spiders/dominos_pizza_jp.py
  --- a/locations/spiders/dominos_pizza_jp.py
  +++ b/locations/spiders/dominos_pizza_jp.py
  @@ -8,7 +8,11 @@
   
   class DominosPizzaJPSpider(scrapy.Spider):
       name = "dominos_pizza_jp"
  -    item_attributes = {"brand": "Domino's", "brand_wikidata": "Q839466"}
  +    item_attributes = {
  +        "brand": "Domino's",
  +        "brand_wikidata": "Q839466",
  +        "country": "JP",
  +    }
       allowed_domains = ["dominos.jp"]
       start_urls = [
           "https://www.dominos.jp/sitemap.aspx",
  @@ -27,28 +31,24 @@
           properties = {
               "ref": ref,
               "name": response.xpath(
  -                'normalize-space(//div[@class="storetitle"][1]/text())'
  +                'normalize-space(//h1[@class="storetitle"][1]/text())'
               ).extract_first(),
               "addr_full": response.xpath(
  -                'normalize-space(//span[@id="store-address-info"]/p/a/text())'
  +                'normalize-space(//span[@id="store-address-info"]/p/text()[4])'
               ).extract_first(),
               "postcode": re.search(
                   r"([\d-]*)$",
                   response.xpath(
  -                    'normalize-space(//div[@class="store-details-text"][1]/p/text())'
  +                    'normalize-space(//div[@class="store-details-text"]/span/p/text()[2])'
                   ).extract_first(),
               ).group(1),
  -            "country": "JP",
               "lat": response.xpath(
                   'normalize-space(//input[@id="store-lat"]/@value)'
               ).extract_first(),
               "lon": response.xpath(
                   'normalize-space(//input[@id="store-lon"]/@value)'
               ).extract_first(),
  -            "phone": re.search(
  -                r"\s([\d-]*)$",
  -                response.xpath('//div[@id="store-tel"]/a/text()').extract_first(),
  -            ).group(1),
  +            "phone": response.xpath('//div[@id="store-tel"]/a/text()').extract_first(),
               "website": response.url,
           }
  
verification_info: {"golden_diff": "diff --git a/locations/spiders/dominos_pizza_jp.py b/locations/spiders/dominos_pizza_jp.py\n--- a/locations/spiders/dominos_pizza_jp.py\n+++ b/locations/spiders/dominos_pizza_jp.py\n@@ -8,7 +8,11 @@\n \n class DominosPizzaJPSpider(scrapy.Spider):\n     name = \"dominos_pizza_jp\"\n-    item_attributes = {\"brand\": \"Domino's\", \"brand_wikidata\": \"Q839466\"}\n+    item_attributes = {\n+        \"brand\": \"Domino's\",\n+        \"brand_wikidata\": \"Q839466\",\n+        \"country\": \"JP\",\n+    }\n     allowed_domains = [\"dominos.jp\"]\n     start_urls = [\n         \"https://www.dominos.jp/sitemap.aspx\",\n@@ -27,28 +31,24 @@\n         properties = {\n             \"ref\": ref,\n             \"name\": response.xpath(\n-                'normalize-space(//div[@class=\"storetitle\"][1]/text())'\n+                'normalize-space(//h1[@class=\"storetitle\"][1]/text())'\n             ).extract_first(),\n             \"addr_full\": response.xpath(\n-                'normalize-space(//span[@id=\"store-address-info\"]/p/a/text())'\n+                'normalize-space(//span[@id=\"store-address-info\"]/p/text()[4])'\n             ).extract_first(),\n             \"postcode\": re.search(\n                 r\"([\\d-]*)$\",\n                 response.xpath(\n-                    'normalize-space(//div[@class=\"store-details-text\"][1]/p/text())'\n+                    'normalize-space(//div[@class=\"store-details-text\"]/span/p/text()[2])'\n                 ).extract_first(),\n             ).group(1),\n-            \"country\": \"JP\",\n             \"lat\": response.xpath(\n                 'normalize-space(//input[@id=\"store-lat\"]/@value)'\n             ).extract_first(),\n             \"lon\": response.xpath(\n                 'normalize-space(//input[@id=\"store-lon\"]/@value)'\n             ).extract_first(),\n-            \"phone\": re.search(\n-                r\"\\s([\\d-]*)$\",\n-                response.xpath('//div[@id=\"store-tel\"]/a/text()').extract_first(),\n-            ).group(1),\n+            \"phone\": response.xpath('//div[@id=\"store-tel\"]/a/text()').extract_first(),\n             \"website\": response.url,\n         }\n", "issue": "Spider dominos_pizza_jp is broken\nDuring the global build at 2021-06-30-14-42-26, spider **dominos_pizza_jp** failed with **0 features** and **0 errors**.\n\nHere's [the log](https://data.alltheplaces.xyz/runs/2021-06-30-14-42-26/logs/dominos_pizza_jp.txt) and [the output](https://data.alltheplaces.xyz/runs/2021-06-30-14-42-26/output/dominos_pizza_jp.geojson) ([on a map](https://data.alltheplaces.xyz/map.html?show=https://data.alltheplaces.xyz/runs/2021-06-30-14-42-26/output/dominos_pizza_jp.geojson))\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\nimport re\n\nimport scrapy\n\nfrom locations.items import GeojsonPointItem\n\n\nclass DominosPizzaJPSpider(scrapy.Spider):\n    name = \"dominos_pizza_jp\"\n    item_attributes = {\"brand\": \"Domino's\", \"brand_wikidata\": \"Q839466\"}\n    allowed_domains = [\"dominos.jp\"]\n    start_urls = [\n        \"https://www.dominos.jp/sitemap.aspx\",\n    ]\n    download_delay = 0.3\n\n    def parse(self, response):\n        response.selector.remove_namespaces()\n        store_urls = response.xpath('//url/loc/text()[contains(.,\"/store/\")]').extract()\n        for url in store_urls:\n            yield scrapy.Request(url, callback=self.parse_store)\n\n    def parse_store(self, response):\n        ref = re.search(r\".+/(.+?)/?(?:\\.html|$)\", response.url).group(1)\n\n        properties = {\n            \"ref\": ref,\n            \"name\": response.xpath(\n                'normalize-space(//div[@class=\"storetitle\"][1]/text())'\n            ).extract_first(),\n            \"addr_full\": response.xpath(\n                'normalize-space(//span[@id=\"store-address-info\"]/p/a/text())'\n            ).extract_first(),\n            \"postcode\": re.search(\n                r\"([\\d-]*)$\",\n                response.xpath(\n                    'normalize-space(//div[@class=\"store-details-text\"][1]/p/text())'\n                ).extract_first(),\n            ).group(1),\n            \"country\": \"JP\",\n            \"lat\": response.xpath(\n                'normalize-space(//input[@id=\"store-lat\"]/@value)'\n            ).extract_first(),\n            \"lon\": response.xpath(\n                'normalize-space(//input[@id=\"store-lon\"]/@value)'\n            ).extract_first(),\n            \"phone\": re.search(\n                r\"\\s([\\d-]*)$\",\n                response.xpath('//div[@id=\"store-tel\"]/a/text()').extract_first(),\n            ).group(1),\n            \"website\": response.url,\n        }\n\n        yield GeojsonPointItem(**properties)\n", "path": "locations/spiders/dominos_pizza_jp.py"}]}