All Projects → balsikandar → Robin

balsikandar / Robin

Licence: mit
Robin is a logging library for Bundle data passed between Activities and fragments. It also provides a callback to send screen views of user visited pages to your analytics client

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to Robin

jquery-manager
Manage jQuery and jQuery Migrate on a WordPress website, activate a specific jQuery and/or jQuery Migrate version. The ultimate jQuery debugging tool for WordPress
Stars: ✭ 27 (-57.14%)
Mutual labels:  debugging, debugging-tool
Tensorwatch
Debugging, monitoring and visualization for Python Machine Learning and Data Science
Stars: ✭ 3,191 (+4965.08%)
Mutual labels:  debugging, debugging-tool
Debugo
一个可能有点用的 iOS 调试工具~
Stars: ✭ 258 (+309.52%)
Mutual labels:  debugging, debugging-tool
Mediator
Cross-platform GUI gRPC debugging proxy
Stars: ✭ 36 (-42.86%)
Mutual labels:  debugging, debugging-tool
Bugsnag Laravel
Bugsnag notifier for the Laravel PHP framework. Monitor and report Laravel errors.
Stars: ✭ 746 (+1084.13%)
Mutual labels:  debugging, debugging-tool
guide-charles-proxy
Charles - Web Debugging Proxy Application. I want to share my experiences when I worked with Charles. It is such an amazing application for debugging and testing the presentation of UI when trying different set of data. Hope you guys will master Charles after reading this section. Let’s find out! 🖍
Stars: ✭ 22 (-65.08%)
Mutual labels:  debugging, debugging-tool
Tapping device
TappingDevice makes objects tell you what they do, so you don't need to track them yourself.
Stars: ✭ 296 (+369.84%)
Mutual labels:  debugging, debugging-tool
docker-pudb
Debug Python code within a Docker container remotely from your terminal using pudb
Stars: ✭ 18 (-71.43%)
Mutual labels:  debugging, debugging-tool
Superdump
A service for automated crash-dump analysis
Stars: ✭ 384 (+509.52%)
Mutual labels:  debugging, debugging-tool
Xcglogger
A debug log framework for use in Swift projects. Allows you to log details to the console (and optionally a file), just like you would have with NSLog() or print(), but with additional information, such as the date, function name, filename and line number.
Stars: ✭ 3,710 (+5788.89%)
Mutual labels:  debugging, debugging-tool
madbomber
Backtrace-on-throw C++ exception logger
Stars: ✭ 17 (-73.02%)
Mutual labels:  debugging, debugging-tool
Power trace
Buff exception backtrace with local variables, passed in arguments and instance variables!
Stars: ✭ 48 (-23.81%)
Mutual labels:  debugging, debugging-tool
pydbg
Python implementation of the Rust `dbg` macro
Stars: ✭ 85 (+34.92%)
Mutual labels:  debugging, debugging-tool
caddy-trace
Request Debugging Middleware Plugin for Caddy v2
Stars: ✭ 25 (-60.32%)
Mutual labels:  debugging, debugging-tool
devmod
Developer Module for debugging web applications
Stars: ✭ 16 (-74.6%)
Mutual labels:  debugging, debugging-tool
Watchpoints
watchpoints is an easy-to-use, intuitive variable/object monitor tool for python that behaves similar to watchpoints in gdb.
Stars: ✭ 261 (+314.29%)
Mutual labels:  debugging, debugging-tool
vscode-cc65-debugger
VSCode extension for CC65 debugging with VICE or Mesen
Stars: ✭ 26 (-58.73%)
Mutual labels:  debugging, debugging-tool
awesome print.cr
It dreams about becoming ruby's awesome_print for crystal-lang, under light development.
Stars: ✭ 13 (-79.37%)
Mutual labels:  debugging, debugging-tool
Cocoadebug
iOS Debugging Tool 🚀
Stars: ✭ 3,769 (+5882.54%)
Mutual labels:  debugging, debugging-tool
Bugsnag Android
Bugsnag crash monitoring and reporting tool for Android apps
Stars: ✭ 990 (+1471.43%)
Mutual labels:  debugging, debugging-tool

Robin

Android Arsenal Android Arsenal API Download Open Source Love License

Robin is a library to log Bundle data passed between Activities and fragments.

It's hard to reproduce a bug that's why we should log data that can reduce human efforts.

One of my friend said this and it's totally true. That's why i always try to log essential data.

Here is an article related to this project.

Bundle

Definition: A mapping from String values to various Parcelable types. Bundle is generally used for passing data between various activities of android.

I have spent good amount of time to debug these at times, depending on code quality i had to work on. Sometimes even tester need to see what id or values we're passing to open a given page and then i had to add logs for them. So i thought let's do something about this.

Robin In Action APIs

  • Log Bundle data passed between Activity and Fragments.
  • A Callback method to send screen views events to Google Analytics or other clients
  • A Callback method for Activity/Fragment lifecycle which can be used to retrace user activities before crashes
  • An API to transform Intent or Bundle data as HashMap (key-value)
This library doesn't requires any permission or root access

To use this in your app

Use below dependency to add it in your app

compile 'com.balsikandar.android:robin:0.1.2'

If you only want to use it in your debug app then use debugCompile dependency

debugCompile 'com.balsikandar.android:robin:0.1.2'

Robin in action

Initialise this library in your Application class using

Robin.start(this)

If you only want to use bundle data logging and disable other callbacks then initialise Robin as

Robin.start(this, false)

The other moves of Robin

1- Tracking screen views

AnalyticsClient.sendView(AppConstants.ScreenViewLabel);

To simplify that, you can implement ScreenViewCallback interface in your application class which provides below callback method

    @Override
    public void onScreenShown(String className, String customScreenView) {
        
    }

className: is actual Activity/Fragment name which you can use to log screenName on your analytics client.

customScreenView: but a lot of times we need to log custom screenNames. To do that you can declare a global variable named screenView in your Activity/Fragment classes and it'll be returned as customScreenView in onScreenShown callback.

Define a global variable screenView in your Activity/Fragment with label value

private String screenView = "RobinSampleHomePage";

2- Retrace user actions before a Crash

At times we get stacktrace log where we have no idea of where it's originated and it's not even possible to figure out in which class crash occurred.

Whatever you log with Crashlytics.log(msg) gets associated with the crashes and is viewable in crashlytics dashboard. These log can really help in narrowing down origin of a crash and Activity/Fragment lifecycle callback methods can come in handy.

To do this, implement LifeCycleCallbacks interface in your application class which provides below callback method

    @Override
    public void breadCrumps(String name, String callback) {
        
    }

name: is Activity/Fragment class name, callback: is lifecycle callback method name

3- Transform Bundle data to HashMap

Use Below APIs to get bundle data as HashMap key-value pairs

   Robin.getDataAsMap(intent)
    
   Robin.getDataAsMap(bundle)

you can also call below APIs explicitly to log bundle or intent data

   Robin.logData(intent, "tagName");
   
   Robin.logData(bundle, "tagName");

tagName- provide this field to filter log in LogCat and if you don't provide this tag Robin/ will be used.

Contributing to this Repo

If you have a feature request or suggestion raise a Ticket here. You can also contribute just create a pull request and dive in.

Find this project useful ? ❤️

  • Support it by clicking the ⭐️ button on the upper right of this page. ✌️

That's it for now

For any query or questions you can access me at below mediums.

TODO

Add application enter foreground and background callbacks Add logic to calculate the size of bundle in transaction.

Contact - Let's connect and share knowledge

License

MIT License

Copyright (c) 2018 BAL SIKANDAR

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].