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

Deprecation fix: File.exists? => File.exist #180

Merged
merged 3 commits into from
Mar 27, 2015
Merged

Deprecation fix: File.exists? => File.exist #180

merged 3 commits into from
Mar 27, 2015

Conversation

ronen
Copy link
Contributor

@ronen ronen commented Dec 6, 2014

Address deprecation warning:

 ...ruby/2.1.3/gems/addressable-2.3.6/lib/addressable/uri.rb:265: warning: File.exists? is a deprecated name, use File.exist? instead

Address deprecation warning:

     ...ruby/2.1.3/gems/addressable-2.3.6/lib/addressable/uri.rb:265: warning: File.exists? is a deprecated name, use File.exist? instead
@coveralls
Copy link

Coverage Status

Coverage remained the same when pulling aed2cfa on ronen:patch-1 into 58c12e1 on sporkmonger:master.

@ronen
Copy link
Contributor Author

ronen commented Dec 7, 2014

I should have mentioned: The deprecation warning is issued when running ruby with verbose warnings enabled, via ruby -w, or $VERBOSE = true or RSpec's config.warnings = true

@iainbeeston
Copy link
Contributor

Or try running the tests with "rspec --warnings"

Any chance of getting this merged?

@iainbeeston
Copy link
Contributor

@sporkmonger Is there anything we can do to get this merged? It makes it very difficult to use addressable with warnings enabled

@iainbeeston
Copy link
Contributor

@ronen Do you think you could add RSpec.configure { |c| c.warnings = true } to spec_helper.rb (in this pull request) so @sporkmonger can see what we mean?

@iainbeeston
Copy link
Contributor

(And maybe prevent future problems too)

@aplatypus
Copy link

Hi ...

I have been looking for the 'reason' for this message:

  • deprecated. use instead jars/installer

I've been searching on here and the web I haven't found anything except this issue. Is this connected some way? What does the message mean?

It came in the context of installing a gem called middleman-blog.

**jruby -S gem install middleman-blog**
Fetching: addressable-2.3.7.gem (100%)
deprecated. use instead jars/installer
Successfully installed addressable-2.3.7
Fetching: middleman-blog-3.5.3.gem (100%)
Successfully installed middleman-blog-3.5.3
2 gems installed

I didn't have any verbose or warning switches set though. I am using the JRuby 9.0 version

JRuby 9.0.0.0.pre1 (2.2.0p0) 2015-01-20 d537cab 
Java HotSpot(TM) 64-Bit Server VM 25.25-b02 on 1.8.0_25-b18 +jit [Windows 7-amd64]

Many thanks,

Will.

@iainbeeston
Copy link
Contributor

@aplatypus I think that's an unrelated deprecation message.

@coveralls
Copy link

Coverage Status

Coverage increased (+0.0%) to 98.39% when pulling fa99f6a on ronen:patch-1 into 58c12e1 on sporkmonger:master.

@ronen
Copy link
Contributor Author

ronen commented Mar 19, 2015

@iainbeeston wrote:

@ronen Do you think you could add RSpec.configure { |c| c.warnings = true } to spec_helper.rb (in this pull request) so @sporkmonger can see what we mean?

Added it. That also exposed some variable-set-but-not-used warnings in template_spec.rb, which I fixed and likewise added to to the PR.

BTW with warnings enabled, MRI 2.2.0p0 gives a bunch of warnings possible reference to past scope in the specs -- it seems that's a bug which will be fixed in future releases, see https://bugs.ruby-lang.org/issues/10661 and https://bugs.ruby-lang.org/projects/ruby-trunk/repository/revisions/49082

sporkmonger added a commit that referenced this pull request Mar 27, 2015
Deprecation fix: File.exists? => File.exist
@sporkmonger sporkmonger merged commit 622d7fe into sporkmonger:master Mar 27, 2015
@sporkmonger
Copy link
Owner

Hey all, sorry it took me so long to get around to merging this.

@iainbeeston
Copy link
Contributor

🎉 😄

@ronen
Copy link
Contributor Author

ronen commented Mar 27, 2015

@sporkmonger cool, thanks.

FYI also MRI 2.2.1 indeed removes the possible reference to past scope warnings.

@ronen ronen deleted the patch-1 branch March 27, 2015 12:27
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.

5 participants