Closed (fixed)
Project:
Search API attachments
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
27 Jul 2016 at 12:11 UTC
Updated:
9 May 2017 at 19:04 UTC
Jump to comment: Most recent, Most recent file

Comments
Comment #2
itsekhmistro commentedComment #3
itsekhmistro commentedComment #4
izus commentedhmm,
i can't reproduce the bug !
i can see the configuration form of all available extration plugins (solr, tika, pdf2text...)
are you sure of using the last versions of search_api_attachments and search_api ?
Comment #5
itsekhmistro commentedHi Ismaeil,
>are you sure of using the last versions of search_api_attachments and search_api ?
Yes, I 'm using the latest dev versions of both modules.
Comment #6
OlgaRabodzei commentedHello!
The topic of the issue is about an index configuration form. I attach screenshots to clarify the problem.
I would be pleased, if you checked this bug one more time.
Comment #7
itsekhmistro commentedHi Ismaeil,
Could you recheck this?
Thanks.
Comment #8
edysmpIt is working for me.
Comment #9
cmah commentedI am getting the following error message when I click on that same checkbox (File attachments shown in the above screencap) ever since I upgraded from search_api 1.0-alpha17 to search_api 1.0-beta2:
Fatal error: Call to undefined method Drupal\search_api\Processor\ProcessorPluginBase::submitConfigurationForm() in /modules/contrib/search_api_attachments/src/Plugin/search_api/processor/FilesExtrator.php on line 456Is this a related issue?
Comment #10
itsekhmistro commentedYes @chickenofeathers, https://www.drupal.org/node/2773343#comment-11696101 it's a related issue.
You can apply the patch to fix it.
Comment #11
webiator gmbh commentedPatch works for me
Comment #12
tuwebo commentedHi, patch works fine for me. Thanks!
Comment #13
lba_emanuel commentedHi,
Maybe patch works but i think it's not solution.
FilesExtrator class extends a wrong class.
Correct class is FieldsProcessorPluginBase and not ProcessorPluginBase. Like this :
(My patch is for beta3 version)
Comment #14
lba_emanuel commentedSorry,
My patch is for 8.x-1.0-alpha4 and work with a Search API 8.x-1.0-beta3
Comment #15
ekes commentedComment #13 rather begs the question here. Related #2784747: File contents field does not appear.
The way processors are now split up in Search API, and how this processor is added as an additional property (the field/s you can add), the configuration should actually with the property (just like Aggregated Fields configuration is).
However, if the processor was a preprocessor of a filefield, then it should be on this page.
I'm guessing that the correct answer, as it would change the type of the field, is that it is an additional property, and the configuration should be on the property.
Comment #16
itsekhmistro commentedHi,
Reviewed the patch from comment #13.
First have to mention that the patch format is invalid. And thus the patch can't be applied automatically.
However I have manually applied the changes and tested it on my project.
Good part - the Processor configuration does appear.
Bad part - there are configuration for fields from index and those fields has nothing to do with FileExtractor.
Still, the patch attached initially in the issue https://www.drupal.org/files/issues/search_api_attachments.FileExtractor...
looks better for me. And moreover it address other minor issues in configuration.
Comment #17
wengerkI try the following patch FileExtractor-configform.patch and fix it there : FileExtractor-configform-alpha4
It now works properly with an automatic install through composer Eg.
Comment #18
ekes commentedIf the plan is to leave the the processor on this page even though it adds a property, and can't be moved in process order, the top patch is using the correct classes. The FieldsProcessorPluginBase is designed for adding the option to select which fields to operate on.
However, it removes the submit method, which means the configuration excluded_extensions are never converted to the excluded_mimes stored in the configuration. It's these types that are actually used to exclude file types in FilesExtrator::isFileIndexable() via call to FilesExtractor::getExcludedMimes()
To remove the error related to the excluded extension (while saving the mime-type) there is a separate issue #2821884: Default excluded extensions not working correctly
I've pushed a version of the repo with this and other patches from the queue that are RTBC'd to sandbox updated version of Search API Attachments 8.x-1.x.
Comment #20
izus commentedThanks all
this is now merged and will be part of next beta
Thanks again !