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

Document the syntax of OpenApiError.Pointer #500

Closed
KalleOlaviNiemitalo opened this issue Jul 14, 2020 · 1 comment · Fixed by #583
Closed

Document the syntax of OpenApiError.Pointer #500

KalleOlaviNiemitalo opened this issue Jul 14, 2020 · 1 comment · Fixed by #583
Assignees
Labels
type:bug A broken experience
Milestone

Comments

@KalleOlaviNiemitalo
Copy link

KalleOlaviNiemitalo commented Jul 14, 2020

The OpenApiError.Pointer property currently has a minimal XML documentation comment:

/// <summary>
/// Pointer to the location of the error.
/// </summary>
public string Pointer { get; set; }

I would like to see documentation of the possible syntaxes here. I have an MSBuild task that tries to parse this string and pass line and column numbers to TaskLoggingHelper.LogError.

Currently, the possibilities seem to be:

(Some errors have more detailed location information in OpenApiError.Message. Filed #502 for making that easier to access.)

@KalleOlaviNiemitalo
Copy link
Author

Verified that OpenApiError.Pointer in Microsoft.OpenApi.Readers 1.2.2 does not escape / as ~1 if the error occurs within a Path Item Object, whose key in the Paths Object always starts with a slash.

@darrelmiller darrelmiller added bug-fix type:bug A broken experience and removed bug-fix labels Sep 28, 2020
@darrelmiller darrelmiller added this to the 1.3 milestone Sep 28, 2020
@darrelmiller darrelmiller self-assigned this Mar 15, 2021
darrelmiller added a commit that referenced this issue May 2, 2021
Fixes issues with the pointer in the OpenApiError object
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug A broken experience
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants