IIC2143-2020-1 / proyecto

Repositorio para el proyecto semestral de IIC2143 Ingeniería de Software 2020-1
22 stars 8 forks source link

Spring error #118

Closed sluchsinger closed 4 years ago

sluchsinger commented 4 years ago

Hola estoy haciendo rails server y me muestra el siguiente error:

C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:46:in `find_project_root': Spring was unable to locate the root of your project. There was no Gemfile present in the current directory (C:/Users/Sebasti▒n/grupo29-proyecto/app1) or any of the parent directories. (Spring::UnknownProject)
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:37:in `project_root_path'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:28:in `application_root_path'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/watcher.rb:24:in `watcher'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/watcher.rb:28:in `watch'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/webpacker-4.2.2/lib/webpacker/railtie.rb:88:in `block in <class:Engine>'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:32:in `instance_exec'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:32:in `run'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:61:in `block in run_initializers'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:228:in `block in tsort_each'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:431:in `each_strongly_connected_component_from'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:349:in `block in each_strongly_connected_component'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:347:in `each'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:347:in `call'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:347:in `each_strongly_connected_component'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:226:in `tsort_each'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:205:in `tsort_each'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:60:in `run_initializers'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/application.rb:361:in `initialize!'
        from C:/Users/Sebastián/grupo29-proyecto/app1/config/environment.rb:5:in `<top (required)>'
        from config.ru:5:in `require_relative'
        from config.ru:5:in `block in <main>'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:116:in `eval'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:116:in `new_from_string'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:105:in `load_file'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:66:in `parse_file'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/server.rb:349:in `build_app_and_options_from_config'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/server.rb:249:in `app'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:27:in `app'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/server.rb:422:in `wrapped_app'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:89:in `log_to_stdout'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:51:in `start'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:147:in `block in perform'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:142:in `tap'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:142:in `perform'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/command.rb:27:in `run'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in `invoke_command'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor.rb:392:in `dispatch'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/command/base.rb:69:in `perform'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/command.rb:46:in `invoke'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands.rb:18:in `<top (required)>'
        from bin/rails:11:in `require'
        from bin/rails:11:in `<main>'
=> Booting Puma
=> Rails 5.2.4.2 application starting in development
=> Run `rails server -h` for more startup options
Exiting

En internet no hay mucho sobre este tipo de error

daleal commented 4 years ago

Dónde estás ejecutando el comando?

sluchsinger commented 4 years ago

en la app

daleal commented 4 years ago

Ejecuta ls y mandame el resultado del comando

sluchsinger commented 4 years ago
app/             bin/     config.ru  Gemfile       lib/  node_modules/  postcss.config.js  Rakefile   storage/  tmp/     yarn.lock
babel.config.js  config/  db/        Gemfile.lock  log/  package.json   public/            README.md  test/     vendor/
valerojasm commented 4 years ago

Hola! Puedes ver si hay algo en tmp/pids?

sluchsinger commented 4 years ago

no hay nada

sluchsinger commented 4 years ago

Que es lo que hace spring y como soluciono este error?

daleal commented 4 years ago

Es un application preloader. Como te podrás imaginar, el error que tienes es bastante extraño. Si quieres leer un poco más sobre Spring puedes revisar su README oficial. En cuanto al error, qué sucede si ejecutas bundle install y luego bundle exec rails server?

sluchsinger commented 4 years ago

Sigue pasando el mismo error, cuando ejecuto bundle install aparece entre las líneas using spring 2.1.0, no se si eso tiene algo que ver

daleal commented 4 years ago

Podrías enviarme el output de ambos comandos?

sluchsinger commented 4 years ago

bundle install:

