Problem/Motivation

MR.

Backport is complete - all tests are fully green on:

  1. Drupal 10.5.x
  2. Drupal 11.1.x
  3. Drupal 11.2.x
  4. Drupal 11.3.x

Untested on

  • Drupal 10.4.x (untested)

BACKGROUND INFORMATION:

We need to support Drupal 10.4.x, Drupal 10.5.x and Drupal 11.1.x and are unable to upgrade to Drupal 11.2.5 at this time due to various reasons.

We need the said functionality provided by 3.0.x that was added in:
#3173808: Make book child content-type configurable per enabled book content-type

We had the desired functionality working with Drupal 10 using a core patch.

When we upgraded to Drupal 11, we dropped the core patch obviously, since it no longer applied, forgot about it, and then 8 months after upgrading we noticed a bunch of broken functionality that previously was not broken.

The fix/features were applied to 3.0.x however 3.0.x was made incompatible with Drupal 11.1.8.

So, I've made it compatible with Drupal 11.1.8, Drupal 10.5.x without breaking Drupal 11.2.x and Drupal 11.3.x.

Proposed resolution

See MR

Remaining tasks

Review MR and test it.

User interface changes

See
#3173808: Make book child content-type configurable per enabled book content-type

and including all fixes/enhancements that are currently in 3.0.x

Issue fork book-3554905

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

joseph.olstad created an issue. See original summary.

joseph.olstad’s picture

Assigned: joseph.olstad » Unassigned
Status: Active » Needs review

Ok I brought everything from book 3.0.x over to book 2.0.x

and then I backed off the changes that make 3.0.x incompatible with Drupal 11.1.8.

I changed all the version pinning from ^11.2 to ^11.1

made another change to book.post_update.php as it crashed my environment, the changes are in the merge request.

"drupal/book": "2.0.x-dev#b966267a as 2.0.2",

this patch:

"patches": {
     "drupal/book": {
          "3554905 - Port book allow other types to create books to 2.0.x":
           "https://git.drupalcode.org/project/book/-/merge_requests/127.diff"
      }
 },

joseph.olstad’s picture

Assigned: Unassigned » joseph.olstad
Status: Needs review » Active

Need to make a new MR based off of 3555112 and set it to merge to 2.0.x

#3555112: Make 1.0.x Livre a version of Book 3.0.x that is compatible with Drupal 11.1.8+

smustgrave’s picture

Status: Active » Closed (won't fix)

Sorry this feature I purposely did not backport for it's disruptive behavior.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

joseph.olstad’s picture

Status: Closed (won't fix) » Active

We need this desperately before a prod release. Cannot upgrade to D11.2.x so we need this functionality in D11.1.8.

All tests are passing 100% in Drupal 11.2.x while there's now only two fails , possibly insignificant fails for D11.1.8.

joseph.olstad’s picture

So, we had the desired functionality working with Drupal 10 using a core patch.

When we upgraded to Drupal 11, we dropped the core patch obviously, since it no longer applied, forgot about it, and then 8 months after upgrading we noticed a bunch of broken functionality that previously was not broken.

The fix/features were applied to 3.0.x however 3.0.x was made incompatible with Drupal 11.1.8.

So, I've made it compatible with Drupal 11.1.8 and only seeing two errors in the tests that likely won't affect us, and to avoid problems with composer I'm creating a merge patch to bring this back to 2.0.x.

Would like to fix the two remaining issues but probably don't need to.

joseph.olstad’s picture

Issue summary: View changes
joseph.olstad’s picture

Issue summary: View changes
joseph.olstad’s picture

*** EDIT ***

Noise

*** END EDIT ***

joseph.olstad’s picture

Almost perfect now.

"drupal/book": "2.0.x-dev#b966267a as 2.0.2",

this patch:

"patches": {
     "drupal/book": {
          "3554905 - Port book allow other types to create books to 2.0.x":
           "https://git.drupalcode.org/project/book/-/merge_requests/131.diff"
      }
 },

joseph.olstad’s picture

Title: 2.0.x backport of: Make book child content-type configurable per enabled book content-type » 2.0.x backport of 3.0.x
joseph.olstad’s picture

Next commit will add test coverage for 10.5.x

joseph.olstad’s picture

Title: 2.0.x backport of 3.0.x » 2.0.x clean full backport of 3.0.x

joseph.olstad changed the visibility of the branch 3554905-cleaner-backport to hidden.

joseph.olstad changed the visibility of the branch 3554905-full-backport to hidden.

joseph.olstad changed the visibility of the branch 3554905-merge-3.0.x-into-2.0.x-with-fixes to hidden.

joseph.olstad’s picture

Issue summary: View changes
joseph.olstad’s picture

Assigned: joseph.olstad » Unassigned
Status: Active » Needs review
smustgrave’s picture

I’ll leave these 2 issues open for a week or so but will eventually close out to keep the queue clear for just valid issues

Thanks!

joseph.olstad’s picture

Issue summary: View changes
joseph.olstad’s picture

Issue summary: View changes
joseph.olstad’s picture

Title: 2.0.x clean full backport of 3.0.x » Livre - evaluate Book 2.0.x with a clean full backport of 3.0.x
Project: Book » Livre
Version: 2.0.x-dev »
Assigned: Unassigned » joseph.olstad
joseph.olstad’s picture

Version: » 1.0.x-dev
Assigned: joseph.olstad » Unassigned
Status: Needs review » Closed (won't fix)

Basically not needed now, Livre 1.0.x is compatible with Drupal 10.5.x, Drupal 11.1.x, Drupal 11.2.x and Drupal 11.3.x and is based off of the 3.0.x branch of the Book module.

Keeping an eye on the upstream for changes, will ensure git aligns when possible.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

joseph.olstad’s picture

Assigned: Unassigned » joseph.olstad
Status: Closed (won't fix) » Active

updating the merge request.

joseph.olstad’s picture

Issue summary: View changes
joseph.olstad’s picture

Assigned: joseph.olstad » Unassigned
Status: Active » Closed (won't fix)

All tests passing, 100% green!

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

joseph.olstad’s picture

Assigned: Unassigned » joseph.olstad
Status: Closed (won't fix) » Needs review

Reviewing this

smustgrave’s picture

Sorry for the noise closing MRs on the book side.

joseph.olstad’s picture

StatusFileSize
new276.06 KB
joseph.olstad’s picture

Patch #44 essentially makes book 2.0.x equivalent to livre 1.0.2 , which it'self is essentially book 3.0.x except backwards compatible with all supported releases of Drupal core.

With that said, probably easier to move forward with livre until we're ready for Drupal 11.2/11.3.

Keeping both options on the table for the moment:

Option #1 ) Patch the book module (276 kilobytes of patching)
Option #2 ) Simply require drupal/livre , no need to patch, replaces book without fuss.

joseph.olstad’s picture

StatusFileSize
new275.71 KB

Rolled again for 2.0.3

joseph.olstad’s picture

Ok patch 47 won't roll, fatal merge conflict, I won't be able to maintain book 2.0.x this way, recommending everyone use livre instead which aligns well with book 3.0.x.

joseph.olstad’s picture

hmm , might have been a composer glitch

joseph.olstad’s picture

Ok for book 2.0.3:

apply this patch which reverts the conflicting bit
Revert conflict

then this patch
backport 3x

then this patch
what was removed from conflict, apply forward fix from 3x instead

smulvih2’s picture

@joseph is it possible for WxT to stick with drupal/book 1.x (last updated April 2024) and have that work as it did before, and wait for WxT 6.2.x (11.2.x) to upgrade to book 3.x? Essentially skip book 2.x?

joseph.olstad’s picture

StatusFileSize
new269.74 KB

This patch is for 2.0.3 specifically

Ok comment #50 is for 2.0.x dev only.

I've made a new one, one patch for book 2.0.3 which brings all of the 3.0.x functionality to 2.0.x , this should work.

The conflict with patch 47 and 2.0.3 was related to the stupid build info yml with the release date

New patch now

joseph.olstad’s picture

Unfortunately we already upgraded to 2.0.x with wxt 5.4.x and 6.1.x so we're committed now.

Also, I've aligned the configuration to the new array format in the bundle settings for book 3.0.x / livre 1.0.x

I recomment livre 1.0.7+

joseph.olstad’s picture

Status: Needs review » Active

Reviewing this again.

joseph.olstad’s picture

Assigned: joseph.olstad » Unassigned
Status: Active » Closed (won't fix)

Not needed, livre 1.0.5 is based on book 3.0.x, has nothing from 2.0.x.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.