Skip to content

Commit 5edc97f

Browse files
committed
add copyright to code, add LICENSE to manifest, fixes mvexel#51
1 parent 330ed80 commit 5edc97f

File tree

10 files changed

+54
-6
lines changed

10 files changed

+54
-6
lines changed

MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include LICENSE.txt

examples/readme_example.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
#!/usr/bin/env python
22

3+
# Copyright 2015-2018 Martijn van Exel.
4+
# This file is part of the overpass-api-python-wrapper project
5+
# which is licensed under Apache 2.0.
6+
# See LICENSE.txt for the full license text.
7+
38
import overpass
49

510
api = overpass.API()

examples/turn_restriction_relations_as_list.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
#!/usr/bin/env python
22

3+
# Copyright 2015-2018 Martijn van Exel.
4+
# This file is part of the overpass-api-python-wrapper project
5+
# which is licensed under Apache 2.0.
6+
# See LICENSE.txt for the full license text.
7+
38
# Retrieves a list of turn restriction relations in Toronto.
49

510
import overpass

examples/unique_users_for_area.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
#!/usr/bin/env python
22

3+
# Copyright 2015-2018 Martijn van Exel.
4+
# This file is part of the overpass-api-python-wrapper project
5+
# which is licensed under Apache 2.0.
6+
# See LICENSE.txt for the full license text.
7+
38
# Retrieves a list of unique usernames and user IDs for a named area.
49

510
import overpass

overpass/__init__.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,14 @@
11
# -*- coding: utf-8 -*-
22

3+
# Copyright 2015-2018 Martijn van Exel.
4+
# This file is part of the overpass-api-python-wrapper project
5+
# which is licensed under Apache 2.0.
6+
# See LICENSE.txt for the full license text.
7+
38
"""Thin wrapper around the OpenStreetMap Overpass API."""
49

510
__title__ = 'overpass'
6-
__version__ = '0.1.0'
11+
__version__ = '0.6.0'
712
__license__ = 'Apache 2.0'
813

914
from .api import API

overpass/api.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# Copyright 2015-2018 Martijn van Exel.
2+
# This file is part of the overpass-api-python-wrapper project
3+
# which is licensed under Apache 2.0.
4+
# See LICENSE.txt for the full license text.
5+
16
import requests
27
import json
38
import csv

overpass/errors.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
# Copyright 2015-2018 Martijn van Exel.
2+
# This file is part of the overpass-api-python-wrapper project
3+
# which is licensed under Apache 2.0.
4+
# See LICENSE.txt for the full license text.
5+
6+
17
class OverpassError(Exception):
28
"""An error during your request occurred.
39
Super class for all Overpass api errors."""

overpass/queries.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# -*- coding: utf-8 -*-
22

3+
# Copyright 2015-2018 Martijn van Exel.
4+
# This file is part of the overpass-api-python-wrapper project
5+
# which is licensed under Apache 2.0.
6+
# See LICENSE.txt for the full license text.
7+
38

49
class MapQuery(object):
510
"""Query to retrieve complete ways and relations in an area."""

overpass/utils.py

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,15 @@
1+
# Copyright 2015-2018 Martijn van Exel.
2+
# This file is part of the overpass-api-python-wrapper project
3+
# which is licensed under Apache 2.0.
4+
# See LICENSE.txt for the full license text.
5+
6+
17
class Utils(object):
28

39
@classmethod
4-
def to_overpass_id(self, osmid, area=False):
5-
AREA_BASE = 2400000000
6-
RELATION_BASE = 3600000000
10+
def to_overpass_id(cls, osmid, area=False):
11+
area_base = 2400000000
12+
relation_base = 3600000000
713
if area:
8-
return int(osmid) + AREA_BASE
9-
return int(osmid) + RELATION_BASE
14+
return int(osmid) + area_base
15+
return int(osmid) + relation_base

tests/test_api.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
# Copyright 2015-2018 Martijn van Exel.
2+
# This file is part of the overpass-api-python-wrapper project
3+
# which is licensed under Apache 2.0.
4+
# See LICENSE.txt for the full license text.
5+
16
import overpass
27

38

0 commit comments

Comments
 (0)