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

CocoaPods 1.14.0 not compatible with activesupport 7.1 #12116

Closed
1 task done
ydesgagn opened this issue Oct 26, 2023 · 4 comments
Closed
1 task done

CocoaPods 1.14.0 not compatible with activesupport 7.1 #12116

ydesgagn opened this issue Oct 26, 2023 · 4 comments

Comments

@ydesgagn
Copy link

ydesgagn commented Oct 26, 2023

Report

What did you do?

Was testing the fix for activesupport 7.1 as per release notes of v1.14.0

Gemfile.lock

GEM
  remote: https://rubygems.org/
  specs:
    CFPropertyList (3.0.6)
      rexml
    activesupport (7.1.1)
      base64
      bigdecimal
      concurrent-ruby (~> 1.0, >= 1.0.2)
      connection_pool (>= 2.2.5)
      drb
      i18n (>= 1.6, < 2)
      minitest (>= 5.1)
      mutex_m
      tzinfo (~> 2.0)
    addressable (2.8.5)
      public_suffix (>= 2.0.2, < 6.0)
    algoliasearch (1.27.5)
      httpclient (~> 2.8, >= 2.8.3)
      json (>= 1.5.1)
    ast (2.4.2)
    atomos (0.1.3)
    base64 (0.1.1)
    bigdecimal (3.1.4)
    claide (1.1.0)
    cocoapods (1.14.0)
      addressable (~> 2.8)
      claide (>= 1.0.2, < 2.0)
      cocoapods-core (= 1.14.0)
      cocoapods-deintegrate (>= 1.0.3, < 2.0)
      cocoapods-downloader (>= 2.0)
      cocoapods-plugins (>= 1.0.0, < 2.0)
      cocoapods-search (>= 1.0.0, < 2.0)
      cocoapods-trunk (>= 1.6.0, < 2.0)
      cocoapods-try (>= 1.1.0, < 2.0)
      colored2 (~> 3.1)
      escape (~> 0.0.4)
      fourflusher (>= 2.3.0, < 3.0)
      gh_inspector (~> 1.0)
      molinillo (~> 0.8.0)
      nap (~> 1.0)
      ruby-macho (>= 2.3.0, < 3.0)
      xcodeproj (>= 1.23.0, < 2.0)
    cocoapods-core (1.14.0)
      activesupport (>= 5.0, < 8)
      addressable (~> 2.8)
      algoliasearch (~> 1.0)
      concurrent-ruby (~> 1.1)
      fuzzy_match (~> 2.0.4)
      nap (~> 1.0)
      netrc (~> 0.11)
      public_suffix (~> 4.0)
      typhoeus (~> 1.0)
    cocoapods-deintegrate (1.0.5)
    cocoapods-downloader (2.0)
    cocoapods-plugins (1.0.0)
      nap
    cocoapods-search (1.0.1)
    cocoapods-trunk (1.6.0)
      nap (>= 0.8, < 2.0)
      netrc (~> 0.11)
    cocoapods-try (1.2.0)
    colored2 (3.1.2)
    concurrent-ruby (1.2.2)
    connection_pool (2.4.1)
    drb (2.1.1)
      ruby2_keywords
    escape (0.0.4)
    ethon (0.16.0)
      ffi (>= 1.15.0)
    ffi (1.16.3)
    fourflusher (2.3.1)
    fuzzy_match (2.0.4)
    gh_inspector (1.1.3)
    httparty (0.21.0)
      mini_mime (>= 1.0.0)
      multi_xml (>= 0.5.2)
    httpclient (2.8.3)
    i18n (1.14.1)
      concurrent-ruby (~> 1.0)
    inquirer (0.2.1)
      term-ansicolor (>= 1.2.2)
    json (2.6.3)
    language_server-protocol (3.17.0.3)
    mini_mime (1.1.5)
    minitest (5.20.0)
    molinillo (0.8.0)
    multi_xml (0.6.0)
    mutex_m (0.1.2)
    nanaimo (0.3.0)
    nap (1.1.0)
    netrc (0.11.0)
    optparse (0.3.1)
    parallel (1.23.0)
    parser (3.2.2.4)
      ast (~> 2.4.1)
      racc
    public_suffix (4.0.7)
    racc (1.7.1)
    rainbow (3.1.1)
    regexp_parser (2.8.2)
    rexml (3.2.6)
    rubocop (1.57.2)
      json (~> 2.3)
      language_server-protocol (>= 3.17.0)
      parallel (~> 1.10)
      parser (>= 3.2.2.4)
      rainbow (>= 2.2.2, < 4.0)
      regexp_parser (>= 1.8, < 3.0)
      rexml (>= 3.2.5, < 4.0)
      rubocop-ast (>= 1.28.1, < 2.0)
      ruby-progressbar (~> 1.7)
      unicode-display_width (>= 2.4.0, < 3.0)
    rubocop-ast (1.30.0)
      parser (>= 3.2.1.0)
    ruby-macho (2.5.1)
    ruby-progressbar (1.13.0)
    ruby2_keywords (0.0.5)
    semantic (1.6.1)
    sync (0.5.0)
    term-ansicolor (1.7.1)
      tins (~> 1.0)
    tins (1.32.1)
      sync
    typhoeus (1.4.0)
      ethon (>= 0.9.0)
    tzinfo (2.0.6)
      concurrent-ruby (~> 1.0)
    unicode-display_width (2.5.0)
    xcodeproj (1.23.0)
      CFPropertyList (>= 2.3.3, < 4.0)
      atomos (~> 0.1.3)
      claide (>= 1.0.2, < 2.0)
      colored2 (~> 3.1)
      nanaimo (~> 0.3.0)
      rexml (~> 3.2.4)
    yarn_lock_parser (0.1.0)

