Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev config flags: raise_on_error, log_payload, transmit, logger_level #867

Merged
merged 3 commits into from
May 24, 2019

Conversation

waltjones
Copy link
Contributor

@waltjones waltjones commented May 22, 2019

Implements the dev flags recently defined for all SDKs.

The verbose flag has already been implemented in this SDK as logger_level, and this remains unchanged. Further, the existing default logger_level setting of :info is retained. Finally, in keeping with the expected way of disabling config settings, setting a falsey value for logger_level disables the verbose logging completely.

Fixes #708
Fixes #813

@ArturMoczulski
Copy link
Contributor

@waltjones what do you think about adding verbose as an alias for logger_level to remain the standard across SDKs?

@tisba
Copy link

tisba commented Mar 27, 2020

I found this PR by accident.

I was wondering why the config generator does not mention these options, nor does the official documentation at https://docs.rollbar.com/docs/ruby.

I'm trying to figure out, how I can log everything in dev to the application log in development, without sending data to Rollbar. Can someone give me a hint? Thanks!

@waltjones
Copy link
Contributor Author

@tisba Yes, the docs and the generator are out of date. I've opened #948 to track this.

I think the config options you want are:

config.enabled = true
config.transmit = false
config.log_payload = true
config.logger = your_logger # e.g. Rails.logger
config.logger_level = level # :debug, :info, :warn, or :error

@tisba
Copy link

tisba commented Mar 31, 2020

That does not seem to work.

If I make these adjustments (using logger_level = :debug, I get this:

Rollbar.error("this is a test", foo: "bar")

returns "disabled" and nothing gets logged.

@joeesteves
Copy link

joeesteves commented Jul 7, 2021

It seems an access_token is always required .. even for logging

def enabled?

@waltjones waltjones deleted the wj-raise-on-error branch June 27, 2023 18:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants