Before process_action callback :set_current_usuario has not been defined
Extracted source (around line #641):
639
640
641
642
643
644
|
if !callback && options[:raise]
raise ArgumentError, "#{type.to_s.capitalize} #{name} callback #{filter.inspect} has not been defined"
end
if callback && (options.key?(:if) || options.key?(:unless))
|
Extracted source (around line #637):
635
636
637
638
639
640
|
__update_callbacks(name) do |target, chain|
filters.each do |filter|
callback = chain.find {|c| c.matches?(type, filter) }
if !callback && options[:raise]
|
Extracted source (around line #637):
635
636
637
638
639
640
|
__update_callbacks(name) do |target, chain|
filters.each do |filter|
callback = chain.find {|c| c.matches?(type, filter) }
if !callback && options[:raise]
|
Extracted source (around line #568):
566
567
568
569
570
571
|
([self] + ActiveSupport::DescendantsTracker.descendants(self)).reverse_each do |target|
chain = target.get_callbacks name
yield target, chain.dup
end
end
|
Extracted source (around line #566):
564
565
566
567
568
569
|
# CallbackChain.
def __update_callbacks(name) #:nodoc:
([self] + ActiveSupport::DescendantsTracker.descendants(self)).reverse_each do |target|
chain = target.get_callbacks name
yield target, chain.dup
end
|
Extracted source (around line #566):
564
565
566
567
568
569
|
# CallbackChain.
def __update_callbacks(name) #:nodoc:
([self] + ActiveSupport::DescendantsTracker.descendants(self)).reverse_each do |target|
chain = target.get_callbacks name
yield target, chain.dup
end
|
Extracted source (around line #636):
634
635
636
637
638
639
|
options[:raise] = true unless options.key?(:raise)
__update_callbacks(name) do |target, chain|
filters.each do |filter|
callback = chain.find {|c| c.matches?(type, filter) }
|
Extracted source (around line #212):
210
211
212
213
214
215
|
define_method "skip_#{callback}_action" do |*names|
_insert_callbacks(names) do |name, options|
skip_callback(:process_action, callback, name, options)
end
end
|
Extracted source (around line #95):
93
94
95
96
97
98
|
callbacks.push(block) if block
callbacks.each do |callback|
yield callback, options
end
end
|
Extracted source (around line #94):
92
93
94
95
96
97
|
_normalize_callback_options(options)
callbacks.push(block) if block
callbacks.each do |callback|
yield callback, options
end
end
|
Extracted source (around line #94):
92
93
94
95
96
97
|
_normalize_callback_options(options)
callbacks.push(block) if block
callbacks.each do |callback|
yield callback, options
end
end
|
Extracted source (around line #211):
209
210
211
212
213
214
|
# for details on the allowed parameters.
define_method "skip_#{callback}_action" do |*names|
_insert_callbacks(names) do |name, options|
skip_callback(:process_action, callback, name, options)
end
end
|
Extracted source (around line #5):
3
4
5
6
7
8
|
skip_before_action :verify_authenticity_token
skip_before_action :authenticate_from_token
skip_before_action :set_current_usuario
skip_before_action :authenticate_usuario!
before_action :verify_last_login, :only => [
|
Extracted source (around line #1):
1
2
3
4
5
6
|
class Geowise::AgendamentoController < ApplicationController
skip_before_action :verificar_permissoes_para_pagina_atual
skip_before_action :verify_authenticity_token
skip_before_action :authenticate_from_token
skip_before_action :set_current_usuario
skip_before_action :authenticate_usuario!
|
Extracted source (around line #478):
476
477
478
479
480
481
|
result = nil
newly_defined_paths = new_constants_in(*parent_paths) do
result = Kernel.load path
end
autoloaded_constants.concat newly_defined_paths unless load_once_path?(path)
|
Extracted source (around line #478):
476
477
478
479
480
481
|
result = nil
newly_defined_paths = new_constants_in(*parent_paths) do
result = Kernel.load path
end
autoloaded_constants.concat newly_defined_paths unless load_once_path?(path)
|
Extracted source (around line #663):
661
662
663
664
665
666
|
begin
yield # Now yield to the code that is to define new constants.
success = true
ensure
new_constants = constant_watch_stack.new_constants
|
Extracted source (around line #477):
475
476
477
478
479
480
|
result = nil
newly_defined_paths = new_constants_in(*parent_paths) do
result = Kernel.load path
end
|
Extracted source (around line #375):
373
374
375
376
377
378
|
if !warnings_on_first_load or history.include?(expanded)
result = load_file(*load_args)
else
enable_warnings { result = load_file(*load_args) }
end
|
Extracted source (around line #37):
35
36
37
38
39
40
|
# block at the same time.
def self.load_interlock
Dependencies.interlock.loading { yield }
end
# Execute the supplied block while holding an exclusive lock,
|
Extracted source (around line #12):
10
11
12
13
14
15
|
def loading
@lock.exclusive(purpose: :load, compatible: [:load], after_compatible: [:load]) do
yield
end
end
|
Extracted source (around line #150):
148
149
150
151
152
153
|
if start_exclusive(purpose: purpose, compatible: compatible, no_wait: no_wait)
begin
yield
ensure
stop_exclusive(compatible: after_compatible)
end
|
Extracted source (around line #11):
9
10
11
12
13
14
|
def loading
@lock.exclusive(purpose: :load, compatible: [:load], after_compatible: [:load]) do
yield
end
end
|
Extracted source (around line #37):
35
36
37
38
39
40
|
# block at the same time.
def self.load_interlock
Dependencies.interlock.loading { yield }
end
# Execute the supplied block while holding an exclusive lock,
|
Extracted source (around line #358):
356
357
358
359
360
361
|
return if loaded.include?(expanded)
Dependencies.load_interlock do
# Maybe it got loaded while we were waiting for our lock:
return if loaded.include?(expanded)
|
Extracted source (around line #512):
510
511
512
513
514
515
|
raise "Circular dependency detected while autoloading constant #{qualified_name}"
else
require_or_load(expanded, qualified_name)
raise LoadError, "Unable to autoload constant #{qualified_name}, expected #{file_path} to define it" unless from_mod.const_defined?(const_name, false)
return from_mod.const_get(const_name)
end
|
Extracted source (around line #203):
201
202
203
204
205
206
|
def const_missing(const_name)
from_mod = anonymous? ? guess_for_anonymous(const_name) : self
Dependencies.load_missing_constant(from_mod, const_name)
end
# We assume that the name of the module reflects the nesting
|
Extracted source (around line #270):
268
269
270
271
272
273
|
constant.const_get(name)
else
candidate = constant.const_get(name)
next candidate if constant.const_defined?(name, false)
next candidate unless Object.const_defined?(name)
|
Extracted source (around line #270):
268
269
270
271
272
273
|
constant.const_get(name)
else
candidate = constant.const_get(name)
next candidate if constant.const_defined?(name, false)
next candidate unless Object.const_defined?(name)
|
Extracted source (around line #266):
264
265
266
267
268
269
|
names.shift if names.size > 1 && names.first.empty?
names.inject(Object) do |constant, name|
if constant == Object
constant.const_get(name)
else
|
Extracted source (around line #266):
264
265
266
267
268
269
|
names.shift if names.size > 1 && names.first.empty?
names.inject(Object) do |constant, name|
if constant == Object
constant.const_get(name)
else
|
Extracted source (around line #266):
264
265
266
267
268
269
|
names.shift if names.size > 1 && names.first.empty?
names.inject(Object) do |constant, name|
if constant == Object
constant.const_get(name)
else
|
Extracted source (around line #584):
582
583
584
585
586
587
|
def get(key)
key = key.name if key.respond_to?(:name)
@store[key] ||= Inflector.constantize(key)
end
alias :[] :get
|
Extracted source (around line #615):
613
614
615
616
617
618
|
# Raises an exception if referenced class does not exist.
def constantize(name)
Reference.get(name)
end
# Get the reference for class named +name+ if one exists.
|
Extracted source (around line #81):
79
80
81
82
83
84
|
params[:action] ||= 'index'
const_name = "#{controller_param.camelize}Controller"
ActiveSupport::Dependencies.constantize(const_name)
else
PASS_NOT_FOUND
end
|
Extracted source (around line #44):
42
43
44
45
46
47
|
def controller(req)
req.controller_class
rescue NameError => e
raise ActionController::RoutingError, e.message, e.backtrace
end
|
Extracted source (around line #30):
28
29
30
31
32
33
|
def serve(req)
params = req.path_parameters
controller = controller req
res = controller.make_response! req
dispatch(controller, params[:action], req, res)
rescue ActionController::RoutingError
|
Extracted source (around line #39):
37
38
39
40
41
42
|
req.path_parameters = set_params.merge parameters
status, headers, body = route.app.serve(req)
if 'pass' == headers['X-Cascade']
req.script_name = script_name
|
Extracted source (around line #26):
24
25
26
27
28
29
|
def serve(req)
find_routes(req).each do |match, parameters, route|
set_params = req.path_parameters
path_info = req.path_info
script_name = req.script_name
|
Extracted source (around line #26):
24
25
26
27
28
29
|
def serve(req)
find_routes(req).each do |match, parameters, route|
set_params = req.path_parameters
path_info = req.path_info
script_name = req.script_name
|
Extracted source (around line #727):
725
726
727
728
729
730
|
req = make_request(env)
req.path_info = Journey::Router::Utils.normalize_path(req.path_info)
@router.serve(req)
end
def recognize_path(path, environment = {})
|
Extracted source (around line #36):
34
35
36
37
38
39
|
result = catch(:warden) do
env['warden'].on_request
@app.call(env)
end
result ||= {}
|
Extracted source (around line #34):
32
33
34
35
36
37
|
env['warden'] = Proxy.new(env, self)
result = catch(:warden) do
env['warden'].on_request
@app.call(env)
end
|
Extracted source (around line #34):
32
33
34
35
36
37
|
env['warden'] = Proxy.new(env, self)
result = catch(:warden) do
env['warden'].on_request
@app.call(env)
end
|
Extracted source (around line #27):
25
26
27
28
29
30
|
def call(env)
status, headers, body = @app.call(env)
headers = Utils::HeaderHash[headers]
|
Extracted source (around line #27):
25
26
27
28
29
30
|
case env[REQUEST_METHOD]
when "GET", "HEAD"
status, headers, body = @app.call(env)
headers = Utils::HeaderHash[headers]
if status == 200 && fresh?(env, headers)
status = 304
|
Extracted source (around line #12):
10
11
12
13
14
15
|
def call(env)
status, headers, body = @app.call(env)
if env[REQUEST_METHOD] == HEAD
[
|
Extracted source (around line #266):
264
265
266
267
268
269
|
req = make_request env
prepare_session(req)
status, headers, body = app.call(req.env)
res = Rack::Response::Raw.new status, headers
commit_session(req, res)
[status, headers, body]
|
Extracted source (around line #260):
258
259
260
261
262
263
|
def call(env)
context(env)
end
def context(env, app = @app)
|
Extracted source (around line #613):
611
612
613
614
615
616
|
request = ActionDispatch::Request.new env
status, headers, body = @app.call(env)
if request.have_cookie_jar?
cookie_jar = request.cookie_jar
|
Extracted source (around line #553):
551
552
553
554
555
556
|
end
end
@app.call(env)
end
private
|
Extracted source (around line #38):
36
37
38
39
40
41
|
result = run_callbacks :call do
begin
@app.call(env)
rescue => error
end
end
|
Extracted source (around line #97):
95
96
97
98
99
100
|
def __run_callbacks__(callbacks, &block)
if callbacks.empty?
yield if block_given?
else
runner = callbacks.compile
e = Filters::Environment.new(self, false, nil, block)
|
Extracted source (around line #750):
748
749
750
751
752
753
|
module_eval <<-RUBY, __FILE__, __LINE__ + 1
def _run_#{name}_callbacks(&block)
__run_callbacks__(_#{name}_callbacks, &block)
end
RUBY
end
|
Extracted source (around line #90):
88
89
90
91
92
93
|
# end
def run_callbacks(kind, &block)
send "_run_#{kind}_callbacks", &block
end
private
|
Extracted source (around line #36):
34
35
36
37
38
39
|
def call(env)
error = nil
result = run_callbacks :call do
begin
@app.call(env)
rescue => error
|
Extracted source (around line #12):
10
11
12
13
14
15
|
state = @executor.run!
begin
response = @app.call(env)
returned = response << ::Rack::BodyProxy.new(response.pop) { state.complete! }
ensure
state.complete! unless returned
|
Extracted source (around line #79):
77
78
79
80
81
82
|
req = ActionDispatch::Request.new env
req.remote_ip = GetIp.new(req, check_ip, proxies)
@app.call(req.env)
end
# The GetIp class exists as a way to defer processing of the request data
|
Extracted source (around line #49):
47
48
49
50
51
52
|
def call(env)
request = ActionDispatch::Request.new env
_, headers, body = response = @app.call(env)
if headers['X-Cascade'] == 'pass'
body.close if body.respond_to?(:close)
|
Extracted source (around line #135):
133
134
135
136
137
138
|
def call_app(env)
@app.call(env)
rescue => e
throw :app_exception, e
end
|
Extracted source (around line #22):
20
21
22
23
24
25
|
app_exception = catch :app_exception do
request = create_regular_or_whiny_request(env)
return call_app(env) unless request.from_whitelisted_ip?
if id = id_for_repl_session_update(request)
return update_repl_session(id, request)
|
Extracted source (around line #20):
18
19
20
21
22
23
|
def call(env)
app_exception = catch :app_exception do
request = create_regular_or_whiny_request(env)
return call_app(env) unless request.from_whitelisted_ip?
|
Extracted source (around line #20):
18
19
20
21
22
23
|
def call(env)
app_exception = catch :app_exception do
request = create_regular_or_whiny_request(env)
return call_app(env) unless request.from_whitelisted_ip?
|
Extracted source (around line #31):
29
30
31
32
33
34
|
def call(env)
request = ActionDispatch::Request.new env
@app.call(env)
rescue Exception => exception
if request.show_exceptions?
render_exception(request, exception)
|
Extracted source (around line #36):
34
35
36
37
38
39
|
instrumenter.start 'request.action_dispatch', request: request
logger.info { started_request_message(request) }
resp = @app.call(env)
resp[2] = ::Rack::BodyProxy.new(resp[2]) { finish(request) }
resp
rescue Exception
|
Extracted source (around line #24):
22
23
24
25
26
27
|
if logger.respond_to?(:tagged)
logger.tagged(compute_tags(request)) { call_app(request, env) }
else
call_app(request, env)
end
|
Extracted source (around line #69):
67
68
69
70
71
72
|
def tagged(*tags)
formatter.tagged(*tags) { yield self }
end
def flush
|
Extracted source (around line #26):
24
25
26
27
28
29
|
def tagged(*tags)
new_tags = push_tags(*tags)
yield self
ensure
pop_tags(new_tags.size)
end
|
Extracted source (around line #69):
67
68
69
70
71
72
|
def tagged(*tags)
formatter.tagged(*tags) { yield self }
end
def flush
|
Extracted source (around line #24):
22
23
24
25
26
27
|
if logger.respond_to?(:tagged)
logger.tagged(compute_tags(request)) { call_app(request, env) }
else
call_app(request, env)
end
|
Extracted source (around line #19):
17
18
19
20
21
22
|
RequestStore.begin!
status, headers, body = @app.call(env)
body = Rack::BodyProxy.new(body) do
RequestStore.end!
|
Extracted source (around line #24):
22
23
24
25
26
27
|
req = ActionDispatch::Request.new env
req.request_id = make_request_id(req.x_request_id)
@app.call(env).tap { |_status, headers, _body| headers[X_REQUEST_ID] = req.request_id }
end
private
|
Extracted source (around line #24):
22
23
24
25
26
27
|
end
@app.call(env)
end
def method_override(env)
|
Extracted source (around line #22):
20
21
22
23
24
25
|
def call(env)
start_time = Utils.clock_time
status, headers, body = @app.call(env)
headers = Utils::HeaderHash[headers]
request_time = Utils.clock_time - start_time
|
Extracted source (around line #28):
26
27
28
29
30
31
|
def call(env)
LocalCacheRegistry.set_cache_for(local_cache_key, LocalStore.new)
response = @app.call(env)
response[2] = ::Rack::BodyProxy.new(response[2]) do
LocalCacheRegistry.set_cache_for(local_cache_key, nil)
end
|
Extracted source (around line #12):
10
11
12
13
14
15
|
state = @executor.run!
begin
response = @app.call(env)
returned = response << ::Rack::BodyProxy.new(response.pop) { state.complete! }
ensure
state.complete! unless returned
|
Extracted source (around line #136):
134
135
136
137
138
139
|
end
@app.call(req.env)
end
end
end
|
Extracted source (around line #110):
108
109
110
111
112
113
|
def call(env)
status, headers, body = @app.call(env)
if body.respond_to?(:to_path)
case type = variation(env)
when 'X-Accel-Redirect'
|
Extracted source (around line #100):
98
99
100
101
102
103
|
vary_resource = resource_for_path(path)
status, headers, body = @app.call env
if add_headers
headers = add_headers.merge(headers)
|
Extracted source (around line #522):
520
521
522
523
524
525
|
def call(env)
req = build_request env
app.call req.env
end
# Defines additional Rack env configuration that is added on each call.
|
Extracted source (around line #193):
191
192
193
194
195
196
|
def method_missing(name, *args, &block)
if instance.respond_to?(name)
instance.public_send(name, *args, &block)
else
super
end
|
Extracted source (around line #193):
191
192
193
194
195
196
|
def method_missing(name, *args, &block)
if instance.respond_to?(name)
instance.public_send(name, *args, &block)
else
super
end
|
Extracted source (around line #107):
105
106
107
108
109
110
|
begin
status, headers, body = @app.call(env)
rescue => e
if !should_swallow_app_error?(e, socket_wrapper)
# It's a good idea to catch application exceptions here because
|
Extracted source (around line #149):
147
148
149
150
151
152
|
begin
if headers[REQUEST_METHOD] == GET
process_request(headers, connection, socket_wrapper, @protocol == :http)
elsif headers[REQUEST_METHOD] == PING
process_ping(headers, connection)
false
|
Extracted source (around line #110):
108
109
110
111
112
113
|
finish_callback.call
while true
hijacked = accept_and_process_next_request(socket_wrapper, channel, buffer)
socket_wrapper = Utils::UnseekableSocket.new if hijacked
end
rescue Interrupted
|
Extracted source (around line #419):
417
418
419
420
421
422
|
handler = thread_handler.new(self, main_socket_options)
handler.install
handler.main_loop(set_initialization_state_to_true)
ensure
set_initialization_state.call(false)
unregister_current_thread
|
Extracted source (around line #113):
111
112
113
114
115
116
|
Thread.current.abort_on_exception = true
begin
yield(*args)
rescue SystemExit
raise
rescue Exception => e
|
Rails.root: /var/www/rails/geowise
Request
Parameters:
None
HTTP_ACCEPT: "*/*"
HTTP_VERSION: "HTTP/1.1"
ORIGINAL_SCRIPT_NAME: ""
REMOTE_ADDR: "3.239.214.173"
SERVER_NAME: "geo.divinopolis.mg.gov.br"
SERVER_PROTOCOL: "HTTP/1.1"
Response
Headers:
None