Maintenance Build Status HitCount Open Source Love Maven Central API Twitter Follow

Sherlock reports any crash that occurres in your application as a notification. You just need to initialize Sherlock at the start of your application and it will take care of the rest.


The motivation behind creating Sherlock is to make the life of Developer and tester easier. Whenever a tester is testing the app and he/she encounters a crash, most of the time they don't have enough details in their hand to enable developer to start fixing the crash immediately. Now with the help of Sherlock, any tester will have enough info to report the crash.

Alt text



debugCompile('com.github.ajitsing:sherlock:[email protected]') {
    transitive = true
releaseCompile('com.github.ajitsing:sherlock-no-op:[email protected]')


To start using Sherlock just add the below line in the onCreate() method of Application class.

public class MyApplication extends Application {
  public void onCreate() {
    Sherlock.init(this); //Initializing Sherlock

Once you add Sherlock.init(this) Sherlock will take care of reporting all the crashes to you.

See All Crashes

You can view all the crashes by starting the CrashListActivity.

Get All Crashes Captured By Sherlock

Sherlock also provides you a way to get all the crashes which are reported by Sherlock in form of java object. You can get them using below line of code.


Before accessing getInstance() make sure that you have initialized Sherlock, otherwise it will throw SherlockNotInitializedException.

App Info

By default Sherlock only captures the version of your application and shows that as part of crash details. If you want to provide some extra details regarding app, you can do so by providing an AppInfoProvider to the Sherlock.

Sherlock.setAppInfoProvider(new AppInfoProvider() {
  public AppInfo getAppInfo() {
    return new AppInfo.Builder()
               .with("Version", "2.21") //You can get the actual version using "AppInfoUtil.getAppVersion(context)"
               .with("BuildNumber", "221B")


You can contribute to Sherlock by forking the repo and creating pull requests. You can also contribute by reporting bugs/issues. If you want to see a new feature in Sherlock, just add that as an issue with enough details.


Copyright (C) 2017 Ajit Singh

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
See the License for the specific language governing permissions and
limitations under the License.