Skip to content

CI/CD Pipeline False Positives: import-dir Exits with Code 0 on Failures#474

Open
aniket866 wants to merge 1 commit into
microcks:masterfrom
aniket866:fix/Pipeline-False-Positives
Open

CI/CD Pipeline False Positives: import-dir Exits with Code 0 on Failures#474
aniket866 wants to merge 1 commit into
microcks:masterfrom
aniket866:fix/Pipeline-False-Positives

Conversation

@aniket866

Copy link
Copy Markdown
Contributor

Issue

graph TD
    A[Start import-dir] --> B[Scan Directory]
    B --> C[Import File 1: Success]
    B --> D[Import File 2: FAILED]
    C & D --> E[Display Results Summary]
    E --> F["Exit Status Code 0 (Success)"]
    F --> G["CI/CD pipeline reports green/success despite failures"]
Loading

Steps to Reproduce

  1. Run microcks import-dir ./specs where at least one spec has invalid content.
  2. The console displays ✗ Failed: ....
  3. Check the exit code of the process (echo $? or $LASTEXITCODE in PowerShell). It returns 0.

fixed: #473

@Harishrs2006 @lbroudoux
Please do review

Signed-off-by: aniket866 <iamaniketkumarmaner@gmail.com>
@aniket866

Copy link
Copy Markdown
Contributor Author

@Vaishnav88sk do checkout this one too

@github-actions

Copy link
Copy Markdown

This pull request has been automatically marked as stale because it has not had recent activity 😴

It will be closed in 30 days if no further activity occurs. To unstale this pull request, add a comment with detailed explanation.

There can be many reasons why some specific pull request has no activity. The most probable cause is lack of time, not lack of interest. Microcks is a Cloud Native Computing Foundation project not owned by a single for-profit company. It is a community-driven initiative ruled under open governance model.

Let us figure out together how to push this pull request forward. Connect with us through one of many communication channels we established here.

Thank you for your patience ❤️

@github-actions github-actions Bot added the stale State due to inactivity label Jul 25, 2026
Comment thread cmd/importDir.go
Comment on lines 199 to +202
fmt.Printf("\nImport completed: %d/%d files imported successfully\n", result.SuccessCount, result.TotalFiles)
if result.FailedCount > 0 {
os.Exit(1)
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is the right behavior change for CI/CD, but please add a test that covers the partial-failure path and verifies we return a non-zero exit when FailedCount > 0.

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

Labels

stale State due to inactivity

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CI/CD Pipeline False Positives: import-dir Exits with Code 0 on Failures

2 participants