Giter VIP home page Giter VIP logo

buglife-ios's Introduction

Platform CocoaPods Compatible Carthage compatible License Twitter

Buglife is an awesome bug reporting SDK & web platform for iOS apps. Here's how it works:

  1. User takes a screenshot, or stops screen recording
  2. User annotates their screenshot & writes feedback
  3. Bug reports are pushed to your team's email/Jira/Slack/Asana/wherever you track bugs.

You can also find Buglife for Android here.


Main Features
πŸ‘€ Free + no account required
πŸ“– Open source
πŸƒπŸ½β€β™€οΈ Fast & lightweight
🎨 Themeable
πŸ“© Automatic caching & retry
πŸ“œ Custom form fields, with pickers & multiline text fields
ℹ️ Advanced logging, with debug / info / warning levels
πŸ“Ž Custom attachments, including JSON & SQLite support
πŸŽ₯ Attach photos & video from camera roll
πŸ“Ÿ String customization
🌎 16 languages supported, with RTL for Arabic + Hebrew
πŸ™ˆ Automatic view blurring for sensitive information
πŸ‘©πŸ½β€πŸ’» Written in Objective-C, with full Swift support

Demo

To try the example app, you can either run pod try Buglife from your command line, OR clone this repository and open the Xcode project under the β€œExample” directory.

Installation

CocoaPods

To integrate Buglife into your Xcode project using CocoaPods, specify it in your Podfile:

pod 'Buglife'

Then, run the following command:

$ pod install

Carthage

Place the following line in your Cartfile:

github "Buglife/Buglife-iOS"

Now run carthage update. Then drag & drop the Buglife.framework in the Carthage/build folder to your project. Refer to the Carthage README for detailed / updated instructions.

Manually

  1. Download the Buglife SDK

  2. Unzip it & pull Buglife.framework into the Frameworks group in your project. In the following dialog box, make sure you have "Copy items if needed" checked.

Code

  1. Import the Buglife framework header into your app delegate.

    // Swift
    import Buglife
    // Objective-C
    #import <Buglife/Buglife.h>
  2. Add the following to your app delegate's application:didFinishLaunchingWithOptions: method.

    // Swift
    Buglife.shared().start(withEmail: "[email protected]")
    // Objective-C
    [[Buglife sharedBuglife] startWithEmail:@"[email protected]"];

    Be sure to replace [email protected] with your own email address; this is where bug reports will be sent to.

Usage

Build & run your app. Once your app is running, shake your device (^⌘Z in the simulator) to report a bug! Bug reports are sent directly to your email address.

You can customize how the bug reporter is invoked. Rather than shake, we recommend configuring the bug reporter to be shown when a user takes a screenshot:

// Swift
Buglife.shared().invocationOptions = .screenshot
// Objective-C
[Buglife sharedBuglife].invocationOptions = LIFEInvocationOptionsScreenshot;

To learn more about customizing Buglife, refer to the documentation.

Requirements

  • Xcode 8 or later
  • iOS 9 or later

Contributing

We don't have any contributing guidelines at the moment, but feel free to submit pull requests & file issues within GitHub!

buglife-ios's People

Contributors

danhd123 avatar fredpi avatar merktassel avatar neonichu avatar nrbrook avatar richardgroves avatar schukin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

buglife-ios's Issues

BugLife barTintColor doesn't seem to be working

Hi,

I'm trying to give the bug reporter's navigation bar a barTintColor, but I can't seem to get it working.
I am using the following code for updating the appearance:

let appearance = Buglife.shared().appearance
appearance.tintColor = UIColor.red
appearance.barTintColor = Colors.black
appearance.titleTextAttributes = [NSForegroundColorAttributeName : UIColor.red]
appearance.statusBarStyle = .lightContent
Buglife.shared().invocationOptions = [.screenshot]
Buglife.shared().start(withAPIKey: Constants.kBugLifeAPIKey)        

Using the following code I expect the navigationbar to be black with red textlabels. But this is the result:

simulator screen shot 19 mar 2017 19 40 15

Any idea on what I'm doing wrong?
Thanks in advance

Warning: Conflicting Nullability Specifier on Return Types

Since migrating to Swift 3, we've been getting the following warning: /our-app/Pods/Buglife/Buglife.framework/Headers/Buglife.h:186:1: Conflicting nullability specifier on return types, 'nullable' conflicts with existing specifier 'nonnull'. We're using the latest version (1.3.1) of Buglife.

Truncated AppDelegate.swift

...

import Buglife

@UIApplicationMain
class AppDelegate: ..., BuglifeDelegate {

    ...

    func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {

        ...

        // Setup Bug Reporting
        Buglife.shared().start(withAPIKey: "xxx")
        Buglife.shared().invocationOptions = [.floatingButton]
        Buglife.shared().delegate = self

        ...

        // Finish Setup
        return true
    }

...

Thus far we haven't noticed any issues with Buglife, but we do have Treat Warnings as Errors set to Yes in our build settings, which is causing Buglife to throw build errors in our continuous integration cycle.

Support for Swift Package Manager

As Swift Package Manager is getting more and more support (moreover with the latest additions in Swift 5.3), is there any chance we get support for it soon?

For us it'd be a huge deal as we're migrating from Carthage to SPM πŸ‘

Feature: add explanation on first buglife report for user

I tested the workflow on someone who did not know that I integrated buglife into the app. He took a screenshot, saw the prompt for submitting a bug, accepted and then could not understand how to add arrows / magnifying glass / pixel vision, so he closed it and did not submit the bug. I imagine that numerous of people not train to bug reporting tools would not go through all the process. An explanation prompt on the first time the view is opened would help them fill bug reports.

Localizable Strings.

Can we have the Strings used in the App in a Localizable.strings? In that way they be easily localizable for any language!

Thanks!

Can't Set Invocation Option to None

We've decided to switch from using a floating button to manually triggering bug reports. This of course means setting Buglife.sharedBuglife().invocationOptions = .None as shown on your documentation.

Previous AppDelegate.swift (Truncated)

...

import Buglife

@UIApplicationMain
class AppDelegate: ..., BuglifeDelegate {

    ...

    func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?) -> Bool {

        ...

        // Setup Bug Reporting
        Buglife.shared().start(withAPIKey: "xxx")
        Buglife.shared().invocationOptions = [.floatingButton]
        Buglife.shared().delegate = self

        ...

        // Finish Setup
        return true
    }

...

However, this doesn't seem to be working:

Attempt 1
Code: swift Buglife.sharedBuglife().invocationOptions = .None
Error: 'None' has been renamed to 'none'

Attempt 2
Code: swift Buglife.sharedBuglife().invocationOptions = .none
Error :'none' is unavailable: use [:] to construct an empty option set

Attempt 3
Code: swift Buglife.sharedBuglife().invocationOptions = [:]
Error: Contextual type 'LIFEInvocationOptions' cannot be used with dictionary literal

Attempt 4
Code: swift Buglife.sharedBuglife().invocationOptions = [.None]
Error: 'None' has been renamed to 'none'

Attempt 5
Code: swift Buglife.sharedBuglife().invocationOptions = [.none]
Error: 'none' is unavailable: use [:] to construct an empty option set

As you can see, for some strange reason we can utilize every invocation option enumerated by LIFEInvocationOptions except for none. I'm using Swift 3 with Xcode 8. Any ideas?

Setting .invocationOptions = [] still results in prompt when recording video

I am trying to use Buglife with a purely manual invocation.

