Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Nuneaton and Bedworth Borough Council #946

Closed
3 tasks done
jpitcairn opened this issue Nov 1, 2024 · 3 comments
Closed
3 tasks done

Nuneaton and Bedworth Borough Council #946

jpitcairn opened this issue Nov 1, 2024 · 3 comments
Assignees
Labels
council request A new council request

Comments

@jpitcairn
Copy link
Contributor

jpitcairn commented Nov 1, 2024

Name of Council

Nuneaton and Bedworth Borough Council

Example Address/Postcode

Newtown Road

Search URL

https://www.nuneatonandbedworth.gov.uk/bin-day

Additional Information

I've been looking into integrating my local council. Unfortunately their available data isn't ideal to work with. Digging around some issues here I can see a lot of similarities to #448.

Findings

  • Data is in the format of an annual PDF with coloured cells for black/brown/green+brown bins.
  • Searching is based on street name (partial name will list multiple streets if there are multiple matches)
  • It looks as though some larger streets have different collection days. Searching for Newtown Road will provide 3 options, 2 of which are the same street with different collection days, based on odd/even split. E.g. -
    • Newtown Road, Bedworth (303-365 Odds, 282-292 Evens)
    • Newtown Road, Bedworth (1A - 285 Odds, 12 - 238 Evens, Croft House, Warners Court)
    • Newtown Road, Nuneaton
  • Street page provides the collection day and the week cycle (A or B) and a link to the PDF. No specific date information of which bin is on which day.
  • A and B week cycles seem to just be reversed. (Week A is Black bin while Week B is Green+brown bin.)
  • Bank Holidays don't seem to be reflected in the PDF, though from memory I believe the councils approach is leave it out and they'll get to it when they can.

I've done some scraping of their site and it looks like there are only 10 possible calendars (5 days of A+B cycles).

Looking at their accessibility information, it looks as though they are aware that PDF documents on their site aren't friendly for screen readers etc and work is being done to correct this (They mention in 2024). However, for now PDF's are all we've got.

I have reached out to the council to see if there are other formats available and am awaiting a response.

Ideas

  • Search should be straight forward, though the multiple collection schedules for some streets needs to be taken into account (Choice presented to the user I guess.).
  • I think like the excellent work done in Gedling Borough Council #448, a manually hard coded dictionary for each of the 10 options could work while the data is still in a PDF format. I'd be happy to put the work in for this if the maintainers think this is the best approach.
  • Alternatively, we know the start date of each calendar and that it always alternates between black/green+brown, except for one week per year where green is not collected, so we could just work it out.
  • When (If?) the council change this for next year, we switch to using their data.

Verification

  • I searched for similar issues at https://github.com/robbrad/UKBinCollectionData/issues?q=is:issue and found no duplicates
  • I have provided a tested working address/postcode/UPRN with bin collections available
  • I understand that this project is run by volunteer contributors and completion depends on numerous factors - even with a request, we cannot guarantee if/when your council will get a script
@jpitcairn jpitcairn added the council request A new council request label Nov 1, 2024
@jpitcairn
Copy link
Contributor Author

Have created a quick proof of concept for one of the 10 calendars. I'll do the other 9 if this solution is acceptable.

https://github.com/jpitcairn/UKBinCollectionData/blob/c97e9bb860af27b14d7d7e4995d1b25c28e57e27/uk_bin_collection/uk_bin_collection/councils/NuneatonAndBedworthBoroughCouncil.py

  • Handling scenarios where multiple results are returned - I'm thinking the most effective method is to raise an exception and to ask the user to grab the exact wording from the council site (I believe there may only be 1 or 2 instances of this anyway).

@dp247
Copy link
Collaborator

dp247 commented Nov 6, 2024

Looks good - we have some functions in common.py that can generate lists of dates (if that would prove useful), but feel free to approach it however you'd like to

@m26dvd
Copy link
Contributor

m26dvd commented Nov 23, 2024

@dp247 This one looks like it can be closed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
council request A new council request
Projects
None yet
Development

No branches or pull requests

3 participants