Warning: the running version of Bundler (1.17.2) is older than the version that created the lockfile (1.17.3). We suggest you upgrade to the latest version of Bundler by running `gem install bundler`.
Using rake 13.0.1
Using concurrent-ruby 1.1.6
Using i18n 1.8.2
Using minitest 5.14.0
Using thread_safe 0.3.6
Using tzinfo 1.2.7
Using activesupport 5.2.4.2
Using builder 3.2.4
Using erubi 1.9.0
Using mini_portile2 2.4.0
Using nokogiri 1.10.9 (x64-mingw32)
Using rails-dom-testing 2.0.3
Using crass 1.0.6
Using loofah 2.5.0
Using rails-html-sanitizer 1.3.0
Using actionview 5.2.4.2
Using rack 2.2.2
Using rack-test 1.1.0
Using actionpack 5.2.4.2
Using nio4r 2.5.2
Using websocket-extensions 0.1.4
Using websocket-driver 0.7.1
Using actioncable 5.2.4.2
Using globalid 0.4.2
Using activejob 5.2.4.2
Using mini_mime 1.0.2
Using mail 2.7.1
Using actionmailer 5.2.4.2
Using activemodel 5.2.4.2
Using arel 9.0.0
Using activerecord 5.2.4.2
Using mimemagic 0.3.4
Using marcel 0.3.3
Using activestorage 5.2.4.2
Using public_suffix 4.0.4
Using addressable 2.7.0
Using io-like 0.3.1
Using archive-zip 0.12.0
Using ast 2.4.0
Using bcrypt 3.1.13
Using bindex 0.8.1
Using msgpack 1.3.3 (x64-mingw32)
Using bootsnap 1.4.6
Using bundler 1.17.2
Using byebug 11.1.1
Using regexp_parser 1.7.0
Using xpath 3.2.0
Using capybara 3.32.1
Using childprocess 3.0.0
Using chromedriver-helper 2.1.1
Using coffee-script-source 1.12.2
Using execjs 2.7.0
Using coffee-script 2.4.1
Using method_source 1.0.0
Using thor 1.0.1
Using railties 5.2.4.2
Using coffee-rails 4.2.2
Using cowsay 0.3.0
Using orm_adapter 0.5.0
Using responders 3.0.0
Using warden 1.2.8
Using devise 4.7.1
Using ffi 1.12.2 (x64-mingw32)
Using jaro_winkler 1.5.4
Using jbuilder 2.10.0
Using rb-fsevent 0.10.3
Using rb-inotify 0.10.1
Using ruby_dep 1.5.0
Using listen 3.1.5
Using parallel 1.19.1
Using parser 2.7.1.0
Using pg 1.2.3 (x64-mingw32)
Using puma 3.12.4
Using rack-proxy 0.6.5
Using sprockets 3.7.2
Using sprockets-rails 3.2.1
Using rails 5.2.4.2
Using rainbow 3.0.0
Using rexml 3.2.4
Using ruby-progressbar 1.10.1
Using unicode-display_width 1.7.0
Using rubocop 0.81.0
Using rubyzip 2.3.0
Using sass-listen 4.0.0
Using sass 3.7.4
Using tilt 2.0.10
Using sass-rails 5.1.0
Using selenium-webdriver 3.142.7
Using spring 2.1.0
Using spring-watcher-listen 2.0.1
Using turbolinks-source 5.2.0
Using turbolinks 5.2.1
Using tzinfo-data 1.2019.3
Using uglifier 4.2.0
Using web-console 3.7.0
Using webpacker 4.2.2
Bundle complete! 22 Gemfile dependencies, 96 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.

bundle exec rails server:

C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:46:in `find_project_root': Spring was unable to locate the root of your project. There was no Gemfile present in the current directory (C:/Users/Sebasti▒n/grupo29-proyecto/app1) or any of the parent directories. (Spring::UnknownProject)
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:48:in `find_project_root'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:37:in `project_root_path'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/configuration.rb:28:in `application_root_path'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/watcher.rb:24:in `watcher'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/spring-2.1.0/lib/spring/watcher.rb:28:in `watch'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/webpacker-4.2.2/lib/webpacker/railtie.rb:88:in `block in <class:Engine>'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:32:in `instance_exec'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:32:in `run'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:61:in `block in run_initializers'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:228:in `block in tsort_each'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:431:in `each_strongly_connected_component_from'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:349:in `block in each_strongly_connected_component'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:347:in `each'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:347:in `call'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:347:in `each_strongly_connected_component'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:226:in `tsort_each'
        from C:/Ruby26-x64/lib/ruby/2.6.0/tsort.rb:205:in `tsort_each'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/initializable.rb:60:in `run_initializers'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/application.rb:361:in `initialize!'
        from C:/Users/Sebastián/grupo29-proyecto/app1/config/environment.rb:5:in `<top (required)>'
        from config.ru:5:in `require_relative'
        from config.ru:5:in `block in <main>'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:116:in `eval'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:116:in `new_from_string'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:105:in `load_file'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/builder.rb:66:in `parse_file'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/server.rb:349:in `build_app_and_options_from_config'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/server.rb:249:in `app'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:27:in `app'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/rack-2.2.2/lib/rack/server.rb:422:in `wrapped_app'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:89:in `log_to_stdout'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:51:in `start'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:147:in `block in perform'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:142:in `tap'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands/server/server_command.rb:142:in `perform'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/command.rb:27:in `run'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor/invocation.rb:127:in `invoke_command'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/thor-1.0.1/lib/thor.rb:392:in `dispatch'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/command/base.rb:69:in `perform'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/command.rb:46:in `invoke'
        from C:/Ruby26-x64/lib/ruby/gems/2.6.0/gems/railties-5.2.4.2/lib/rails/commands.rb:18:in `<top (required)>'
        from bin/rails:11:in `require'
        from bin/rails:11:in `<main>'