    Buglife.shared().invocationOptions = []
    Buglife.shared().start(withAPIKey: "<my api key>")

My app records the screen using ReplayKit's RPScreenRecorder. Whenever a recording is finished, Buglife shows up with a prompt whether I would like to add feedback to the recording.

Any way to disable this prompt?

Crash when attempting to rotate arrow

I've noticed our app occasionally crashing when using Buglife.

If you take a screenshot, draw an arrow, then attempt to rotate the arrow with two fingers, the app crashes. It looks like the Buglife is trying to create a new arrow?

The error that appears in the simulator is:
*** Terminating app due to uncaught exception 'NSRangeException', reason: '*** -[__NSArrayM replaceObjectAtIndex:withObject:]: index 9223372036854775807 beyond bounds [0 .. 1]'

Any help with this?

LIFETextInputField not editable [Any idea Why ?]

i can't write text in LIFETextInputField summary (feedback textView)

Buglife.shared().start(withAPIKey: bugLifeKey)
let appearance = Buglife.shared().appearance
appearance.tintColor = UIColor.CAPerrywinkle
Buglife.shared().invocationOptions = [.shake, .screenshot] 

Simulator Screen Shot - iPhone XS Max - 2020-04-26 at 01 02 45

Update Docs to explain how to customize floating button

I'd like to understand how to:

