title: how to use overpass to get all street in a city
body: <ol>
  <li>I am trying to get a polygon of a road using the nodes returned by overpass-api.
  For example, these code lines get all ways having the name <code>New York</code></li>
  </ol>
  <pre><code>import overpy
  api = overpy.Overpass()
  result = api.query(&quot;&quot;&quot;way[&quot;name&quot;=&quot;New York&quot;];out;&quot;&quot;&quot;)
  </code></pre>
  <p><code>result.ways</code> outputs :</p>
  <pre><code> [&lt;overpy.Way id=13299262 nodes=[122693667, 122693669]&gt;
   &lt;overpy.Way id=16853691 nodes=[174614245, 1474795638, 174617781, 174614749]&gt;,
  ...
  ]
  </code></pre>
  <p>Each way has multiple nodes. How to make a polygon of the road using those nodes, and then test if a specific gps coordinate, for example (gps=(lat=4.78, long=6.67)), lies on that road (polygon) ? <br>
  How could I handle the case where there are only two nodes available ? <br></p>
  <ol start="2">
  <li>My second question is, how to query lat and long coordinates of each node  ? I have tried it with:</li>
  </ol>
  <pre><code>for way in result.ways:
      for node in way.nodes:
          print(node.lon, node.lat)
  </code></pre>
  <p>But I get the error, <code>DataIncomplete: ('Data incomplete try to improve the query to resolve the missing data', 'Resolve missing nodes is disabled')</code>. <br>
  When I add this line: <code>nodes = way.get_nodes(resolve_missing=True)</code> as mentioned in <a href="https://readthedocs.org/projects/python-overpy/downloads/pdf/latest/" rel="nofollow noreferrer">the overpy documentation</a> , I get nothing as output. <br></p>
  <p>Any hints will be welcome.<br>
  Thanks</p>