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

Rename usage of Dir/File.exists to exist #788

Merged
merged 1 commit into from
Apr 12, 2024

Conversation

ecnelises
Copy link
Contributor

The singular methods were deprecated long ago and finally removed in Ruby 3.2.0.

See ruby/ruby@bf97415

The singular methods were deprecated long ago and finally removed in Ruby 3.2.0.
@tsrivishnu
Copy link

Looking forward to having this merged. We are seeing these deprecations after upgrading to Ruby 3.1.3.

@jweir
Copy link

jweir commented Jan 4, 2023

Ruby 3.2 removes Dir.exists? and File.exists? but that will not yet be discovered via tests since FakeFS is used and it creates its own aliases.I have a PR open to update that FakeFS: fakefs/fakefs#482

Also, updating the workflow to test 3.2 would be kind.

@jcoyne
Copy link

jcoyne commented Apr 21, 2023

Thanks for your efforts @ecnelises . We need this too.

@ssuttner
Copy link

Thanks @ecnelises for this work!

@ddollar hey 👋
I see that this is starting to become a blocker for newer versions of Ruby.
If I may ask, would it be possible to get some approvers' eyes on it?

Thanks in advanced!

@johnleeming
Copy link

just run up against this issue. manual edit of base.rb fixed it locally but next time I update...

@bdescamps
Copy link

Any update concerning potential merge ?

@graaff
Copy link

graaff commented Feb 6, 2024

There is another File.exists? in spec/foreman_spec.rb

@ecnelises
Copy link
Contributor Author

There is another File.exists? in spec/foreman_spec.rb

Already fixed by c944101

@Geesu
Copy link

Geesu commented Apr 11, 2024

There is another File.exists? in spec/foreman_spec.rb

Already fixed by c944101

This just fixes the spec, it is still broken in ruby 3.2

@ddollar ddollar merged commit 0fe6bc9 into ddollar:master Apr 12, 2024
@ddollar
Copy link
Owner

ddollar commented Apr 12, 2024

Thank you!

@jcoyne
Copy link

jcoyne commented Apr 12, 2024

Yay! Thank you so much @ddollar!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants