Tests: Add tests for graph listing, some cleanup
Fix handling of invalid graph parameters, including API tests
server: Add handler for uncaught exceptions

Just to keep the server from crashing