  • Customize where the button is displayed upon first viewing (I don't like where it starts)
  • Customize the icon/image
  • Perhaps change it from floating to stationary
  • I use an onboarding repo called Instructions which can hook a label onto a UI element .. like
    UIelement.helpLabel.text = "This is the exciting UIelement" .. How can I do that with the floating button? I'm using Swift and know little about poking around in objc

Programmatically add fields to a bug report

I know you can make an attachment and tag it along, but it would be incredibly useful to add custom fields, or just 1 if adding multiple would be hard, to a bug report. Then have that information get passed along to the current integrations as well.

Proper support for Carthage

I'm trying to build this framework with Carthage using Xcode 10.2 and Swift 5.

It seems that framework itself builds nicely, however since the Example scheme and workspaces is there two - they are built as well. And they fail thus leaving me with failed build of framework too.

Suggestion: add user-id to the report email

Currently, the report email includes only the reporter’s email. In order to get their user_id, one need to open the actual report. Would be great if it can include the user_id

Thanks!

Unintended invocations

I have the invocation options set to [.shake]. Some people are reporting that…

Send feedback keeps popping up for no reason

I have seen once before, that when I returned to the app it was displaying Buglife. I am wondering if the shake event could be happening when people drop their phone down on the table.

Given my invocation options are only .shake, and I am not calling presentReporter could there be another explanation for what people are reporting?

Undefined symbols

Hi,

Buglife SDK version: 2.10.1
macOS: 10.14.4
Xcode: 10.1 (10B61)

After downloading Buglife SDK and plugging it into the project I receive the following linking errors:

Undefined symbols for architecture x86_64:
  "_OBJC_CLASS_$_LIFEAlertAction", referenced from:
      objc-class-ref in Buglife(Buglife+UIStuff.o)
  "_OBJC_CLASS_$_LIFEImageEditorView", referenced from:
      objc-class-ref in Buglife(LIFEContainerAlertToImageEditorAnimator.o)
  "_OBJC_CLASS_$_LIFEAlertAnimator", referenced from:
      objc-class-ref in Buglife(LIFEContainerViewController.o)
  "_OBJC_CLASS_$_LIFEAlertController", referenced from:
      objc-class-ref in Buglife(LIFEContainerViewController.o)
      objc-class-ref in Buglife(Buglife+UIStuff.o)
  "_OBJC_CLASS_$_LIFEImageEditorViewController", referenced from:
      objc-class-ref in Buglife(LIFEReportTableViewController.o)
      objc-class-ref in Buglife(LIFEContainerViewController.o)
      objc-class-ref in Buglife(Buglife.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Update: it seems that installation instructions on the website have link to the faulty sdk. Installing the SDK by following instructions here (btw, using Carthage) - worked correctly.

bug: statusBar rotate in landscape though restricted using FloatingButton

Hi guys, found a litte bug.
StatusBar rotates in landscape while using LIFEInvocationOptions.FloatingButton and rotating device to landscape although UIInterfaceOrientation is restricted to portrait by overriding func supportedInterfaceOrientations() -> UIInterfaceOrientationMask. The topViewController stays in portrait.
I have to override the method because 2 viewController should allow landscape.

Settings in Info.plist -> Deployment Info -> Device Orientation
[x] Portrait
[ ] Upside Down
[x] Landscape Left
[x] Landscape Right

Thanks for your super cool tool!

Feature: Make integrations togglable per report

Say I have an integration with JIRA and Slack. I would like to be able to send a bug report to only Jira, Slack, or neither and just send the email. This could be an option when submitting the report.

Build error

Xcode: 8.3.3
Buglife: 1.9.2~4
Message:

Undefined symbols for architecture x86_64:
  "_UIScreenCapturedDidChangeNotification", referenced from:
      -[Buglife setScreenRecordingInvocationEnabled:] in Buglife(Buglife.o)
  "___isOSVersionAtLeast", referenced from:
      -[LIFEScreenshotAnnotatorView life_configureConstraints] in Buglife(LIFEScreenshotAnnotatorView.o)
      -[Buglife setScreenRecordingInvocationEnabled:] in Buglife(Buglife.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)

The above error occurs when building from the simulator after 1.9.2~4 has been updated.
(our build CI got very sad. 😭)

Current framework requires extra app permission with XCode 8

The current build of the framework installed via cocoapods (version 1.3.0) will trigger an 'Invalid binary' rejection from Apple when an app is submitted to the app store after building with XCode 8.

Exact rejection text is:

"This app attempts to access privacy-sensitive data without a usage description. The app's Info.plist must contain an NSPhotoLibraryUsageDescription key with a string value explaining to the user how the app uses this data."

It seems at about the GM time of the latest XCode cycle they fired up a new static analyser that is even more aggressive about code that even looks like it touches the camera or photo library (Other libraries are triggering various other warnings too - http://stackoverflow.com/questions/39383289/ios-10-gm-release-error-when-submitting-apps-this-app-attempts-to-access-privac)

Screen not launching in SwiftUI app

Hi, I'm trying to run this in my SwiftUI app. The code is getting all the way to
[self _showContainerWindowWithViewController:nav animated:animated completion:completionBlock];

but no window appears. Any idea how to connect this with my SwiftUI views?

Add attachement button (iOS)

Hi
Do you guys plan to make the add attachement button optional and not only based on the camera roll permission.
Do you accept pull requests if we implement this small opt in feature ?
This is how we'd like to use it :

Buglife.shared().makeAddAttachementButtonAvailable = NO; //YES is default value

Should use aliases instead of duplicate files in .framework

Instead of having duplicate headers and binary throughout the .framework, a single binary and set of headers under .framework/Versions/A would suffice and then .framework/Versions/Current would alias to .framework/Versions/A, .framework/Headers would alias to .framework/Versions/A/Headers, .framework/Modules would alias to .framework/Versions/A/Modules, and .framework/Buglife would alias to .framework/Versions/A/Buglife. This would cut the size of the framework by one third (66%).

Bug Life not working..

I added pod 'Buglife' in pod file.

It has no error when building. and added Privacy - Photo Library Usage Description in Info.plist.

But when taking a screenshot , it has no action triggered.

I tested this sdk on empty project. it's nothing to do action.

A diffrenent thing with sample is using SceneDelegate.

When co-existing with SceneDelagte, is there any settings I have to do?

Status bar colour is changed

When I use the shake gesture or screenshot (not tested button) to bring up the bug report action sheet the status bar on my ViewController is changed from white to black text.

Tested on:
iOS9.2, simulator iPhone5s, using XCode 7.2
iOS9.2, iPhone 6+, launched from XCode 7.2

On device the status bar colour resets as soon as the action sheet is dismissed, on simulator it takes a tap on the 'screen' for it to reset.

Will there be any more Framework?

Will there be any more Framework?
I.e. from version 2.0.0

I'm not a fan of using that damn CocoaPods or adding a million sources.

Misused `barTintColor` when setting up UI

Setting barTintColor on LIFEAppearance proxy messes up UI if the barTintColor is black.

I have these two colors:

  • primary color: 0x6CA130
  • accent color: 0x252424

Setting them as either tint/barTint or barTint/tint colors respectively doesn't yield nice results because setting barTintColor sets the text tint for action buttons in an alert view that is present once user shakes the device AND sets the background color for image editor.

Possible solution might be introducing either backgroundTintColor OR not setting the text to barTintColor, but rather using tintColor.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.