Skip to content

Fixed Exception caused by Empty Lines in config file. #1099

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

Merged
merged 2 commits into from
May 17, 2022

Conversation

JBeamer92
Copy link
Contributor

Description

What behavior does this PR change, and why?

The config file provided in the C# setup contains empty lines with a Length of 0. This was causing Exceptions when trying to read the config file in the LoadConfig method because the empty lines were not being filtered out by the Where clause. By filtering out empty lines with a length of 0, the LoadConfig method completes without exceptions and the application completes as expected.

Author Validation

Describe the validation already done, or needs to be done, by the PR submitter.
Verified using .NET 6.0. Needs to be tested against earlier versions of .NET to prove backwards compatibility.

[ ] clients/cloud

Reviewer Tasks

Describe the tasks/validation that the PR submitter is requesting to be done by the reviewer.
Needs to be tested against earlier versions of .NET to prove backwards compatibility.

[ ] clients/cloud

JBeamer92 added 2 commits May 15, 2022 15:12
LoadConfig method caused an exception due to the fact that the Where filter did not filter out empty lines in the Config file, causing an exception when running the C# demo with the provided config file in C# Setup Guide.
@ybyzek
Copy link
Contributor

ybyzek commented May 16, 2022

@bbejeck do you happen to have the right environment set up to validate this PR?

@bbejeck
Copy link
Contributor

bbejeck commented May 16, 2022

do you happen to have the right environment set up to validate this PR?

Yes - I have .NET versions 3, 5, and 6 installed - I can test against all 3

@bbejeck
Copy link
Contributor

bbejeck commented May 17, 2022

Tested against .NET 6 and 5 - .NET 3 is pretty old and not compatible with Confluent.Kafka 1.8.2 so IMHO going with version 5 is good enough

@ybyzek
Copy link
Contributor

ybyzek commented May 17, 2022

@bbejeck thanks so much for validating and @JBeamer92 thanks again for the PR! Merging now

@ybyzek ybyzek merged commit 13f50af into confluentinc:7.1.0-post May 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants