-
-
Notifications
You must be signed in to change notification settings - Fork 112
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
Spike: find a suitable Inflector #876
Comments
How is removing ActiveSupport moving this project forward? It's the 5th most popular gem and is extremely stable. I could understand the idea if it was to eliminate a dependency, or bring better functionality. This is just replacing one thing with another for no reason. This is quite a disappointment. |
@jclusso Dang, I was hoping this conversation had been resolved some time ago? I'm not sure why we're covering the same ground again. ICYMI and need more context: |
Resolved implies I think this is a good decision... If someone is looking for this functionality in the future, it should be known that it did exist, but was abandoned on principle, not due to the functionality. Also, I think it would be interesting to poll the Bridgetown community and see if they support removing Active Support. Your post you linked about 2.0 speaks directly to the lack of that being done when removing Typescript. |
Jarrett makes a very good point. If you (@jaredcwhite) think DHH's removal of Typescript was a violation of the Code of Conduct, why are you doing the same thing? |
If removing ActiveSupport proves tricky or time consuming, I'd be in favour of vendoring it rather than dropping it completely. That said, @jclusso @brandondrew do you have any technical concerns regarding this change? From my POV, ActiveSupport is quite a large, monolithic gem with a large surface area. That's fantastic for Rails. For Bridgetown I wouldn't mind slimming down the dependencies a bit and pull in just the functionality we need. |
@ayushn21 as previously stated I'm all for removing an unecessary dependency or one that provides little value. This however is for the agenda to "de-37signals-ify" Bridgetown. It's based on opinions of DHH's actions on Turbo, a completely unrelated project. The reason to remove Active Support is based on not wanting to tangentially include code from a project that some believe violates the CoC. I feel like vendoring it is the equivelent of saying you don't support theives, but buying their discount stolen products. I don't see how we can vendor it in good faith. Also, this feels like a slippery slope. Have we fully vetted the entire Gemfile.lock that pulls in like 100 other dependencies to make sure they're up to par with the CoC? How far does it go? |
@jclusso It's true it's pretty fiddly philosophical territory here. It's tenuous ground and we're unlikely to agree with each other completely. However I feel we as project maintainers still have the right to set the project's direction and philosophy. I don't want to speak for Jared here, but I think he'd agree with me when I say we remain completely open to discussing technical grounds on which we shouldn't make a change. If there's little to no effect on Bridgetown users and the effort to make the change is put in by the maintainers, I'm struggling to see the issue here. I'll say again that we're completely open to feedback regarding any technical problems this may cause. Please share any concrete difficulties you would encounter should we drop |
@ayushn21 one potential concern I have is we rely on https://github.com/dvmonroe/sanity-ruby for integrating our CMS. This uses Active Support. I'm sure many other projects include AS due to how common it is. Should we start vendoring or reinventing bits and pieces of AS, we run the risk of unexpected issues. Bugs like this could be tricky to identify, especially to someone that isn't completely aware that AS is being vendored or bits of it were recreated. I don't have any concrete examples besides that. There are numerous bits and pieces of AS that are useful though. It's not always apparent something relies on AS and removing it might comprimise the stability of the project, especially if some bits are here, but others aren't. I agree that project maintainers hold the sole right to make any decision they like. If I come up with any other items, I'll share those here. Lastly, I know I've made a few contributions to Bridgetown already that used AS. Being able to reach for a poweful tool to add new functionality, is super convenient. |
Thanks for sharing @jclusso :) I'm not that familiar with Bridgetown's usage of AS under the hood so I haven't got a response off the top of my head. I'll let @jaredcwhite address that when he has some time and will do my own research as and when I get time. |
Please let me know which gems are owned by people violating their own CoCs and I will gladly take a close look. There's no slippery slope here!
Vendoring is merely a near-term solution, I'll grant you that. The long-term solution is to migrate off completely. This is certainly no easy feat and will take some real time and effort. For example, it only just dawned on me the other day that the CLI framework we use, Thor, is completely located within the Rails repo! It was actually migrated from I believe wycats (aka Yehuda Katz, the original author) some while back. I honestly have no idea at the present moment how to deal with that. Regarding Active Support specifically, it's obviously not going to blink out of existence right away. We'll whittle away at it a bit for v2, some more for v2.1, etc. And long-term, here's what I can promise you. If you want to But expecting us to use AS in perpetuity merely because it's convenient or popular is a huge leap. Other Ruby web frameworks don't use it. Hanami doesn't use it. Roda doesn't use it. Sinatra doesn't use it. Sidekiq, a very popular background jobs processor, doesn't use it. The reason Bridgetown uses it is because when the project started in 2000, the events in question re: 37signals & CoCs hadn't transpired yet, I was still a happy Rails user, and Active Support was indeed very useful and convenient. But I was already aware at that time that many fine Rubyists out there have real issues with how much AS affects the Ruby runtime and the amount of monkey-patching involved. That didn't bother me enough to avoid using it. But here we are. As @ayushn21 said, while we may not reach agreement on the philosophy of this, we very much want to avoid suddenly breaking any user projects purely out of some lofty principle and without technical merit. Heck, I'm struggling just trying to break my own habit of using With regards to this particular issue (adding a default Inflector to the config), this is a new feature for v2.0. Using something like dry-inflector shouldn't cause any major issues if we do it right, and that's something I'm quite comfortable with taking on. For example, Hanami seems to have dry-inflector working fine with Zeitwerk and it looks easy enough to set up acronyms like |
@brandondrew Doing the same thing would be authoring a PR that completely removes all trace of Active Support etc. and then merging it in a few hours later. 😅 Thankfully we're not doing that! |
I'm sure there's gotta be some. I'm not going down that rabbit hole though!
At least we can agree on this.
I want to start by saying I think your time is valuable, as well as that of anyone else that is contributing to OS. With that being said, it's disappointing to see that limited time spent replacing stuff, instead of on new stuff. You've written about some exciting things like Signals and what not. I'm sure most Bridgetown users would be way more excited to see a release with real changes vs. housekeeping.
Fair enough. I wasn't sure if the removal of AS would lead to situation like "we don't support AS, so that's not worth figuring out". |
5th most popular gem just means its a dependency of Rails to be fair. I don't think that alone has any technical merit. My personal view is ActiveSupport is a leaky abstraction that patches Ruby internals. Which can be a good thing in some cases, but its definitely a large monolithic gem as @ayushn21 pointed out. ActiveSupport is also notorious for breaking conventions and needing funky workarounds to get bundler to work correctly. I remember a few versions of Bridgetown hitting issues with ActiveSupport. All that to say, it doesn't really matter to me what happens. But I also have very little love for ActiveSupport in the first place 🤷 |
After some testing, it looks like we can get all the functionality we need with Dry::Inflector, so I've just added that in #881. Can go ahead and close this one out. |
Details forthcoming…this is a placeholder item to determine which inflector to use as we're removing Active Support dependencies.
Some possible options:
The text was updated successfully, but these errors were encountered: