feature: Migrate RestSharp to target .NET Framework 4.8#16
Open
devin-ai-integration[bot] wants to merge 1 commit into
Open
feature: Migrate RestSharp to target .NET Framework 4.8#16devin-ai-integration[bot] wants to merge 1 commit into
devin-ai-integration[bot] wants to merge 1 commit into
Conversation
Remove the legacy RestSharp.Net2 project (LinqBridge + System.Xml.Linq polyfills) and retarget RestSharp, RestSharp.Tests and RestSharp.IntegrationTests to v4.8. Drop NET_2_0/Net2 conditional compilation, upgrade Newtonsoft.Json to 13.0.3 (net45) and xunit to 2.4.2, and update solution/nuspec metadata accordingly. Co-Authored-By: Travis Myers <travis.myers@cognition.ai>
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Retargets the RestSharp core library and test projects from .NET 3.5/4.0 to .NET Framework 4.8 and removes the legacy
RestSharp.Net2project, which existed only to backport features (LINQ +System.Xml.Linq) that ship in 4.8. Verified withmono xbuild(all projects build) and the xUnit console runner: 83/83 unit tests pass.Project retargeting
RestSharp.csproj:v3.5→v4.8; removed<TargetFrameworkProfile>Client</TargetFrameworkProfile>(no Client Profile in 4.x), removed the<RequiredTargetFramework>3.5</RequiredTargetFramework>hints onSystem.Core/System.ServiceModel.Web/System.Xml.Linq, dropped the 3.5-SP1BootstrapperPackageentries, and removed the duplicateMicrosoft.CSharp.targetsimport ($(MSBuildBinPath)one; kept$(MSBuildToolsPath)).DefineConstantsleft asTRACE;DEBUG;FRAMEWORK.RestSharp.Tests.csproj/RestSharp.IntegrationTests.csproj:v4.0→v4.8.Dependency upgrades
4.x→ 13.0.3 (lib\net45), reference +packages.config+ nuspec dependency range[13.0.3,).1.9.x→ 2.4.2. References switched toxunit.core/xunit.assert/xunit.abstractions(+xunit.execution.desktop, required so the v2 console runner can discover/run the desktop test assembly). Test sources needed no code changes (onlyAssert.*/[Fact]are used; noPropertyData/DoesNotThrow/xunit.extensions).Removed RestSharp.Net2 project
RestSharp.Net2/(LinqBridge + 28-fileSystem.Xml.Linqreimplementation) and itspackages.config; removed the project from bothRestSharp.slnand the renamedRestSharp.Net2.sln→RestSharp.Net48.sln; dropped its entry frompackages/repositories.config.Conditional compilation cleanup
The
NET_2_0/Net2symbols are now never defined, so the dead branches were removed (keptFRAMEWORKblocks, which still distinguish Silverlight/WP/Mono targets):(Only these two files in this fork actually referenced
NET_2_0/Net2; the broader file list in the request reflects upstream RestSharp, not this fork.)Notes / out of scope
RestSharp.Mono.slnwere left untouched — they are separate platform targets, not part of the 4.8 retarget.packages/folder (the repo vendors its NuGet packages) was updated: added the Newtonsoft 13.0.3 + xUnit 2.4.2 package set and removed the now-unused 4.x/1.x packages.Test plan
Link to Devin session: https://app.devin.ai/sessions/29818d0169444e82a3eca9a1f16d0ae6
Requested by: @travismyers-png
Devin Review