Open vvatikiotis opened 13 years ago
Could you check if that is still happening using rack-webconsole from master?
same problem. Same versions. Also using bundler 1.0.12, sinatra 1.2.6 and rack 1.3.2, rack-webconsole from master.
Gemfile: gem "redis" gem "SystemTimer", "1.2.3" # redis requires this gem "sinatra", "1.2.6" gem "activesupport", "3.0.5" # XML <-> JSON gem "i18n" gem "json" gem "builder" gem "nokogiri" # xpath gem "dm-core", "1.1.0" gem "dm-migrations", "1.1.0"
group :development, :test do gem "shotgun" gem "ruby-debug" gem 'rack-webconsole', :git => 'https://github.com/codegram/rack-webconsole.git' gem 'rack-test' gem "capybara" gem 'launchy' # capybara's save_and_open_page requires this gem 'factory_girl' gem 'rspec', '2.5' gem 'rspec-core', '2.5.2' gem "ZenTest", '4.6' gem 'autotest' gem "autotest-inotify" gem "mysql2" gem "dm-mysql-adapter", "1.1.0" end
config.ru require 'lib/myprox' if Sinatra::Base.development? require 'rack/webconsole' use Rack::Webconsole Rack::Webconsole.inject_jquery = true end
run MyProx
I had a quick look, no spec yet, I have to work on it (me newb)
In Repl#call : return [status, headers, response] unless check_legitimate(req)
The above always returns. Repl.token is always nil even if req.params['token'] is not. Where do you set Repl.token ?
sorry closed it by accident
when the console is active and each time input is passed in the form, Repl is re-initialised, thus token = nil
I've tracked it down to the ajax call which sends the token and the user query. unfortunately my javascript knowledge is nil...
So whenever there is the ajax POST at /webconsole, env['QUERY_STRING') is empty. the user query and the token aren't passed in the call.
I've used the query injection method and the standard way i.e. download and load jquery in my html. No joy.
This is similar to bug #22. When I invoke shotgun I get a 404. rackup works as expected.
Any updates / further insight on this?
@vvatikiotis any updates?
with gem version 0.1.2 on a linux chromium 12.0.742.112.
The console opens up ok (backtic). I can insert chars in the CLI, but the enter key is ignored and the console view is always blank.