You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "CurtHagenlocher (via GitHub)" <gi...@apache.org> on 2025/09/26 17:28:23 UTC
[PR] Move to latest version of System.CommandLine package [arrow-dotnet]
CurtHagenlocher opened a new pull request, #83:
URL: https://github.com/apache/arrow-dotnet/pull/83
## What's Changed
Moves integration tests to the latest version of the System.CommandLine package.
Closes #3.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Move to latest version of System.CommandLine package [arrow-dotnet]
Posted by "CurtHagenlocher (via GitHub)" <gi...@apache.org>.
CurtHagenlocher commented on PR #83:
URL: https://github.com/apache/arrow-dotnet/pull/83#issuecomment-3339924588
@kou, I *think* the integration tests are failing for infrastructure reasons rather than as a result of this change -- especially because this failure model looks familiar -- but I'm not sure.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Move to latest version of System.CommandLine package [arrow-dotnet]
Posted by "Copilot (via GitHub)" <gi...@apache.org>.
Copilot commented on code in PR #83:
URL: https://github.com/apache/arrow-dotnet/pull/83#discussion_r2383022790
##########
test/Apache.Arrow.Flight.IntegrationTest/Program.cs:
##########
@@ -23,45 +25,61 @@ public static class Program
{
public static async Task<int> Main(string[] args)
{
- var portOption = new Option<int>(
- new[] { "--port", "-p" },
- description: "Port the Flight server is listening on");
- var scenarioOption = new Option<string>(
- new[] { "--scenario", "-s" },
- "The name of the scenario to run");
- var pathOption = new Option<FileInfo>(
- new[] { "--path", "-j" },
- "Path to a JSON file of test data");
-
- var rootCommand = new RootCommand(
- "Integration test application for Apache.Arrow .NET Flight.");
+ var portOption = new Option<int>("--port", "-p")
+ {
+ Description = "Port the Flight server is listening on",
+ };
+ var scenarioOption = new Option<string>("--scenario", "-s")
+ {
+ Description = "The name of the scenario to run",
+ };
+ var pathOption = new Option<FileInfo>("--path", "-j")
+ {
+ Description = "Path to a JSON file of test data",
+ };
var clientCommand = new Command("client", "Run the Flight client")
{
portOption,
scenarioOption,
pathOption,
};
- rootCommand.AddCommand(clientCommand);
-
- clientCommand.SetHandler(async (port, scenario, jsonFile) =>
+ clientCommand.SetAction(async (parseResult, cancellationToken) =>
{
- var command = new FlightClientCommand(port, scenario, jsonFile);
+ var command = new FlightClientCommand(
+ parseResult.GetValue(portOption),
+ parseResult.GetValue(scenarioOption),
+ parseResult.GetValue(pathOption));
await command.Execute().ConfigureAwait(false);
- }, portOption, scenarioOption, pathOption);
+ });
var serverCommand = new Command("server", "Run the Flight server")
{
scenarioOption,
};
- rootCommand.AddCommand(serverCommand);
-
- serverCommand.SetHandler(async scenario =>
+ serverCommand.SetAction(async (parseResult, cancellationToken) =>
{
- var command = new FlightServerCommand(scenario);
+ var command = new FlightServerCommand(
+ parseResult.GetValue(scenarioOption));
await command.Execute().ConfigureAwait(false);
- }, scenarioOption);
+ });
Review Comment:
The `SetAction` method appears to be used instead of the standard `SetHandler` method. Verify that `SetAction` is the correct method name in the System.CommandLine 2.0.0-rc.1.25451.107 API, as this may be a deprecated or incorrect method name.
##########
test/Apache.Arrow.Flight.IntegrationTest/Program.cs:
##########
@@ -23,45 +25,61 @@ public static class Program
{
public static async Task<int> Main(string[] args)
{
- var portOption = new Option<int>(
- new[] { "--port", "-p" },
- description: "Port the Flight server is listening on");
- var scenarioOption = new Option<string>(
- new[] { "--scenario", "-s" },
- "The name of the scenario to run");
- var pathOption = new Option<FileInfo>(
- new[] { "--path", "-j" },
- "Path to a JSON file of test data");
-
- var rootCommand = new RootCommand(
- "Integration test application for Apache.Arrow .NET Flight.");
+ var portOption = new Option<int>("--port", "-p")
+ {
+ Description = "Port the Flight server is listening on",
+ };
+ var scenarioOption = new Option<string>("--scenario", "-s")
+ {
+ Description = "The name of the scenario to run",
+ };
+ var pathOption = new Option<FileInfo>("--path", "-j")
+ {
+ Description = "Path to a JSON file of test data",
+ };
var clientCommand = new Command("client", "Run the Flight client")
{
portOption,
scenarioOption,
pathOption,
};
- rootCommand.AddCommand(clientCommand);
-
- clientCommand.SetHandler(async (port, scenario, jsonFile) =>
+ clientCommand.SetAction(async (parseResult, cancellationToken) =>
{
- var command = new FlightClientCommand(port, scenario, jsonFile);
+ var command = new FlightClientCommand(
+ parseResult.GetValue(portOption),
+ parseResult.GetValue(scenarioOption),
+ parseResult.GetValue(pathOption));
await command.Execute().ConfigureAwait(false);
- }, portOption, scenarioOption, pathOption);
+ });
var serverCommand = new Command("server", "Run the Flight server")
{
scenarioOption,
};
- rootCommand.AddCommand(serverCommand);
-
- serverCommand.SetHandler(async scenario =>
+ serverCommand.SetAction(async (parseResult, cancellationToken) =>
{
- var command = new FlightServerCommand(scenario);
+ var command = new FlightServerCommand(
+ parseResult.GetValue(scenarioOption));
await command.Execute().ConfigureAwait(false);
- }, scenarioOption);
+ });
Review Comment:
The `SetAction` method appears to be used instead of the standard `SetHandler` method. Verify that `SetAction` is the correct method name in the System.CommandLine 2.0.0-rc.1.25451.107 API, as this may be a deprecated or incorrect method name.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Move to latest version of System.CommandLine package [arrow-dotnet]
Posted by "CurtHagenlocher (via GitHub)" <gi...@apache.org>.
CurtHagenlocher merged PR #83:
URL: https://github.com/apache/arrow-dotnet/pull/83
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Move to latest version of System.CommandLine package [arrow-dotnet]
Posted by "CurtHagenlocher (via GitHub)" <gi...@apache.org>.
CurtHagenlocher commented on code in PR #83:
URL: https://github.com/apache/arrow-dotnet/pull/83#discussion_r2383023874
##########
test/Apache.Arrow.Flight.IntegrationTest/Program.cs:
##########
@@ -23,45 +25,61 @@ public static class Program
{
public static async Task<int> Main(string[] args)
{
- var portOption = new Option<int>(
- new[] { "--port", "-p" },
- description: "Port the Flight server is listening on");
- var scenarioOption = new Option<string>(
- new[] { "--scenario", "-s" },
- "The name of the scenario to run");
- var pathOption = new Option<FileInfo>(
- new[] { "--path", "-j" },
- "Path to a JSON file of test data");
-
- var rootCommand = new RootCommand(
- "Integration test application for Apache.Arrow .NET Flight.");
+ var portOption = new Option<int>("--port", "-p")
+ {
+ Description = "Port the Flight server is listening on",
+ };
+ var scenarioOption = new Option<string>("--scenario", "-s")
+ {
+ Description = "The name of the scenario to run",
+ };
+ var pathOption = new Option<FileInfo>("--path", "-j")
+ {
+ Description = "Path to a JSON file of test data",
+ };
var clientCommand = new Command("client", "Run the Flight client")
{
portOption,
scenarioOption,
pathOption,
};
- rootCommand.AddCommand(clientCommand);
-
- clientCommand.SetHandler(async (port, scenario, jsonFile) =>
+ clientCommand.SetAction(async (parseResult, cancellationToken) =>
{
- var command = new FlightClientCommand(port, scenario, jsonFile);
+ var command = new FlightClientCommand(
+ parseResult.GetValue(portOption),
+ parseResult.GetValue(scenarioOption),
+ parseResult.GetValue(pathOption));
await command.Execute().ConfigureAwait(false);
- }, portOption, scenarioOption, pathOption);
+ });
var serverCommand = new Command("server", "Run the Flight server")
{
scenarioOption,
};
- rootCommand.AddCommand(serverCommand);
-
- serverCommand.SetHandler(async scenario =>
+ serverCommand.SetAction(async (parseResult, cancellationToken) =>
{
- var command = new FlightServerCommand(scenario);
+ var command = new FlightServerCommand(
+ parseResult.GetValue(scenarioOption));
await command.Execute().ConfigureAwait(false);
- }, scenarioOption);
+ });
Review Comment:
Go home, Copilot; you're drunk.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Move to latest version of System.CommandLine package [arrow-dotnet]
Posted by "CurtHagenlocher (via GitHub)" <gi...@apache.org>.
CurtHagenlocher commented on PR #83:
URL: https://github.com/apache/arrow-dotnet/pull/83#issuecomment-3341859737
> I opened [apache/arrow-go#521](https://github.com/apache/arrow-go/issues/521) for it.
Thanks; it looks like this is impacting all test runs so I'm going to go ahead and commit this PR as I don't believe it to be related.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Move to latest version of System.CommandLine package [arrow-dotnet]
Posted by "kou (via GitHub)" <gi...@apache.org>.
kou commented on PR #83:
URL: https://github.com/apache/arrow-dotnet/pull/83#issuecomment-3341402687
I opened https://github.com/apache/arrow-go/issues/521 for it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org