Comments (6)
I think explicitly locking versions with a comment is superior to using Bundler in a non-default mode. The KISS principle. 99% of Ruby developers, including myself, have no idea what the side effects of that switch are.
from net-imap.
The issue here is that mail
2.8 now requires net-imap and almost every Ruby app that sends email via SMTP is now pulling in net-imap
even though most of them do not use or need IMAP. Anyone wanting a pure Ruby environment will need to lock to mail 2.7.1.
I really wish Rubygems had optional dependencies so I could disable this type of unnecessary dependency.
from net-imap.
@mperham instead of locking to mail 2.7.1, you could lock the date
gem to
Gem::Specification.find{_1.name == "date" && _1.default_gem?}.version
You could even add that to the Gemfile (although you would still need a different lockfile for each version of ruby). Or you could add bundle add date --version $(ruby -e 'Gem::Specification.find...')
to your deploy scripts?
Or you could lock net-imap
to 0.3.1
. If you don't even care about net-imap
, then that might be the quickest, simplest answer!
Obviously, manually managing gem versions like this is a pain.
from net-imap.
@mperham, I was about to start a discussion over at https://github.com/rubygems/rubygems, but then I wondered if the feature I wanted wasn't already supported. So I read through the bundler docs and found an existing option which might work for you, bundle install --prefer-local
:
--prefer-local
Force using locally installed gems, or gems already present in
Rubygems´ cache or in vendor/cache, when resolving, even if
newer versions are available remotely. Only attempt to connect
to rubygems.org for gems that are not present locally.
It's not exactly what I was looking for, but it might be a better solution than the others I suggested?
In addition to your "optional dependencies" suggestion, I have a few other ideas for potential bundler features that maybe would help. i.e. bundle cache --include-platform-extensions
or bundle install --prefer-system
or bundle add --source system
. But I'll save any deeper discussion of bundler feature requests for the rubygems repository.
from net-imap.
I think explicitly locking versions with a comment is superior to using Bundler in a non-default mode. The KISS principle. 99% of Ruby developers, including myself, have no idea what the side effects of that switch are.
I know what I want and expect the effects to be, but I've never actually used it so that also puts me in the 99% who have no idea!
from net-imap.
I wonder if ruby/date would consider a PR for publishing pre-compiled native gems?
I can release it. But pre-compiled gems need many of maintenance resources. I'm negative to do it.
Or we could drop the explicit dependency.
☹️
It's the short-term solution. Because date
gem(= library on ruby/ruby repository) has no maintainer now. So, I will extract date
from ruby/ruby repository. After that, net-imap
will break the missing dependency of date
library.
We don't have to extract embedded Time
library to default or bundled gem. Can we rewrite lib/net/imap/data_encoding.rb
with Time
class?
from net-imap.
Related Issues (20)
- Workaround for "already initialized constant errors", e.g. with net/protocol HOT 2
- Use modern TLS-related recommendations as per RFC7525, RFC7817, and RFC8314
- Parse RFC9051 `esearch-response` and `search-response-data`
- RFC4422 2.6.2: untagged response
- Add `:condstore` kwarg to `#select`, `#examine` (RFC7162)
- Add `:qresync` kwarg to `#select`, `#examine` (RFC7162)
- Add arbitrary kwargs to `#select`/`#examine`, using `select-params` syntax (RFC4466 tagged-ext)
- Add `:use` kwarg to `#create` (RFC6154, SPECIAL-USE)
- Add arbitrary kwargs to `#create`, using `create-params` syntax (RFC4466 tagged-ext)
- Add TaggedExtensionData (with `#to_hash`)
- Add ExtensionDataList (with `#to_ary`) HOT 1
- Add UnparsedData (with `#to_str`) HOT 1
- Add arbitrary kwargs to `#rename`, using `rename-params` syntax (RFC4466 tagged-ext)
- Add `:vanished` kwarg to `#fetch`/`#uid_fetch` (RFC7162, QRESYNC)
- Add `changedsince` kwarg to `#fetch`/`#uid_fetch` (RFC7162, CONDSTORE)
- Add arbitrary kwargs to `#fetch`/`#uid_fetch`, using RFC4466 tagged-ext syntax
- Honor `STARTTLS` capability
- test suite cannot be run offline HOT 2
- XAOUTH2 mechanism throwing error: unknown auth type - "XOAUTH2" HOT 2
- 0.3.5 lib/net/imap/flags.rb file permissions regression HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from net-imap.