Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Support NLog.config from UNC path #5666

Copy link
Copy link

Description

@snakefoot
Issue body actions

Seems NET9 changes the System.AppContext.BaseDirectory and AppDomain.CurrentDomain.BaseDirectory to UNC paths:

  • \\?\UNC\rwells\very\special\bin\Development\net9.0\NLog.config
  • \\?\C:\Temp\NLog.config

These paths cannot be handled by Uri-object, which is used inside XmlReader for loading NLog.config-file. Uri throws System.UriFormatException - Invalid URI: The hostname could not be parsed..

Possible work-around is to manually read the contents of the NLog.config-file, and give the stream/string to the XmlReader (Only apply work-around when path starts with \\?\)

See also: https://stackoverflow.com/q/79208703/193178

Reactions are currently unavailable

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    Morty Proxy This is a proxified and sanitized view of the page, visit original site.