alibaba/DataX · error · IllegalArgumentException

您提供的作业配置有误, List不能为空.

Error message

您提供的作业配置有误, List不能为空.

What it means

Thrown by ListUtil.makeSureNoValueDuplicate when the provided List<String> is null or empty. Despite the method's purpose (duplicate detection), its first guard rejects empty/null input as an invalid job configuration, reflecting DataX's assumption that such lists (e.g. column lists) must be non-empty. Note isListHasDuplicate swallows this and returns true.

Source

Thrown at common/src/main/java/com/alibaba/datax/common/util/ListUtil.java:36

    public static boolean checkIfValueDuplicate(List<String> aList,
                                                boolean caseSensitive) {
        if (null == aList || aList.isEmpty()) {
            throw DataXException.asDataXException(CommonErrorCode.CONFIG_ERROR,
                    "您提供的作业配置有误,List不能为空.");
        }

        try {
            makeSureNoValueDuplicate(aList, caseSensitive);
        } catch (Exception e) {
            return true;
        }
        return false;
    }

    public static void makeSureNoValueDuplicate(List<String> aList,
                                                boolean caseSensitive) {
        if (null == aList || aList.isEmpty()) {
            throw new IllegalArgumentException("您提供的作业配置有误, List不能为空.");
        }

        if (1 == aList.size()) {
            return;
        } else {
            List<String> list = null;
            if (!caseSensitive) {
                list = valueToLowerCase(aList);
            } else {
                list = new ArrayList<String>(aList);
            }

            Collections.sort(list);

            for (int i = 0, len = list.size() - 1; i < len; i++) {
                if (list.get(i).equals(list.get(i + 1))) {
                    throw DataXException
                            .asDataXException(

View on GitHub (pinned to 80ec23d5c5)

Solutions

  1. Populate the list (e.g. add column names) in the job configuration
  2. If calling programmatically, guard with an isEmpty check before invoking and handle the empty case in your own logic
  3. Verify upstream parsing didn't drop the list contents (wrong key name returning empty)

Example fix

// before
ListUtil.makeSureNoValueDuplicate(columns, true); // columns == []
// after
if (columns != null && !columns.isEmpty()) {
    ListUtil.makeSureNoValueDuplicate(columns, true);
}
Defensive patterns

Strategy: validation

Validate before calling

if (aList == null || aList.isEmpty()) { /* treat as config error with your own clear message */ }

Type guard

boolean isNonEmptyList(List<String> l) { return l != null && !l.isEmpty(); }

Try / catch

catch (IllegalArgumentException e) {
  if ("您提供的作业配置有误, List不能为空.".equals(e.getMessage())) { /* populate the list in config */ }
  throw e;
}

Prevention

When it happens

Trigger: Calling makeSureNoValueDuplicate(aList, caseSensitive) with a null or empty list — e.g. validating a column configuration where the user specified an empty "column": [].

Common situations: Job config with "column": [] or omitted column list reaching validation; programmatic callers passing a filtered-then-empty list; expecting the duplicate-checker to be a no-op on empty input.

Related errors


AI-assisted analysis of alibaba/DataX@80ec23d5c5 (2026-08-14). Data as JSON: /api/errors/66727ccad76d0a55. Report an issue: GitHub.