Github user aljoscha commented on a diff in the pull request:

    https://github.com/apache/flink/pull/2746#discussion_r86549195
  
    --- Diff: 
flink-tests/src/test/java/org/apache/flink/test/checkpointing/SavepointITCase.java
 ---
    @@ -339,9 +339,12 @@ protected void run() {
                                        SubtaskState subtaskState = 
taskState.getState(tdd.getIndexInSubtaskGroup());
     
                                        assertNotNull(subtaskState);
    -                                   errMsg = "Initial operator state 
mismatch.";
    -                                   assertEquals(errMsg, 
subtaskState.getLegacyOperatorState(),
    -                                                   
tdd.getTaskStateHandles().getLegacyOperatorState());
    +
    +                                   if (subtaskState.hasState()) {
    --- End diff --
    
    I think this check can actually be replaced by 
`subtaskState.getLegacyOperatorState()` and if you do that there is no place in 
the code that calls `SubtaskState.hasState()`, making it obsolete.
    
    Please correct me if I'm wrong. 😅 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to