Comments (8)
@adityamandaleeka Excellent.
Well there is an initial implementation of VirtualPathUtility
for AspNet Core in the repo I mentioned previously. I started putting together some test cases, but haven't had time to go through all permutations or functions. There is a test library (netstandard2.0) with some test calls of ToAbsolute
, and it is consumed by an AspNet Core net6.0 project and an AspNet/System.Web net48 project. *Same output on both.
I'm not quite sure what to do about a test plan, but I could probably create a PR with the code from the VirtualPathUtility.Library project as is?
Let me know how you want to proceed.
*It should be noted that the net48 implementation doesn't actually throw the error listed in the docs. The framework throws an ArgumentException
with a custom message, not an ArgumentOutOfRangeException
for ToAbsolute with an invalid relative path. I'm not sure which is actually better, but it is a mismatch. I can probably change it to more closely match the net framework implementation if need be.
from systemweb-adapters.
I think a lot of the implementation for this is already in System.Web.Util.UrlPath
. It is just that that is a) not public and b) not in AspNet Core.
from systemweb-adapters.
Triage: This sounds reasonable. @CZEMacLeod would you be interested in contributing some/all of the implementation for this?
from systemweb-adapters.
@adityamandaleeka I've had a look at this and I could certainly put together something if it was based on the code / logic in the net48 System.Web.Util.UrlPath
- but I don't believe that is under any form of open-source agreement. I guess the mono project would have a version, but again I'm not sure about the copyright for that.
I could certainly look at (re)implementing this from scratch, based solely on the published docs, although I think it might easily miss some edge cases covered in other implementations, especially as I am not aware of any sort of test suite/data to check the implementation against.
from systemweb-adapters.
@adityamandaleeka Some code here https://github.com/CZEMacLeod/System.Web.VirtualPathUtility - note that this is based partially on the net48 framework System.Web.Util.UrlPath
implementation and I'm not entirely sure what the legalities are around that code.
from systemweb-adapters.
@CZEMacLeod, thanks for being cautious with licensing. The good news is that there's no issue from the licensing perspective to use code from the .NET Framework sources since they're under an acceptable license (MIT).
We might have to add a third-party notice entry in this repo. I'll follow up internally to take care of that.
from systemweb-adapters.
@CZEMacLeod Feel free to open a PR for this and we'll review the approach. It may take a bit longer than usual now since the team is fairly occupied at the moment, but we'll get to it as soon as we can.
from systemweb-adapters.
Closed via #179
from systemweb-adapters.
Related Issues (20)
- Session serializer does not support nullables
- Caching.Cache.Insert is missing the overload with 3 arguments
- Support for UrlHelper methods during incremental migration HOT 3
- 413 Request Limit too Large HOT 1
- Broken links in README.md
- Add Missing API: HttpCapabilitiesBase.Cookies HOT 1
- Ask About WebConfigurationManager, ConfigurationManager, HttpRuntimeSection, MachineKeySection, AuthenticationSection, AuthorizationSection HOT 4
- Ask About System.Web.Hosting.HostingEnvironment HOT 2
- Ask About HttpCachePolicy and HttpResponse.Cache HOT 4
- Ask About HttpContext.Trace and TraceContext
- Ask About HttpContext.SetSessionStateBehavior HOT 3
- Ask About HttpRequest.CurrentExecutionFilePath HOT 2
- Ask About HttpRequest.PhysicalPath HOT 4
- Ask about HttpResponse.BufferOutput HOT 1
- Ask about HttpResponse.Filter
- Add Missing API HttpResponse.HeadersWritten HOT 3
- Ask About HttpServerUtility.TransferRequest HOT 3
- Ask About HtmlTextWriter
- Session State is not working or Could not redirect to WebForms page. HOT 25
- Improve documentation for remote authentication with Blazor HOT 2
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 systemweb-adapters.