floci-io/floci · error · AwsException

Override %s must not be blank.

Error message

Override %s must not be blank.

What it means

Thrown by the Lambda invoke action when the invocation returns a FunctionError (Handled/Unhandled) or an HTTP status of 400+. The emulator builds a CodePipeline.job event, invokes the configured function synchronously (RequestResponse), and any function-side failure fails the pipeline action with ActionExecutionFailed. The message contains the function error string.

Source

Thrown at src/main/java/io/github/hectorvent/floci/core/common/ReservedTags.java:169

            throw new AwsException(errorCode, "Override %s contains unsupported characters.".formatted(name), 400);
        }
        if (normalized.chars().anyMatch(Character::isISOControl)) {
            throw new AwsException(errorCode, CONTROL_CHARACTER_ERROR_MESSAGE.formatted(name), 400);
        }
        return normalized;
    }

    private static String validateClientSecret(String overrideSecret, String name, String errorCode) {
        String normalized = checkNullAndWhitespace(overrideSecret, name, errorCode);
        if (normalized.chars().anyMatch(Character::isISOControl)) {
            throw new AwsException(errorCode, CONTROL_CHARACTER_ERROR_MESSAGE.formatted(name), 400);
        }
        return normalized;
    }

    private static String checkNullAndWhitespace(String overrideSecret, String name, String errorCode) {
        if (overrideSecret == null || overrideSecret.trim().isEmpty()) {
            throw new AwsException(errorCode, "Override %s must not be blank.".formatted(name), 400);
        }
        String normalized = overrideSecret.trim();
        if (normalized.chars().anyMatch(Character::isWhitespace)) {
            throw new AwsException(errorCode, "Override %s must not contain whitespace.".formatted(name), 400);
        }
        return normalized;
    }


    private static boolean isReserved(String key) {
        return key != null && key.startsWith(RESERVED_PREFIX);
    }
}

View on GitHub (pinned to 62ff490619)

Solutions

  1. Invoke the function directly (aws lambda invoke) with the same CodePipeline.job event shape and read the error/stack trace
  2. Wrap the function body in try-catch, report PutJobFailureResult with failureDetails, and still exit cleanly so the pipeline records a controlled failure
  3. Verify configuration.FunctionName matches an existing function in the same emulator region/account

Example fix

// before (lambda handler)
exports.handler = async (job) => { deployArtifact(job); /* throws -> unhandled */ };

// after
exports.handler = async (job) => {
  try { deployArtifact(job); } catch (e) {
    await cp.putJobFailureResult({ jobId: job.id, failureDetails: { type: 'JobFailed', message: e.message } }).promise();
  }
};
Defensive patterns

Strategy: retry

Validate before calling

if (action.configuration().get("FunctionName") == null
        || lambda.getFunction(r -> r.functionName(cfg.get("FunctionName")).build()) == null) {
    throw new IllegalStateException("Lambda action target does not exist");
}

Try / catch

try {
    lambda.invoke(r -> r.functionName(fn).payload(codec.toJson(jobEvent)));
} catch (AwsServiceException fnErr) {
    // transient invoke failures: retry with backoff before failing the pipeline action
}

Prevention

When it happens

Trigger: Lambda function raising an exception before calling PutJobSuccessResult; function returning a non-2xx via the emulator's invoke layer; function timeout or resource error surfaced as FunctionError; wrong FunctionName in the action configuration.

Common situations: Job worker functions that forget to catch their own errors; functions that assume a real AWS environment (role, env vars) absent in the emulator; artifact processing code failing on unexpected input.

Related errors


AI-assisted analysis of floci-io/floci@62ff490619 (2026-08-14). Data as JSON: /api/errors/63f27243658f5ecf. Report an issue: GitHub.