Problem/Motivation

The "Configuration Read-only mode" module locks forms that are for updating config entities.
SearchPageForm extends EntityForm, which means that search forms are locked when that module is installed.
#2794413: Search form is locked

Proposed resolution

Stop extending EntityForm

Remaining tasks

User interface changes

API changes

Data model changes

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

tim.plunkett created an issue. See original summary.

tim.plunkett’s picture

Status: Active » Needs review
Related issues: +#2794413: Search form is locked
FileSize
2.83 KB
claudiu.cristea’s picture

The patch looks good but what if a custom/contrib module class extends methods from SearchPageForm that are part of EntityForm, like ::form(), ::actions()?

tim.plunkett’s picture

Forms/controllers and form arrays AND entity handlers are all explicitly not protected by BC.
https://www.drupal.org/core/d8-bc-policy#controllers

claudiu.cristea’s picture

Status: Needs review » Needs work

@tim.plunkett, thank you for clarifying this. Given that SearchPageForm is not marked as @api this is not a BC break.

However, the search_page config entity claims that this form is an entity form:

 *     "form" = {
 *       "add" = "Drupal\search\Form\SearchPageAddForm",
 *       "edit" = "Drupal\search\Form\SearchPageEditForm",
 *       "search" = "Drupal\search\Form\SearchPageForm",
 *       "delete" = "Drupal\Core\Entity\EntityDeleteForm"
 *     }

Also the docblock of \Drupal\search\Plugin\SearchInterface::searchFormAlter() makes a reference to \Drupal\search\Form\SearchPageForm::form() and that shold be adapted too.

Version: 8.3.x-dev » 8.4.x-dev

Drupal 8.3.0-alpha1 will be released the week of January 30, 2017, which means new developments and disruptive changes should now be targeted against the 8.4.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

pwolanin’s picture

Issue tags: +Novice

marking as novice since it seems the remaining work consists of minor annotation and code comment fixes.

tameeshb’s picture

Assigned: Unassigned » tameeshb
pwolanin’s picture

Assigned: tameeshb » Unassigned

Please don't leave assigned for more than a day (or at all - sometimes better just to leave a comment if you are immediately working on it)

Lal_’s picture

Assigned: Unassigned » Lal_
Status: Needs work » Needs review
FileSize
2.83 KB
claudiu.cristea’s picture

Assigned: Lal_ » Unassigned
Status: Needs review » Needs work

#5 still not addressed.

pwolanin’s picture

Seems to be the same patch?

joyceg’s picture

@pwolanin,

so, reroll to 8.4-x-dev?

pwolanin’s picture

Status: Needs work » Needs review
FileSize
4.02 KB
1.19 KB

Ok, seems #10 is a re-roll for 8.4.x, but not labeled as such. Seems like tim's patch doesn't apply to 8.4.x using git apply

Here are also the fixes suggested by claudiu.cristea.

claudiu.cristea’s picture

Status: Needs review » Reviewed & tested by the community
Issue tags: -Novice

@pwolanin, Indeed, I suggested that entity "search" form is not an entity form and should be removed from annotation. This is correct, hope no custom or contrib code has referred the form by using the "search" key.

Looks good.

alexpott’s picture

This is correct, hope no custom or contrib code has referred the form by using the "search" key.

I've checked search_api - shouldn't be impacted. Tests pass too.

  • catch committed 993ede0 on 8.4.x
    Issue #2845743 by pwolanin, tim.plunkett, AbhishekLal, claudiu.cristea,...
catch’s picture

Status: Reviewed & tested by the community » Fixed

Committed/pushed to 8.4.x, thanks!

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.