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

deprecated methods no longer existing on new ruby versions #6246

Closed
2 of 3 tasks
dann1 opened this issue Jun 21, 2023 · 0 comments · Fixed by OpenNebula/docs#2622
Closed
2 of 3 tasks

deprecated methods no longer existing on new ruby versions #6246

dann1 opened this issue Jun 21, 2023 · 0 comments · Fixed by OpenNebula/docs#2622

Comments

@dann1
Copy link
Contributor

dann1 commented Jun 21, 2023

Description
Some deprecated methods like File.exists? are still being used in ruby libraries. This method no longer exists on newer ruby versions and therefore throws errors, which will result in eventual incompatibility.

To Reproduce

  • Install the opennebula-cli gem on a client with a recent ruby version
ruby 3.2.2 (2023-03-30 revision e51014f9c0) [x86_64-darwin22]
  • issue the onevm list command
 ~  onevm list                                                                                                                                           Wed Jun 21 11:23:45 2023
undefined method `exists?' for File:Class

Expected behavior
The commands should work with recent ruby versions.

Additional context

  • This can easily be solved with a massive linting as rubocop will point out the deprecations
  • The rubocop exclusions should be removed to prevent these problems. Every file should be linted.
  • The CLI client is MacOS with ruby installed from Homebrew

Progress Status

  • Code committed
  • Testing - QA
  • Documentation (Release notes - resolved issues, compatibility, known issues)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant