Skip to content
Gonzalo Bulnes Guilpain edited this page Apr 23, 2016 · 3 revisions

If you didn't find the answer to your questions in the Troubleshooting section of this wiki nor in the FAQ, it's time to ask for help!

Opening an issue

You can ask for help by opening an issue, yet you need to make sure to include enough information in it to allow people to troubleshoot it with you. To make sure your question benefits as many people as possible, it is also important to find a good place/title for your question.

  1. Gathering the relevant information
  2. Choosing a good title for a question

Gathering the relevant information

Please see the recommendations below to make sure you include everything necessary to troubleshoot the most common issues. If anything is unclear in this list, or you need help gathering the information, ask about it in your issue! : )

  • 1. Which are your token authenticatable models? - e.g. User
  • 2. How are you declaring your token authentication handlers, and which callbacks do they define? - e.g.:
# app/controllers/some_controller.rb

class SomeController < ApplicationController

   before_action: :do_something
   skip_before_action: :do_something_else, only: [:index, :show]
   acts_as_token_authentication_handler_for Admin, fallback: :exception, except: [:index, :show]
   before_filter: :do_that_too

   # ...
end

Note: this example was written using: - (see also Highlighting code blocks)

    ```ruby
    # app/controllers/some_controller.rb

    class SomeController < ApplicationController

      before_action: :do_something
      skip_before_action: :do_something_else, only: [:index, :show]
      acts_as_token_authentication_handler_for Admin, fallback: :exception, except: [:index, :show]
      before_filter: :do_that_too

      # ...
    end
    ```
  • 3. If your controller inherit from another one, which callbacks do its parent define? - e.g.:
# app/controllers/application_controller.rb

class ApplicationController < ActionController::Base

   before_action: :do_something_else, only: [:index, :show]

   # ...
end
  • 4. Which requests do you perform? - e.g.:
GET https://secure.example.com?admin_email=alice@example.com&admin_token=1G8_s7P-V-4MGojaKD7a
GET https://secure.example.com/products

X-Admin-Email alice@example.com
X-Admin-Token 1G8_s7P-V-4MGojaKD7a
  • 5. If you didn't in the introduction, what do you expect? - e.g. "I want auhtentication to be required for Admin to accede the ProductsController#index action."

Once you got that information, it's time to choose a title/place to ask you question!

Choosing a good title

Choosing a short, yet descriptive title can be difficult. Don't worry too much about it, we all define things differently. Don't try to make it too precise either, often an approximative title is better than a precise -but misleading- one!

Try to find a good title in existing issues

The title of your issue is important because it defined the topic of your question. It doesn't need to be extremely precise, however. Keeping similar topics in a single issue allow not only you, but other people to benefit from the answers you get and to understand the different aspect the same issue can have in different contexts.

The issues which are part of the FAQ have (often) quite good titles and can be used as examples.


If the title you intend to use is very similar to the title of an existing issue, it is often better to post your question in that issue first. It is always easy to move to a new issue if necessary, and other people confronted to a similar issue may benefit from the details you give in your question.


Create your own title

If none of the existing issues has a title that would match yours, use them as examples to create your own!

That's it!