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

Target .net 6.0 (and later), removing newtonsoft dependency #630

Open
waynebrantley opened this issue Sep 15, 2022 · 16 comments
Open

Target .net 6.0 (and later), removing newtonsoft dependency #630

waynebrantley opened this issue Sep 15, 2022 · 16 comments
Labels
status: help wanted requesting help from the community status: work in progress Twilio or the community is in the process of implementing type: community enhancement feature request not on Twilio's roadmap

Comments

@waynebrantley
Copy link

Issue Summary

Any chance on getting the library updated past netstandard 2.0. By targeting net6.0 and later, you can use system.text.json and not need newtonsoft. You can still create a netstandard 2.0 release with newtonsoft.

@rakatyal
Copy link
Contributor

Hi @waynebrantley! Thanks for reporting the issue. This is on our radar. Pull requests and +1s on the issue summary will help it move up the backlog.

@rakatyal rakatyal added type: community enhancement feature request not on Twilio's roadmap status: help wanted requesting help from the community labels Sep 22, 2022
@waynebrantley
Copy link
Author

@rakatyal there are 12 prs now and concerned that large changes like this will not be merged if a PR is created. Can you assure that PRs with changes that are needed like this will not just sit as a PR with no one touching?

@waynebrantley
Copy link
Author

@rakatyal Any update? As a developer centric product (Twilio really, really relies on developers to help them grow) - this library should be brought up to date and target at least net6 and remove these dependencies. In addition, I think you should really engage and handle all these now 15 prs as they just age out. No community member is going to do this - because the PR will just sit there.

This problem appears to be a problem across Twilio. twilio/twilio-voice.js#55

@waynebrantley
Copy link
Author

@Swimburger @AsabuHere @rakatyal Any update. Need to use System.Text.Json. Additional targets for dotnet 6,7,8 etc would be nice too.
Developers are your bread and butter. Without them - twilio would cease to exist. You really should embrace your projects and keep them up to date.

@Swimburger
Copy link
Contributor

@waynebrantley System.Text.Json is supported on netstandard2.0 too, so the Twilio library should be able to use those APIs on all supported versions of .NET, except for .NET Framework 3.5. .NET Framework 3.5 could keep using Newtonsoft.Json.

@waynebrantley
Copy link
Author

@Swimburger agree - just need to get it done. Those on netframework 3.5 dont have to upgrade either. Hard to believe people are still on that... 5.5yrs left on support for it...so time is ticking down!

Any movement inside Twilio to get this done?

@Swimburger
Copy link
Contributor

@waynebrantley I don't have visibility on that as a former Twilion, but I don't expect this to be done anytime soon.

@josephrodriguez
Copy link

Came to this problem for the same reason when I saw the use of Newtonsoft.Json. It's really a bit disconcerting how this project evolve so slowly in the face of changes in the .NET ecosystem, mainly when is the SDK project of a well know company like Twilio. Newtonsoft library was deprecated for .NET Core 3 at Sep 23, 2019, we are using .NET 8.

@tiwarishubham635
Copy link
Contributor

We tried to address this issue in version 7.0.0 however this issue (#732) came up as people were still using previous versions.

@Swimburger
Copy link
Contributor

We tried to address this issue in version 7.0.0 however this issue (#732) came up as people were still using previous versions.

Removing .NET Framework support doesn't make sense since it's still highly in use.

The built-in JSON library System.Json.Text is supported on .NET6, .NET Framework 4.6.2, and .NET Standard 2.0.
In fact, you could just build for .NET Standard 2.0 and then .NET 6+ and .NET Framework 4.6.2+ would use that build.

You can remove newtonsoft.json and replace it with System.Json.Text.
Newtonsoft.json very often causes issues because so many libraries depend on different versions of the library causing version conflicts. So not taking that dependency would reduce friction for users of this library.

@tiwarishubham635 tiwarishubham635 added the status: work in progress Twilio or the community is in the process of implementing label Apr 15, 2024
@tiwarishubham635
Copy link
Contributor

Sure, I'll check that

@tiwarishubham635
Copy link
Contributor

I was checking here and it says we need .NET Framework 4.7.2+. Won't that be an issue for many users?

@Swimburger
Copy link
Contributor

@tiwarishubham635 That's odd. I have created a GitHub issue for them to clarify this.
dotnet/docs#41005

@Swimburger
Copy link
Contributor

They updated the docs. The support is .NET Framework 4.6.2+

@jonatr35
Copy link

Any update on this?

@ltctech
Copy link

ltctech commented Dec 4, 2024

I've moved a few of my projects to System.Text.Json and realized that Newtonsoft.Json still remains due to Twilio.

I understand that Newtonsoft.Json still works, but .NET has very much moved on. This issue is more than two years old, why hasn't there been more traction on this?

Yes, STJ is a bit less forgiving and cumbersome for some types, but with a bit of customization it works well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: help wanted requesting help from the community status: work in progress Twilio or the community is in the process of implementing type: community enhancement feature request not on Twilio's roadmap
Projects
None yet
Development

No branches or pull requests

7 participants