Skip to content

[Bug] CI build script accepts flags as values for required options #293

Description

@slfan1989

Search before asking

  • I searched in the issues and found nothing similar.

Paimon-cpp version

Paimon version

Current main branch.

Minimal reproduce step

Run one of the following commands:

ci/scripts/build_paimon.sh --source_dir --enable_asan

ci/scripts/build_paimon.sh \
  --source_dir . \
  --build_type --enable_asan

ci/scripts/build_paimon.sh \
  --source_dir . \
  --lint_git_target_commit --enable_asan

The script treats the following option as the value of the preceding option and continues until a later command fails or CMake is invoked with an invalid value.

The script also accepts unsupported build types:

ci/scripts/build_paimon.sh \
  --source_dir . \
  --build_type Profile

What doesn't meet your expectations?

Options that require a value should reject an empty value or another --option with a clear error message.

The --build_type option should only accept the standard CMake build types used by the project:

  • Debug
  • Release
  • RelWithDebInfo
  • MinSizeRel
    Invalid arguments should be rejected before creating build directories or invoking CMake.

The argument validation behavior is currently not covered by dedicated script-level tests.

Anything else?

No response

Are you willing to submit a PR?

  • I'm willing to submit a PR!

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions