iflytek/astron-agent · warning
SysData is empty for version: botId=
Error message
SysData is empty for version: botId={}, versionName={} What it means
getVersionSysData found the workflow_version row but its sys_data column is null or blank, so there is no serialized system data to return. It logs a warning with botId and versionName and returns null. This usually means the version was published without sysData being persisted.
Solutions
- Inspect the row: SELECT sys_data FROM workflow_version WHERE bot_id=? AND name=? to confirm emptiness
- Re-publish the version so sysData is regenerated and persisted
- Backfill sys_data for legacy rows via migration from the bot's current flow data
- Add a publish-time assertion that sysData is non-empty before committing the version row
Example fix
// before
if (StringUtils.isBlank(sysData)) { return null; }
// after
if (StringUtils.isBlank(sysData)) {
log.warn("SysData empty, regenerating for botId={}, versionName={}", botId, versionName);
return regenerateAndPersistSysData(botId, versionName);
} Defensive patterns
Strategy: validation
Validate before calling
WorkflowVersion v = mapper.selectOne(new LambdaQueryWrapper<WorkflowVersion>()
.eq(WorkflowVersion::getBotId, botId).eq(WorkflowVersion::getName, versionName));
if (v == null || v.getSysData() == null || v.getSysData().isBlank()) {
throw new IllegalStateException("Version exists but sysData missing for " + versionName);
} Type guard
boolean hasSysData(WorkflowVersion v) { return v != null && v.getSysData() != null && !v.getSysData().trim().isEmpty(); } Try / catch
try {
return mapper.selectOne(qw).getSysData();
} catch (NullPointerException | IllegalStateException e) {
log.error("sysData unavailable for botId={}, versionName={}", botId, versionName, e);
return regenerateSysData(botId, versionName);
} Prevention
- Enforce non-empty sysData at publish time with a DB NOT NULL/CHECK constraint
- Add a migration to backfill sys_data for legacy version rows
- Alert on any inserted workflow_version row with empty sys_data
- Re-publish versions after schema upgrades that touch sys_data
When it happens
Trigger: versionData(botId, versionName) hits a row whose sys_data is empty/null — e.g. publish pipeline failed to write sysData, an older schema/migration left the column empty, or the row was written by a code path that never populates sys_data.
Common situations: Versions created before a migration added sys_data; publish interrupted after row insert but before sysData write; a different service overwrote sys_data to empty; environment where JSON serialization of flow data silently failed.
Understand the failure class
Background: "must not be empty", "cannot be empty" — required-field validation errors across open-source libraries — this error's family across 41 libraries.
Related errors
- Workflow version not found in database: botId=
- 8100
- CREATE_BOT_FAILED
- DATA_NOT_EXIST
- DATABASE_COPY_FAILED
AI-assisted analysis of iflytek/astron-agent@5e758547a8 (2026-09-12).
Data as JSON: /api/errors/cb123560f266d78b.
Report an issue: GitHub.
Appendix: source
Thrown at console/backend/hub/src/main/java/com/iflytek/astron/console/hub/service/workflow/impl/WorkflowReleaseServiceImpl.java:280
}
String sysData = workflowVersion.getSysData();
if (sysData != null && !sysData.trim().isEmpty()) {
try {
JSONObject versionData = JSON.parseObject(sysData);
return versionData == null || versionData.isEmpty() ? null : versionData;
} catch (Exception e) {
log.error(
"Failed to parse sysData JSON: botId={}, versionName={}, sysDataLength={}",
botId,
versionName,
sysData.length(),
e);
return null;
}
}
log.warn("SysData is empty for version: botId={}, versionName={}", botId, versionName);
return null;
} catch (Exception e) {
log.error("Exception occurred while getting version system data: botId={}, versionName={}",
botId, versionName, e);
return null;
}
}
/**
* Update audit result
*/
private boolean updateAuditResult(
Long versionId, String flowId, String auditResult, String executionUid, Long executionSpaceId) {
if (versionId == null) {
log.warn("Version ID is null, skipping audit result update");
return false;
}View on GitHub (pinned to 5e758547a8)