Index: src/wp-includes/post.php
===================================================================
--- src/wp-includes/post.php	(revision 39412)
+++ src/wp-includes/post.php	(working copy)
@@ -2995,8 +2995,9 @@
 	$post_ID = 0;
 	$update = false;
 	$guid = $postarr['guid'];
-
+	error_log(json_encode($postarr));
 	if ( ! empty( $postarr['ID'] ) ) {
+		error_log('UPDATE!!!');
 		$update = true;
 
 		// Get the post ID and GUID.
Index: tests/phpunit/tests/post/revisions.php
===================================================================
--- tests/phpunit/tests/post/revisions.php	(revision 39412)
+++ tests/phpunit/tests/post/revisions.php	(working copy)
@@ -382,4 +382,30 @@
 
 		$this->assertEquals( $revision_ids, array_values( wp_list_pluck( $revisions, 'ID' ) ) );
 	}
+
+	/**
+	 * @ticket 39011
+	 */
+	function test_wp_first_revision_is_not_lost() {
+		$post = self::factory()->post->create_and_get( array(
+			'post_title' => 'some-post',
+			'post_type' => 'post',
+			'post_content' => 'Initial Content',
+		) );
+		wp_update_post( $post );
+		wp_update_post( array(
+			'ID' => $post->ID,
+			'post_content' => 'Update #1',
+		) );
+
+		wp_update_post( array(
+			'ID' => $post->ID,
+			'post_content' => 'Update #2',
+		) );
+
+		$revisions = wp_get_post_revisions( $post->ID );
+		$earliest_revision = end( $revisions );
+
+		$this->assertEquals( 'Initial Content', $earliest_revision->post_content );
+	}
 }
