-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Make ARC default to true #267
Comments
It makes a lot of sense, but I need to mull it over a bit. Let’s schedule this for after the 0.6.0 release. |
Not sure if this is implemented already: if we make this change (or another breaking change to the Specs format) at a later time, can we use the min version from https://github.com/CocoaPods/Specs/blob/master/CocoaPods-version.yml to prompt the user to update his CocoaPods gem in case the Specs repo requires a more recent version than the one installed? |
Afaik @irrationalfab implemented all of that feature, so yeah :) |
Yes the feature is implemented as described. Regarding the issue I agree with the proposal, just my two cents. |
Ok, then let’s do it. @mk Will you work on that? And if so, do you think you can do it before the 1st of June (target RC1 release date), or should we schedule it for 0.6.1? |
Another reason for defaulting ARC to true is that xcodebuild fails (and hence |
Planned for after 0.14.0. This will also require an update of basically all specs. |
Currently (0.17) ARC is required and when all the specs of the master repo have a value, the flag can be changed. |
This depends on #960 as it would be the only safe way to set the flag to false on the specs which do not declare it. (My above comment is incorrect and this is not being checked by the linter) |
Maybe it would make sense to change this default for yaml specs. That way the existing DSL specs will continue to work. The DSL>yaml migrator should disable ARC if it wasn't explicitly enabled in the DSL. This should be a solid way to do this without any existing pods breaking. |
The plan is more or less the same: convert programmatically the whole repo to YAML and then explicitly set the value to no for the specs/subspecs which do not specify a value. |
Issue has been confirmed by @AhmadAlokush |
@Keithbsmiley haven't you done this/made progress on this? |
@segiddins before doing this trunk needs to be released and the whole repo must be conveyed to JSON. Marking the issue as blocked. |
The specs are ready for this yes. We can re run my scripts if any new specs have been added that some include this setting |
@Keithbsmiley / @alloy / @irrationalfab ping? |
I want this, dev pods defaulting to not-ARC is annoying. |
Same |
If anyone wants to do a validate on the specs repo just to make sure nothing snuck in without a definition that might be nice. But last I checked everything was good there. |
@Keithbsmiley care to share your scripts? |
I want this too, please write up a list of transition steps/TODOs once you know the status of the conversion script. |
Can I have a confirmation that the specs are ready? |
172 are still missing the setting according to this simple script: require 'json'
missing_requires_arc_count = 0
specs = Dir.glob('/Users/fabio/.cocoapods/repos/master/**/*.json')
specs.each do |spec|
json = JSON.parse(File.read(spec))
if json['requires_arc'].nil?
version, name = spec.split('/')[-2..-1]
puts "#{name} (#{version})"
missing_requires_arc_count += 1
end
end
puts "\n\nChecked #{specs.count} specs"
puts "#{missing_requires_arc_count} are missing the requires_arc setting" |
Updated script (thanks @kylef): require 'json'
missing_requires_arc_count = 0
specs = Dir.glob('/Users/fabio/.cocoapods/repos/master/**/*.json')
specs.each do |spec|
contents = File.read(spec)
unless contents.include?('requires_arc')
version, name = spec.split('/')[-2..-1]
puts "#{name} (#{version})"
missing_requires_arc_count += 1
# p spec
end
end
puts "\n\nChecked #{specs.count} specs"
puts "#{missing_requires_arc_count} are missing the requires_arc setting" // ...
Checked 17501 specs
130 are missing the requires_arc setting |
Yep. My script isn't going to work for this in it's current state since it was for ruby specs. |
Fixed and pushed CocoaPods/Specs@c50d2b1 |
How should I convert my private repo ? Is there a script to do it? |
chances are its quicker to just copy and paste |
too many specs in my repo😁 |
@Whirlwind See the comments above by @Keithbsmiley and @fabiopelosin. |
:( only |
Merge `1-9-stable` (1.9.0.beta.3) into `master`
I was wondering if we should make the
requires_arc
flag default totrue
. I know it would break backwards compatibility but looking ahead I think it could make sense because:false
and a library uses arc, you get leaks which I consider to be worse than the other way around: when it defaults totrue
and a library does not use it, you get build errorsWhat do you think?
The text was updated successfully, but these errors were encountered: