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

handle the case kernelinfo si deserialised as dicittionary #2576

Merged
merged 3 commits into from
Dec 27, 2022

Conversation

colombod
Copy link
Member

From vscode invocation the document is deserialized and the medatadata now is a dictionary. This fixes saving notebooks

}

// todo: the kernelInfo should not deserialize as a dictionary
if (kernelInfoObj is Dictionary<string,object> kernelInfoAsDictionary)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a test for the issue this is intended to resolve?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just added a test that uses serialize and parse request. Serialize touches the new code. The document used in test comes from a vscode serialize request.

@colombod colombod enabled auto-merge (rebase) December 27, 2022 21:08
[Fact]
public void Notebook_parser_server_can_handle_serialize_requests()
{
var request = @"{
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jonsequitur this request is taken from vscode

@colombod colombod merged commit 782c941 into dotnet:main Dec 27, 2022
@colombod colombod deleted the metadata_update branch December 27, 2022 23:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants