Kaynağa Gözat

Add Cambridgeshire scraper. Postcodes seem to be only partial, where they exist at all.

master
duncan.parkes 16 yıl önce
ebeveyn
işleme
bee776c03b
2 değiştirilmiş dosya ile 6 ekleme ve 6 silme
  1. +5
    -6
      python_scrapers/AcolnetParser.py
  2. +1
    -0
      python_scrapers/SitesToGenerate.csv

+ 5
- 6
python_scrapers/AcolnetParser.py Dosyayı Görüntüle

@@ -205,8 +205,6 @@ class BridgnorthParser(AcolnetParser):
#http://www2.bridgnorth-dc.gov.uk/planning/acolnetcgi.gov?ACTION=UNWRAP&RIPNAME=Root.PgeCommentForm&TheSystemkey=46958 #http://www2.bridgnorth-dc.gov.uk/planning/acolnetcgi.gov?ACTION=UNWRAP&RIPNAME=Root.PgeCommentForm&TheSystemkey=46958
return self._current_application.info_url.replace("NewPages", "PgeCommentForm") return self._current_application.info_url.replace("NewPages", "PgeCommentForm")


# Cambridgeshire, although an Acolnet site, is so different that it
# may as well be handled completely separately.


class CanterburyParser(AcolnetParser): class CanterburyParser(AcolnetParser):
"""Here the apps are one row each in a big table.""" """Here the apps are one row each in a big table."""
@@ -300,8 +298,6 @@ class SurreyHeathParser(AcolnetParser):
# return javascript_redirect_response # return javascript_redirect_response
# Wychavon is rather different, and will need some thought. There is no
# advanced search page


class BoltonLikeParser(AcolnetParser): class BoltonLikeParser(AcolnetParser):
"""Note that Bolton has ceased to be BoltonLike with its latest change of url.""" """Note that Bolton has ceased to be BoltonLike with its latest change of url."""
@@ -330,7 +326,7 @@ class HarlowParser(AcolnetParser):
return self._current_application.info_url.replace("PgeResultDetail", "PgeCommentNeighbourForm&hasreference=no") return self._current_application.info_url.replace("PgeResultDetail", "PgeCommentNeighbourForm&hasreference=no")


if __name__ == '__main__': if __name__ == '__main__':
day = 21
day = 14
month = 5 month = 5
year = 2008 year = 2008


@@ -367,6 +363,9 @@ if __name__ == '__main__':


#parser = AcolnetParser("Stockport Metropolitan Borough Council", "Stockport", "http://planning.stockport.gov.uk/PlanningData/AcolNetCGI.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch") #parser = AcolnetParser("Stockport Metropolitan Borough Council", "Stockport", "http://planning.stockport.gov.uk/PlanningData/AcolNetCGI.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch")


parser = MidBedsParser("Mid Bedfordshire District Council", "Mid Beds", "http://www.midbeds.gov.uk/acolnetDC/DCpages/acolnetcgi.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch")
# parser = MidBedsParser("Mid Bedfordshire District Council", "Mid Beds", "http://www.midbeds.gov.uk/acolnetDC/DCpages/acolnetcgi.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch")
parser = AcolnetParser("Cambridgeshire County Council", "Cambridgeshire", "http://planapps2.cambridgeshire.gov.uk/DCWebPages/AcolNetCGI.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch")


print parser.getResults(day, month, year) print parser.getResults(day, month, year)

+ 1
- 0
python_scrapers/SitesToGenerate.csv Dosyayı Görüntüle

@@ -217,3 +217,4 @@
"Middlesbrough Borough Council", "Middlesbrough", "http://planserv.middlesbrough.gov.uk/portal/page?_pageid=33,4166&_dad=portal&_schema=PORTAL", "Ocella", "OcellaParser" "Middlesbrough Borough Council", "Middlesbrough", "http://planserv.middlesbrough.gov.uk/portal/page?_pageid=33,4166&_dad=portal&_schema=PORTAL", "Ocella", "OcellaParser"
"Uttlesford District Council", "Uttlesford", "http://planning.uttlesford.gov.uk/portal/page?_pageid=33,35447&_dad=portal&_schema=PORTAL", "Ocella", "OcellaParser" "Uttlesford District Council", "Uttlesford", "http://planning.uttlesford.gov.uk/portal/page?_pageid=33,35447&_dad=portal&_schema=PORTAL", "Ocella", "OcellaParser"
"Mid Bedfordshire District Council", "Mid Beds", "http://www.midbeds.gov.uk/acolnetDC/DCpages/acolnetcgi.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch", "AcolnetParser", "MidBedsParser" "Mid Bedfordshire District Council", "Mid Beds", "http://www.midbeds.gov.uk/acolnetDC/DCpages/acolnetcgi.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch", "AcolnetParser", "MidBedsParser"
"Cambridgeshire County Council", "Cambridgeshire", "http://planapps2.cambridgeshire.gov.uk/DCWebPages/AcolNetCGI.gov?ACTION=UNWRAP&RIPNAME=Root.pgesearch", "AcolnetParser", "AcolnetParser"

Yükleniyor…
İptal
Kaydet