=> Booting Puma
=> Rails 5.2.4.2 application starting in development
=> Run `rails server -h` for more startup options
Exiting
daleal commented 4 years ago

A alguno de tus compañeros le pasa esto?

sluchsinger commented 4 years ago

no, solo a mi

daleal commented 4 years ago

Hemos buscado bastante y no hemos podido encontrar la razón de tu problema. Lo más probable es que se deba a una interacción inesperada entre rails y tu sistema operativo. Mi recomendación es que hagas una partición con Linux y sigas trabajando desde ahí.

sluchsinger commented 4 years ago

Que es una particion con Linux y como lo hago, definitivamente no se puedo seguir trabajando con windows?

valerojasm commented 4 years ago

Probaste clonar el repo de nuevo? Por donde lo estás corriendo, git bash o powershell? Intenta intercambiarlo. En verdad hemos estado buscando cómo ayudarte pero las pocas soluciones en internet son para macOS. Lo que te dice @daleal es una buena opción, Windows en general no es dev friendly y te va a servir para el resto de los cursos de computación. Una partición divide el espacio de tu disco para que puedas correr ambos sistemas operativos (alguna distro de Linux y Windows). Hay muchos tutoriales en internet, acá hay uno por ejemplo. Cuéntanos cómo te va

sluchsinger commented 4 years ago

Ya voy a tratar de clonar de nuevo el repositorio pero en otra carpeta, el problema es que no tengo permisos en otra carpeta como lo hago para darselo? no encuentro nada que me ayude, y si no voy a hacer lo de linux no más

valerojasm commented 4 years ago

A qué te refieres con tener permiso en otra carpeta? Puedes clonar el repositorio donde quieras

sluchsinger commented 4 years ago

Tengo entendido que uno cuando descarga git elige un directorio donde inicia sesion y ahi es donde puedes clonar repositorios, me salgo de esa carpeta y me voy a otra y ejecuto git clone y me aparece fatal: could not create work tree dir 'grupo29-proyecto': Permission denied

daleal commented 4 years ago

Yo creo que lo más recomendable es que instales Ubuntu usando la guía que envió @valerojasm. Tiene mucho más comunidad que windows así que los problemas, si existen, probablemente los puedas solucionar mucho más rápido.

sluchsinger commented 4 years ago

Lo veo muy complicado el tema de la particion, no me está resultando nada de ahí, este problema del pc solo me afectará a rails?, porque estoy pensando en hacer todo este ramo en otro computador

oscars810 commented 4 years ago

@daleal Tal vez podría usar el Subsystem Linux for Window?... Ya que así teoricamente estaría estaría corriendo la app bajo linux

daleal commented 4 years ago

Si podría intentar usar linux subsystem, pero incluso usando esa solución a veces hay problemas únicos de windows y me da la sensación de que el problema que está teniendo es a nivel de SO.

sluchsinger commented 4 years ago

Tuve que empezar con un usuario nuevo desde cero y ahora ya no esta ese error. Muchas gracias por la ayuda

daleal commented 4 years ago

Solo por curiosidad, ese usuario no tiene tilde en el nombre de usuario verdad?

sluchsinger commented 4 years ago

No, lo hice sin tilde para ahorrarme algún proble de ese tipo