{"record":{"id":"6ff931596f2a5c66","repo":"apache/hadoop","slug":"change-detection-policy-requires-s","errorCode":null,"errorMessage":"Change detection policy requires %s","messagePattern":"Change detection policy requires (.+?)","errorType":"exception","errorClass":"NoVersionAttributeException","httpStatus":null,"severity":"error","filePath":"hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/impl/ChangeTracker.java","lineNumber":213,"sourceCode":"\n  /**\n   * Process the response from the server for validation against the\n   * change policy.\n   * @param copyObjectResponse response of a copy operation\n   * @throws PathIOException raised on failure\n   * @throws RemoteFileChangedException if the remote file has changed.\n   */\n  public void processResponse(final CopyObjectResponse copyObjectResponse)\n      throws PathIOException {\n    // ETag (sometimes, depending on encryption and/or multipart) is not the\n    // same on the copied object as the original.  Version Id seems to never\n    // be the same on the copy.  As such, there isn't really anything that\n    // can be verified on the response, except that a revision ID is present\n    // if required.\n    String newRevisionId = policy.getRevisionId(copyObjectResponse);\n    LOG.debug(\"Copy result {}: {}\", policy.getSource(), newRevisionId);\n    if (newRevisionId == null && policy.isRequireVersion()) {\n      throw new NoVersionAttributeException(uri, String.format(\n          \"Change detection policy requires %s\",\n          policy.getSource()));\n    }\n  }\n\n  /**\n   * Process an exception generated against the change policy.\n   * If the exception indicates the file has changed, this method throws\n   * {@code RemoteFileChangedException} with the original exception as the\n   * cause.\n   * @param e the exception\n   * @param operation the operation performed when the exception was\n   * generated (e.g. \"copy\", \"read\").\n   * @throws RemoteFileChangedException if the remote file has changed.\n   */\n  public void processException(SdkException e, String operation) throws\n      RemoteFileChangedException {\n    if (e instanceof AwsServiceException) {","sourceCodeStart":195,"sourceCodeEnd":231,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/impl/ChangeTracker.java#L195-L231","documentation":"Error \"Change detection policy requires %s\" thrown in apache/hadoop.","triggerScenarios":"Thrown at hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/impl/ChangeTracker.java:213 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set fs.s3a.change.detection.source (etag or versionid) so the change detection policy has the attribute it requires."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-22T20:17:22.307Z"}