PLATFORMS
  aarch64-linux
  arm64-darwin-22
  arm64-darwin-23
  x86_64-darwin-22
  x86_64-linux

DEPENDENCIES
  activesupport (>= 7.1.0)
  bundler (>= 2.3.0)
  cocoapods (>= 1.14.0)
  httparty (>= 0.20.0)
  inquirer (>= 0.2.0)
  json (>= 2.6.0)
  optparse (>= 0.2.0)
  rubocop (>= 1.28.2)
  semantic (>= 1.6.1)
  yarn_lock_parser (>= 0.1.0)

BUNDLED WITH
   2.4.21

On a GitHub runner macos instance log of the bundle install

...
Fetching activesupport 7.1.1
Installing activesupport 7.1.1
Fetching cocoapods-core 1.14.0
Installing cocoapods-core 1.14.0
Fetching cocoapods 1.14.0
Installing cocoapods 1.14.0
...

What did you expect to happen?

Simple Ruby file calling this should work fine.

require 'cocoapods-core'

What happened instead?

require 'cocoapods-core'

Gave

/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/gems/3.2.0/gems/activesupport-7.1.1/lib/active_support/core_ext/array/conversions.rb:108:in `<class:Array>': undefined method `deprecator' for ActiveSupport:Module (NoMethodError)

  deprecate to_default_s: :to_s, deprecator: ActiveSupport.deprecator
                                                          ^^^^^^^^^^^
Did you mean?  deprecate_constant
	from /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/gems/3.2.0/gems/activesupport-7.1.1/lib/active_support/core_ext/array/conversions.rb:8:in `<top (required)>'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:96:in `require'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:96:in `require'
	from /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/gems/3.2.0/gems/cocoapods-core-1.14.0/lib/cocoapods-core/specification/set.rb:1:in `<top (required)>'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:96:in `require'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:96:in `require'
	from /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/gems/3.2.0/gems/cocoapods-core-1.14.0/lib/cocoapods-core/specification.rb:7:in `<top (required)>'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:96:in `require'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:96:in `require'
	from /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/gems/3.2.0/gems/cocoapods-core-1.14.0/lib/cocoapods-core.rb:[39](https://github.com/Cloud-Officer/soup/actions/runs/6655891726/job/18087209970?pr=11#step:4:40):in `<module:Pod>'
	from /Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/gems/3.2.0/gems/cocoapods-core-1.14.0/lib/cocoapods-core.rb:3:in `<top (required)>'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:159:in `require'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:159:in `rescue in require'
	from <internal:/Users/runner/hostedtoolcache/Ruby/3.2.2/x64/lib/ruby/3.2.0/rubygems/core_ext/kernel_require.rb>:39:in `require'

CocoaPods Environment

Not using pod env.

Project that demonstrates the issue

Error here:

https://github.com/Cloud-Officer/soup/tree/CocoaPods

Working fine when gems pinned (master branch).

gem 'activesupport', '7.0.8'
gem 'cocoapods', '1.12'

New release v1.14.0 did not help for me using Ruby code.

@amorde
Copy link
Member

amorde commented Oct 26, 2023

Ugh - thanks for reporting this. Unfortunate that this was missed.

Since this is from directly doing require 'cocoapods-core', this is something that can be worked around by adding your own require statements for active_support or 'cocoapods' correct?

@ydesgagn
Copy link
Author

Correct. If I change the Ruby code to the following it does work. But that should not be necessary.

require 'active_support'
require 'active_support/core_ext'
require 'cocoapods-core'

@amorde
Copy link
Member

amorde commented Oct 26, 2023

Fixed and shipped 1.14.1

@amorde amorde closed this as completed Oct 26, 2023
@ydesgagn
Copy link
Author

Thanks a lot.

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

No branches or pull requests

2 participants