Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Why? Does package management use a source of truth other than the config and the lock?
-
@homo-lorens seems like a part of the config is also stored in the lock file. That is, apart from the versions of the actual packages. So if you want to force the platform, you'll have to configure the lock aswell, even though it should definitely NOT hold that kind of stuff.
In general you'd should not even force the platform at all, but some packages are broken in a away, that makes them simply unusable, and you have to fall back to the 'any' arch equivalent, which in this case is platform=ruby.
And it makes it even better, that it then simply ignores the platform set in your ACTUAL config, which is the gemfile
TL:DR: part of the config is stored in the lock file for no particular reason. -
@homo-lorens i have
bundle lock --add-platform=ruby
which would add a platform to the lock, but not to the gemfile. Again, kinda not the right place, to config stuff like that.
And then it would control the platform over ALL gems, and not only the ones, where i want to use a specific platform for.
Related Rants
okay let's put a platform tag at the end of a gem in the gemfile, because it only works when you don't use the mingw platform on windows:
gem 'eventmachine', platform: :ruby
so far so good. Now lets remove the gemfile.lock and let bundle rebuild the dependency tree again (to make sure nothing gets left there):
bundle install
Resolving Dependencies.....
...
Fetching eventmachine 1.2.7 (x64-mingw32)
...
Why bundle, why?? :(
Now to fix that, i have to:
gem uninstall eventmachine
and:
gem install eventmachine --platform=ruby
every fucking time.
rant
ruby
ruby on rails
bundle