Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
field_release_recommended doesn't get created on install, which then means that project nodes crash.
This is because the code to create the field is wrapped in this test:
// Add a recommended toggle to the API taxonomy, if there is one.
$api_vocabulary = taxonomy_vocabulary_load(variable_get('project_release_api_vocabulary', ''));
if ($api_vocabulary !== FALSE) {
field_create_field(array(
'translatable' => '0',
'settings' => array(
'allowed_values' => array(
0 => '',
1 => $t('Recommended for project releases'),
),
'allowed_values_function' => '',
),
'field_name' => 'field_release_recommended',
AFAICT there is no code that takes care of creating that vocabulary. So the field will never get created.
Comment | File | Size | Author |
---|---|---|---|
#6 | 2161823-6.patch | 985 bytes | dww |
Comments
Comment #1
drummYep, the API vocabulary-related code isn't the best. API vocabularies are meant to be optional, the field should be created when a vocabulary is configured to be an API vocabulary.
Comment #2
eabquina CreditAttribution: eabquina as a volunteer commentedSad that I also encountered this as well...
As a workaround, I manually created field_release_recommended TEXT Field.
I thought first that making a Term Reference field fixes it, but I encountered a Field SQL error that it misses a field_recommended_release_value column.
No more errors when adding Releases. But now we see error:
Found this issue here but not really sure if it is related:
https://www.drupal.org/node/749166
Comment #3
foredoc CreditAttribution: foredoc commentedSame here...
Any solutions yet?
Thanks.
Regards,
foredoc
Comment #4
ajoboe CreditAttribution: ajoboe commentedI'm having the same issue as techopsph and foredoc.
Comment #5
BartGysens CreditAttribution: BartGysens commented+1: having the same issue - even after reinstall...
EntityFieldQueryException: Unknown: field_release_recommended in EntityFieldQuery->addFieldCondition() (rule 841 in .../www_html/includes/entity.inc).
when I want to manage the releases
UPDATE: this helped me a little further: https://www.drupal.org/node/749166
Now bumping in this error:
Comment #6
dwwWe're moving away from this vocabulary overall.
But until that happens, yeah, we should definitely create it on install, since so much depends on it (and things horribly explode if it doesn't exist).
Comment #8
dww