Skip to content

[Bug] Maven build fails in directories with spaces in their names #11768

Open
@Jzow

Description

@Jzow

What happened

During local Maven build testing, it was found that when the project is placed in a directory with spaces in its name, a compilation error occurs. Specifically, Maven fails to handle spaces in the path correctly, leading to a build failure.

Upon investigation, it was discovered that the issue was caused by the exec-maven-plugin plugin mishandling paths with spaces. This problem has been fixed in a newer version of the plugin. Refer to the following links for more details:

The solution is to upgrade the exec-maven-plugin plugin version from 1.6.0 to 3.1.0. Update the version number in the pom.xml file as follows:

<exec.maven.version>3.1.0</exec.maven.version>

What you expected to happen

Maven should properly handle spaces in the path and successfully complete the project build.

How to reproduce

  1. Clone the project locally.
  2. Rename the project directory to include spaces, e.g., Open Source.
  3. Run the Maven build command: mvn clean install.
  4. Observe the compilation error.

Environment

  • Operating System: All
  • Maven Version: 3.x
  • JDK Version: 1.8

InLong version

master

InLong Component

Other for not specified component

Are you willing to submit PR?

  • Yes, I am willing to submit a PR!

Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Labels

    type/bugSomething is wrong

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions