keboola / common-exceptions
Common exceptions shared between different applications
Installs: 122 802
Dependents: 15
Suggesters: 0
Security: 0
Stars: 0
Watchers: 19
Forks: 0
Language:Dockerfile
Requires
- php: ^7.1|^8.0
Requires (Dev)
- keboola/coding-standard: ^13.0
- keboola/php-temp: ^1.0
- php-parallel-lint/php-parallel-lint: ^1.3
- phpstan/phpstan: ^0.12.93
- phpunit/phpunit: ^8.0
README
This package provides common exception interfaces to be shared between different Keboola systems.
Usage
In your library or application implement
UserExceptionInterface
for exceptions that are caused by user's error. That usually means validation failures, HTTP404s, HTTP403s, etc. Anything where user can take any step to fix it.Also there is
ApplicationExceptionInterface
for the other thing - where you want to explicitly state that the exception is NOT user error.
Development
Clone this repository and init the workspace with following command:
git clone https://github.com/keboola/common-exceptions
cd common-exceptions
docker-compose build
docker-compose run --rm dev composer install --no-scripts
Run the test suite using this command:
docker-compose run --rm dev composer tests
Integration
For information about deployment and integration with KBC, please refer to the deployment section of developers documentation
License
MIT licensed, see LICENSE file.