Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

Chain Provider catch Exception

Open
#881 7 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
php
Domain
backend

Research direction

Start by reading the final Chain class and its provider execution path to understand where exceptions are currently logged and converted into an empty AddressCollection. Check nearby tests for chain-provider behavior, then define completion as exposing a reliable way for callers to distinguish no results from provider errors and covering that behavior with tests.

Written by the indexing model from the issue text.

Description

question

Hi,

Currently, the chain provider only logs the exceptions, there is no way to catch the exceptions and we always get an empty AddressCollection in case something went wrong. There is no way to know if the collection is empty because there were no results or if an error occurred.

A simple customized solution would be to extend the class Chain and throw the exception but it's not possible since it's final. All I can do is to replicate the class (not best solution).

If there is a workaround about this I would like to hear about it, otherwise I guess it must be implemented a way to catch the erros.

Thank you.

Dominant language
PHP
Stars
4k
Forks
525
Avg merge
8m
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from geocoder-php/Geocoder

All issues in geocoder-php/Geocoder

Similar issues

More PHP issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.