As seen in #2537290: Call to undefined function feeds_importer_load_all() trying to run an upgrade for change source and target definitions is crazy. Let's not do it.
We can maintain compatibility by allowing targets and sources to be hidden, that way things can change, but existing installs still work.
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | feeds-allow-hidden-targets-2542416-9.patch | 7.36 KB | twistor |
| #9 | interdiff.txt | 3.79 KB | twistor |
| #8 | interdiff-2542416-5-8.txt | 2.18 KB | megachriz |
| #8 | feeds-allow-hidden-targets-2542416-8.patch | 7.28 KB | megachriz |
| #5 | feeds-allow-hidden-targets-2542416-5.patch | 6.19 KB | twistor |
Comments
Comment #1
twistor commentedAlso, even force enabling and loading modules to try and run the upgrade won't fix importers that are in disabled features and such.
Comment #2
twistor commentedComment #4
twistor commentedComment #5
twistor commentedComment #6
twistor commentedComment #7
twistor commentedThis should delete the whole update hook, just make it a no-op.
Comment #8
megachrizNice work. I tested this patch by defining a mapper to "field_image" and by setting one source from FeedsSyndicationParser to be hidden. Both show up as "DEPRECATED" when the importer uses them, so I guess this is good.
My review:
It would be nice if the key of the target is shown even if the target is "hidden".
Further in the code
$sourcegets a second time through check_plain(). This causes text to be double escaped.In the attached patch I addressed points 1, 2 and 4 from above. If a hidden target is used, it will show up like this:
We could debate about what to call the property ("hidden" or "deprecated"). Now it seems not to be consistent to have a target that is marked as hidden and when it used it is marked as deprecated.
Comment #9
twistor commentedMy comment in #7 was supposed to say, "This should not delete the whole update hook, just make it a no-op."
I agree, deprecated makes more sense than hidden. I was just going off of other keys in other parts of the API.
Comment #11
megachrizAll looks good. Committed #9.