Skip to content

compile_commands.json is not generated if cli run with --only-compilation-database ends in error #1245

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

Open
ag88 opened this issue Mar 29, 2021 · 0 comments
Assignees
Labels
topic: build-process Related to the sketch build process topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project

Comments

@ag88
Copy link

ag88 commented Mar 29, 2021

Bug Report

Current behavior

this issue is discovered in Arduino IDE 2.0 beta 4 found here
arduino/arduino-ide#220 (comment)

if arduino-cli compile is run with --only-compilation-database ends in error, compile_commands.json is not generated

however if arduino-cli compile is run without --only-compilation-database the build completes, though with a success : false status and a detailed compile_commands.json file is successfully generated

the complete details is in the Arduino IDE issue comment link above.

Expected behavior

the missing compile_commands.json file causes definition and symbol lookup to fail in Arduino IDE 2.0.
it would seem --only-compilation-database needs to run to completion even if encountering some errors as otherwise compile_commands.json is not generated

Environment

  • CLI version (output of arduino-cli version):
  • arduino-cli version
    arduino-cli alpha Version: 0.17.0 Commit: ab58758 Date: 2021-03-17T15:10:16Z
  • OS and platform: linux opensuse

Additional context

the problem is discovered in Arduino IDE 2.0 beta4

@per1234 per1234 added topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project labels Jan 31, 2022
@umbynos umbynos added the topic: build-process Related to the sketch build process label Nov 30, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic: build-process Related to the sketch build process topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project
Projects
None yet
Development

No branches or pull requests

4 participants