Getting:
Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /home/hoslot5/public_html/modules/forum/forum.module).
followed by
Warning: Invalid argument supplied for foreach() in forum_menu_local_tasks_alter() (line 175 of /home/hoslot5/public_html/modules/forum/forum.module)
in watchdog.
I upgraded from 6x20 to 7.0 core. I've since switched to latest 7x forum in the hopes of resolving my issues related to the upgrade. This seems to be what's left.

I'll try anything. :)

CommentFileSizeAuthor
#34 D7_Modules.txt4.11 KBkwinz
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

kpoirier’s picture

Same here only I've just tried to upgrade to 7.2 from 6.19.

Golem07’s picture

Same problem here after upgrade to 7.2.

Additionally I cannot post to any forum or create a new topic - even as admin. I always get the error message:"You are not allowed to post new content in the forum."

Kakulash’s picture

Same.

No replies in a while. Anyone any closer to figuring this out? I'm stuck.

captaingeek’s picture

Priority: Normal » Critical

same

sun’s picture

Priority: Critical » Normal
Status: Active » Postponed (maintainer needs more info)

erm, why do you guys upgrade to 7.0 or 7.2, if there's a 7.7 already...?

Starminder’s picture

Because that's what was available at the time.

xjm’s picture

Marked #1213480: Forum Broken in Upgrade from D6 to D7 as duplicate. Please try:

  1. Upgrading to 7.7 and seeing if the problem still occurs.
  2. Clearing the cache and seeing if the problem still occurs.

Also, please post some steps to reproduce if possible.

pancrilio’s picture

Version: 7.0 » 7.7

I have exactly the same problem with a fresh 7.7. I have tried your steps, but problem persists. I press "Forum" in a users menu and the messages show in content area.

xjm’s picture

Please provide detailed, step-by-step instructions to reproduce the error, starting from "install drupal 7.7."

pancrilio’s picture

xjm, thanks for your interest... but I can't give you any more info really...

This is my first time installing Drupal, and I'm in the process of designing a new site. For now I've been installing most of the modules I'll be needing to test that eveything works together correctly, so I'm a total newbie still learning and reading all docs I can get my hands on.

I activated forums and this is the message I get when pressing on the menu button "forums". I activated permissions, created a container and a new topic, but still have the same message. I've tried with different users, but they all get the same message.

Maybe I haven't done something really basic....

I've sent you a message with the link to the site, just in case it enlightens you..

THANKS !!

crandallr’s picture

I also have had this problem.

Installed clean drupal 6.22, had old forum enabled with old advanced forum

upgraded to drupal 7.7 -> this error occurs

Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /htdocs/modules/forum/forum.module).

Warning: Invalid argument supplied for foreach() in forum_menu_local_tasks_alter() (line 175 of /htdocs/modules/forum/forum.module).

However this may somehow be related when viewing the permissions on the forum:
Notice: Undefined index: 0 in user_admin_account() (line 205 of htdocs/modules/user/user.admin.inc).

chjagge’s picture

Same issue here with 7.7. Has anyone found a resolution?

Starminder’s picture

Category: support » bug
Priority: Normal » Major
Status: Postponed (maintainer needs more info) » Active
xjm’s picture

I believe we still need some steps to reproduce. Can someone try:

  1. Install D6.22
  2. Enable forum and create some content
  3. Upgrade to D7.7

If this does result in the error, please provide more details and exactly what you did, step by step.

marcingy’s picture

Status: Active » Postponed (maintainer needs more info)

Back to postponed until information on how to recreate is provided.

Shyamala’s picture

Enable forum module in Drupal 6.22 instance. Added couple of forums and 2 forums topics as content.
Followed instructions at http://drupalcode.org/project/drupal.git/blob_plain/refs/heads/7.x:/UPGR... to upgrade to Drupal 7.7
- disabled all contrib modules
- reset theme to Garland
- took the site offline
- deleted all core files and site/default/default.setting.php
- run http://example.com/update.php
The site was upgraded to Drupal 7.7 in Garland theme

No error on Forums page, able to post forum topics. Upgrade was successful.
Unable to replicate the above issues.

xjm’s picture

Awesome, thanks @Shyamala. So it seems the problem is related to one of the following:

  1. Modules installed on the sites getting the errors
  2. Configurations on the sites getting the errors
  3. The upgrade process being used for those sites

We'll probably need someone who is getting this error to do some debugging. Some suggestions:

  • Follow the steps in #16 exactly when you do your upgrade.

  • Try clearing the site cache.

  • See if you can figure out steps to reproduce the issue. Is it related to a particular module you have installed? If you make a new site, how can you get the error again? Etc.

  • Do some debugging inside forum_menu_local_tasks_alter(). The part that is failing is this:

          // Loop through all bundles for forum taxonomy vocabulary field.          
          $field = field_info_field('taxonomy_forums');
          foreach ($field['bundles']['node'] as $type) {
    

    So sounds like funky is going on with the forum taxonomy field's data? Maybe try inspecting $field at this point in the code and seeing what's in there. Is it even a real field? That's where I'd start, at any rate.

larowlan’s picture

@chjagge, @StarMinder - can you please have a look at the fields setup against your node types (forum topic by default) that appear in the forum.
You should have a field called taxonomy_forums of type term reference that references your forum vocabulary.
the undefined index 'node' on this code

foreach ($field['bundles']['node'] as $type) {

would indicate that the forum field does not exist against any node types.
Please investigate and report back.

Starminder’s picture

I do have this field: taxonomy_forums Term reference Forum topic
However, this was the site Catch & Troky used early on to investigate various upgrade issues and i remember we manually corrected some of this stuff, so at this point it's hard to say...

larowlan’s picture

After the manual corrections did the message go away?

Starminder’s picture

@larowlan - yes, it did!

dirtylabrats’s picture

sorry I am a nubie, so can I ask what the final verdict for the fix was. thank you

Xomby’s picture

I'm also getting these messages after three clean installs of 7.8 (Ubuntu LAMP, godaddy shared hosting, AND easyphp-win7x64).

Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /<...>/modules/forum/forum.module).
Warning: Invalid argument supplied for foreach() in forum_menu_local_tasks_alter() (line 175 of /<...>/modules/forum/forum.module).

For S&G I added if(isset($field['bundle']['node'])){} around that foreach loop in forum.module, which completely eliminated the error message, but definitely did not fix the root issue.

It seems as though the [bundles] array (part of $fields variable referenced in #18) is just not being populated...

I'm also seeing no way to add an "add content->forum topic" to a specific forum.
If I brows to the forum container itself (/forum, or /forum/2) i see "you are not allowed to post new content in the forum" even as an admin.

[EDIT]
I fixed all three of my 7.8 installs with the same procedure:

  1. If activated - deactivate Advanced Forum module (save)
  2. Deactivate Forum module (save)
  3. In modules\forum\forum.install add
     set_time_limit(300); //5 minutes for installation
    

    to the top of the

     function forum_install() {
    set_time_limit(300); //5 minutes to install!
      // Set the weight of the forum.module to 1 so it is loaded after the taxonomy.module.
      db_update('system')
      ... 

    function and (save)

  4. open up phpmyadmin and backup your entire database
  5. then drop the following tables:
    • field_data_taxonomy_forums
    • field_revision_taxonomy_forums
    • forum
    • forum_index
  6. Now run a global search of your db for the word "forum" and delete ALL references found
  7. head back over to yoursite/admin/modules and re-activate the forum module
  8. confirm functionality

I hope this helps folks get their forums up and running at least until the glitch is worked out (7.9 anyone?). The best I can figure is during all three of my installs the 30 second timer ran out. When I tried to just install forums.module, it also timed out. My guess is that it didn't FINISH installing the forum module for me, so setting the time limit to 5 minutes gave it plenty of time to finish... BUT, I had to really clean out the references to forum module for everything to install properly.

ntigh52’s picture

Version: 7.7 » 7.9

also the same problem...
Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /<...>/modules/forum/forum.module).
Warning: Invalid argument supplied for foreach() in forum_menu_local_tasks_alter() (line 175 of /<...>/modules/forum/forum.module).

p.s.
when I uninstall te module and install it again I get page to refresh...
I cant create a forum or somthing?!.....

ntigh52’s picture

Hi all,
I think I found whats wrong.
I installed again my "Multilingual forum" Module and all fixed!!!!
p.s.
I dont know why that:
Toolbar, Shortcut, and Overlay Moduls disabled?!?! ..... But I activate them and now all fine....
My Idea: if you installed a module that activate forume module... activate it again!
Hope that it helps to fix the problem.

deinerson1’s picture

Status: Postponed (maintainer needs more info) » Active

Here's the output of $field just prior to line 175:

Array ( [settings] => Array ( [required] => [allowed_values] => Array ( [0] => Array ( [vocabulary] => vocabulary_1 [parent] => 0 ) ) ) [entity_types] => Array ( ) [translatable] => 0 [indexes] => Array ( [tid] => Array ( [0] => tid ) ) [storage] => Array ( [type] => field_sql_storage [settings] => Array ( ) [module] => field_sql_storage [active] => 1 [details] => Array ( [sql] => Array ( [FIELD_LOAD_CURRENT] => Array ( [field_data_taxonomy_forums] => Array ( [tid] => taxonomy_forums_tid ) ) [FIELD_LOAD_REVISION] => Array ( [field_revision_taxonomy_forums] => Array ( [tid] => taxonomy_forums_tid ) ) ) ) ) [id] => 2 [field_name] => taxonomy_forums [type] => taxonomy_term_reference [module] => taxonomy [active] => 1 [locked] => 0 [cardinality] => 1 [deleted] => 0 [columns] => Array ( [tid] => Array ( [type] => int [unsigned] => 1 [not null] => ) ) [bundles] => Array ( ) ) Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /var/www/vhosts/dev.wholewoman.com/httpdocs/wwbb/modules/forum/forum.module).

We upgraded to 7.10.

xjm’s picture

If I'm reading this right, the tid is the string 'taxonomy_forums_tid'? That looks bogus.

catch’s picture

Version: 7.9 » 8.x-dev
Issue tags: +Needs backport to D7

Fixing version.

strellman’s picture

On Drupal 7.10
How about a fix for the rest of us?
#23 sounds a bit intimidating.
I'm not sure how to perform #6 a global search of your db for the word "forum"
Could we put a cleanup script to run on 7.11 using update.php?

catch’s picture

Status: Active » Postponed (maintainer needs more info)

This still needs step by step instructions on how to reproduce - either starting from a clean install of 7.x, or posting a database dump (or a way to find one) from Drupal 6 to the issue (at least the contents of the {node_type} and {vocabulary} tables).

xjm’s picture

Priority: Major » Normal

Setting priority based on #30 (I think something can't both be major and postponed).

kwinz’s picture

Version: 8.x-dev » 7.10
Priority: Normal » Major

I had the same problem with a fresh D7 install. I had set up a new site a few weeks ago, with Drupal 7.10. I did *not* enable the forum module at first, but just created articles and pages etc. Yesterday I decided to add some forums. Before enabling the core Forum module, I installed the Advanced Forum module, intending to use them both together. I enabled them both, and then created 3 forums.

As soon as I clicked on any of the new forums, I got these errors. Note that I uninstalled the Advanced Forum module, but it didn't make any difference.

"You are not allowed to post new content in the forum."  (although logged in as administrator)

Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /hermes/bosweb25a/b109/ipg.castlevilleconnectio/modules/forum/forum.module).
Warning: Invalid argument supplied for foreach() in forum_menu_local_tasks_alter() (line 175 of /hermes/bosweb25a/b109/ipg.castlevilleconnectio/modules/forum/forum.module).

I did manage to clean up and work around the problem, by following the steps in Basically disabled the Forums module, then went into phpMyadmin and deleted anything having to do with forums, and then enabled Forums again. I created some new forums and they're working fine now. Hope this workaround might help others.

If you still can't reproduce the problem this way, some other modules I had installed (before enabling Forums for the first time) included Taxonomy Manager, LoginToboggan, Content Access, Rules, Token, and Variable.

larowlan’s picture

Bugs get fixed in 8 first and then back-ported to 7.
This does sound like it may be related to installing advanced forum and forum at the same time however until we can reproduce this - it stays at postponed as per #30.

kwinz’s picture

Version: 7.10 » 8.x-dev
Priority: Major » Normal
FileSize
4.11 KB

Attached is a dump of my installed modules, fyi.

xjm’s picture

Tagging.

SebaSOFT’s picture

Also having problems with a fresh D7 install, also didn't enable the forum module right away...

xjm’s picture

Thanks @SebaSOFT, can you post step-by-step how to get to that point? Like:

  1. Install 7.12 using the standard profile
  2. (Insert steps)
  3. Enable the forum module
  4. (Insert steps)

Thanks!

creativelabel’s picture

Came across the error this morning, now I'm no php developer, far from it in fact but try this.

I did a fresh install of Drupal and put my modules in 5 at a time to see what was causing the error. I eventually nailed it down to Chaos Tools (ctools). The strange thing was it didn't even need to be installed for it to through the error with the forum. I reversed the process and put the forum in first and then enabled chaos tools to see if it brought up an error. It did, but a different one.

hp: PDOException: SQLSTATE[42S02]: Base table or view not found:  [error]
1146 Table 'ctools_css_cache'

Reading up about that error it says one cause could be php running out of memory. I put this at the bottom of my settings.php and it fixed the problem.
ini_set('memory_limit', '512M');

Now 512 is probably far too high. So I would recommend trying that first to see if it solves the problem then drop it down to something more like 128 or 64 and try that. Hope that helps.

mgifford’s picture

Think the Undefined index issue in comment #11 is tied to #1189560: Undefined Index 0 notification error on People administration page

kelagedart’s picture

Had same problem with no permission to access forums in D7.14.

Uninstalled Forum module, and then immediately reinstalled.
Appears to have fixed the problem.

dewolfe001’s picture

Here's what I found on this:

  • I did a Drupal 6.22 to Drupal 7.14
  • I had the same forum problems
  • I made a point of rule the update.php, but it kept jamming out because some of the updates had already worked. I went into the install file and commented out the updates that were giving me problems and that let the rest run fine.
  • After that, I had no problems / errors.
larowlan’s picture

@dewolfe001 - can you please advise which update functions failed and which ones you had to comment out?

Lee

moran’s picture

Version: 8.x-dev » 7.15
Assigned: Unassigned » moran

Well i've update the d6 to d7.15
and i had in the d6 forum thread and now it's not working the same problem with line 175
any ideas what to do to fix it?

larowlan’s picture

Version: 7.15 » 8.x-dev

Bugs get fixed in 8.x then backported.
Moran, can you please provide steps to reproduce?
If possible, a sanitized D6 database would be helpful for testing (removing all user details etc).
BTW If you don't intend to work on it, please remove your name from the assigned field.

moran’s picture

Version: 8.x-dev » 7.14
Assigned: moran » Unassigned

update drupal
this is the steps that i used

neilotoole’s picture

So, I banged my head off this problem for several days. But I now have a (dodgy) workaround.

TL;DR: run update.php with your modules ENABLED.

Long version: This is all with the caveat that now that I've gotten the upgrade process to work, I haven't actually dug in and figured out exactly why it now works.

- Background: updating from 6.24 to 7.15.
- My forum vocab was completely standard as of the D6 install.
- Followed the usual steps per http://drupal.org/node/570162 ... immediately after the D7 update.php process completed, I always saw this issue. The really quick way to verify the problem is that even though there was now a field_data_taxonomy_forums table after the update, this table was completely empty. It should have had stuff in it.
- Somehow I accidentally ran the core update process on a copy of the 'live' database (i.e. NOT in maintenance mode, using my own theme, all modules enabled).
- And lo and behold, it worked.
- As I mentioned earlier, I have no idea why this is. If I didn't have a deadline staring me in the face, I'd dig deeper, but I'll leave it to some other intrepid Drupalist to figure it out.

* If this works for anybody else (or if you figure out more detail on why it works), then leave a message back here letting us know.

MichaelMartin’s picture

Version: 7.14 » 7.17

I got the problem after updating to 7.17.
Post #16, #17 and #18 brought a easy solution for me.
I checked admin/structure/types/manage/forum/fields
and found that there is the pre 'field_' defined.
So I jumped in the forum.module and changed there 'taxonomy_forums'
to 'field_taxonomy_forums'.
That was it.

waqasali’s picture

Version: 7.17 » 7.7

u need to upgrade drupal 7.7 here is link
http://drupal.org/node/1231826
i have drupal 7.7 there is no issue about forum.

grigorym’s picture

Version: 7.7 » 7.21

The same issue with clean installation of drupal commons into a shared hosting, which stopped installation several times because of cpu time limit.

1. Administration » Structure » Content types » Forum topic » Manage Fields showed NO taxonomy_forums field (some other was missing also, i don't remember exactly which, but I remember comparing it to the same version successfully installed on localhost).
2. Uninstalling Forum module and then installing it again recreated all field BUT taxonomy_forums.
3. I tried to create the field with: Label:Forums Machine name:taxonomy_forums Field type:Term reference Widget:Select list, but it always prefixed the machine name with 'field_', so it became 'field_taxonomy_forums'.
4. Eventually I created it with name 'field_taxonomy_forums', then opened phpMyAdmin, opened tables 'field_config' and 'field_config_instance', found 'field_taxonomy_forums' and updated it to 'taxonomy_forums', and that solved the problem.
5. By the way, enabling module Locale and then switching language to Russian translates the content type name 'Forums' into russian 'Форумы' (machine name remains the same, of course), however switching language back to english renames back all the fields BUT 'taxonomy_forums', which retains a russian name :).

Conclusion: I suspect a non-clean install which left the database in a corrupted state. However, why re-installing Forum Module does not solve the problem - that question evades me completely.

Hope it was helpful to somebody.

mrvinceo’s picture

Just to confirm #50; this fixed my issue of admin not being able to post to forum topics too (many thanks Gigorym).

I too was upgrading from D6 to D7 (7.23). I've performed the upgrade a few times now, and there are always some mangled tables at the end of it. The comments tables (field_data_comment_body etc.) often seem to come out either missing entirely or just empty, but can be put back together from

In my case I had the 'taxonomy upgrade extras' field in place of the taxonomy_forums term in the field_config_instance table (I had taxonomy_forums in my field_config table, but it wasn't being used by forum_topic type), so switching this back fixed the permissions issue. The widget in Forum topic also needed changing to a select list from autocomplete before it would allow me to add a topic to a forum.

In addition, I had to manually create field_data_taxonomy_forums, and the revisions equivalent from the 'forum' table.

After that, it seems to now work without any reported errors!

Cheers,
Paul

hanksterr7’s picture

Hi. Adding my experience.

Setting: upgrading d6 to d7.23. I also have domain access, organic groups, advanced forum and domain taxonomy in use.

I wanted to preserve all of my forums and containers (and associated taxonomy terms and relationships among them), and the nodes that were in each form or container.

Was getting the Undefined index: node in .../modules/forum/forum.module on line 175 error as described above.

Found that I did not have a taxonomy_forum field among the fields in the forum topic content type. No way to create one since the UI prefixes fields with field_ (as others have mentioned above)

The forum module php code hard codes the field name "taxonomy_forum" all over the place, so this field name needs to exist, and be a field in the Forum Topic content type.

I tried disabling Forum module and re-enabling it. Got primary key violation trying to write to the field_config table (this is where the fields are defined). That table did have a taxonomy_forum row, but it did not show in the list of available fields that could be added to the forum topic content type (not sure why not. would have made things easy if I could have added it to the content type).

I disabled Forum module, and then in phpMyAdmin, I flagged the field_config row as deleted=1 for the taxonomy_forum row.

Now when I try to enable the Forum module, I get mySQL errors saying can't create field_data_taxonomy_forums table since it already exists. I renamed field_data_taxonomy_forums and field_revision_taxonomy_forums tables to something else.

I also modified the taxonomy_vocabulary table, renaming "name" value in the row with name=Forums to something else. I think I was getting a primary key violation if I didn't do this too.

Now I am able to enable Forum module, and it comes up clean (i.e. Forums work. I can create forums and put forum topics into posts. But my old forums and containers are not there.).

Enabling Forum module creates a new row in field_config table for taxonomy_forum field name, and also creates new instances of field_data_taxonomy_forums and field_revision_taxonomy_forums tables. It also adds a new row to taxonomy_vocabulary table with name=Forums

To get all my forums and containers back, I did
update `taxonomy_term_data` set vid='14' where vid='1' <14 is the ID for the new Forum vocabulary, 1 is the ID for the old one>
The taxonomy_term_data table holds the links between taxonomy terms and the vocabulary they live in. I wanted my old terms to be in the newly created vocabulary that the Forum code was looking at. Doing this causes my old terms to show in the new taxonomy (admin/structure/taxonomy for the new Forum taxonomy) and causes the forums and containers to appear in the forum config page (admin/structure/forum). They also show in the forum selector when creating/editing a forum topic.

With the above steps, the forum page looks good. The # of posts and replies in the forum page also seems good. And the Domain Taxonomy module is doing a nice job of getting the forums and containers to show in the proper domains (you do need to reconfigure Domain Taxonomy after making the above changes to reference the new taxonomy, at admin/structure/domain - the taxonomy tab).

Clicking a forum is not yet showing the forum topics in a forum, so I'm not yet done, but close (and that may be due to the kludges I went through to migrate stuff out of table-prefixing done for Domain Access in d6 to the way things work in d7. I merged all the taxonomy terms into the single taxonomy_term_data table, changing tid values).

Also, enabling Advanced Forum is showing a nice forum listing, but the topic and reply counts are all zeros (inappropriately). Still working on that too.

Oh, and the above solved the "you are not authorized to create forum topic" messages :)

Oh, and for what it's worth, you can could try changing the value of "value" in the row in the "variable" table with name=forum_nav_vocabulary to get the forum code to look at your original vocabulary instead of the new one. I didn't try this.

Clearing cache and rebuilding permissions is always a good idea in this process.

Hope this helps someone :)
-- hanksterr7

mripra’s picture

I have the sane problem #32. I like to try to workaround but i am stuck on phpmyadmin comment " anything having to do with forums" can you please explain more about it...I am a new to this and i don;t know what to delete or how to delete them.
Thanks

mahpari’s picture

comment #50 fixed my issue! Thank you mrvinceo! yo saved my life :)
if anyone has issue, they can contact me.

Anonymous’s picture

Hi, just for the record

I have been running the same trouble. I installed the devel module, reinstalled just the forum module and voilá, problem gone (localized site going from D6 to D7, I am working now in the test server).

Maybe it's something related with localized sites and taxonomies names? (mine is a Spanish one).

PS. I have started posting trial messages in the forum and I find an odd messge under a field called "Taxonomy upgrade extras": "Debris left over after upgrade from Drupal 6"... Uh... completely lost here. Is it serious?

gianfrasoft’s picture

Issue summary: View changes

Comment #50 solved my problem too. It seemed installation of AF didn't create any row in field_config_instance table.

Thank you.

pintoian’s picture

Comment #50 resolved the issue with not being able to post even though user had permission to do so. the taxonomy field name has to be modified using PHPMyAdmin as describe in comment #50.

Anonymous’s picture

Im a noob on this and just installed the forum from a clean copy of drupal 7.34

and getting this error.

Notice: Undefined index: node in forum_menu_local_tasks_alter() (line 175 of /hermes/bosnaweb08a/b2575/ipg.dibbles/drupal-7.34/modules/forum/forum.module).
•Warning: Invalid argument supplied for foreach() in forum_menu_local_tasks_alter() (line 175 of /hermes/bosnaweb08a/b2575/ipg.dibbles/drupal-7.34/modules/forum/forum.module).

can anyone help me out please.

joshuautley’s picture

Why on Earth is the field "taxonomy_forums" used instead of "field_taxonomy_forums". And why are we not able to access the Forum container via Views as we can the individual topics?

For thus of us who apparently wrongly assumed we could delete the "taxonomy_forums" field and use our own taxonomy we have no way to restore a forum simply. By simply I mean we should not have to go into the db as described in #50 which didn't work in my instance.

I ended up just creating a view to replace the now broken core forum. I have not created a view to replace the containers portion as we only need one forum "general discussion" at this point.

Frustrated.

harriska2’s picture

Boy is this a nasty problem. First time in, what, 9 years with Drupal that I'm sort of stuck!

joshuautley’s picture

Goes to show we all get stuck sometimes. ( ;

edrokov’s picture

#50 helped me too.

caskraker’s picture

For me this problem occurred due to the memory problem mentioned in #39.
I disabled both Advanced Forum and Forum but forgot to de-install them under the de-install tab in modules. That way the DB never gets cleaned. After doing a proper de-install for both modules and enabling them again everything works fine.

Maybe someone almost as clumsy as me will benefit from this.

Cas

s13’s picture

#50 worked for me too. Thanks to @grigorym.

Edit:
Keep the forum module enabled for upgrade process. This will successfully upgrade the taxonomy reference field(Forums).

rosemary_qld’s picture

I have this exact problem after migrating my Drupal 6 site to Drupal 8. Is #50 from 3 years ago still the recommended solution? As I am not a programmer or expert, editing the database directly is something I'd rather avoid if possible. I had thought it might have been due to the Forum Access module I had in Drupal 6 though I uninstalled it before the migration. This is the only major problem since the migration.
Rosemary

mgifford’s picture

Version: 7.21 » 7.x-dev
Status: Postponed (maintainer needs more info) » Active

@s13 or @rosemary_qld can you give the exact process to reproduce this issue? We can then open this issue.

I assume this isn't just an issue in 7.21 so bumping it up.

#50 suspects this is based on "a non-clean install which left the database in a corrupted state."

Lots of details in #52 that weren't available in 30 when this was set as postponed.

There's enough other folks reproducing this that I'm setting this issue to active. So far it hasn't been reported in D8 so I assume it isn't an issue there.

rosemary_qld’s picture

Thanks for your reply.
I migrated my Drupal 6 site to Drupal 8 using Migrate and Migrate Drupal modules (I think they were the two but it was awhile ago now). It was from within Drupal 8 not from the command line.

Before the migration I disabled and uninstalled the Drupal 6 Forum Access module.

Now when I go to /forum I get
"No forums defined
You are not allowed to post new content in the forum"

Once I hit that page the logs show the following error messages (except I've removed the whole path to my site)

Notice: Undefined index: taxonomy_forums in Drupal\forum\Controller\ForumController->buildActionLinks() (line 298 of /core/modules/forum/src/Controller/ForumController.php).

Warning: Invalid argument supplied for foreach() in Drupal\forum\Controller\ForumController->buildActionLinks() (line 298 of /core/modules/forum/src/Controller/ForumController.php).

Otherwise the forums module operates normally in being able to create forums and containers - and the old Drupal 6 forum messages all migrated but not in the forum containers.

I've rebuilt permissions and done a lot of tests to my limited ability but it appears to be the same problem as described in posts above.

Thank you

larowlan’s picture

Hi Rosemary - can you check out comment #18?

If you have irc access, ping me in #drupal-au, I'm guessing from your username that we're in the same State in .au

I'm the forum maintainer and this one has been hanging around as an upgrade issue for some time.

Lee

rosemary_qld’s picture

Hi Lee
Thanks for your help. I just had a look at the Drupal 8 content types and chose forum and there's no taxonomy_forum listed and it doesn't appear if I try to add an existing field. Unfortunately I'm not a programmer and don't really understand the database structure in phpMyAdmin (on my Windows laptop which I use for development and testing) so am very limited in what I can do outside Drupal itself.
A couple of weeks ago as a test I deleted all my old forum messages that migrated from Drupal 6 to Drupal 8, uninstalled the Forum module and then tried to reinstall the Forum module and there was an error message it couldn't be re-installed (I think that related to two fields - probably taxonomy_forums and one other.)
Next week I could try that again and copy the exact message if that would help or if there are any exact steps I could try within phpMyAdmin to check. I've searched the database and couldn't find taxonomy_forums (but mightn't be searching by the right method).
Thanks
Rosemary

sea_drupal’s picture

My case is because below was mistakenly deleted:
Forums taxonomy_forums Term reference Select list edit delete

The #50 looks it is the right direction to do, but after I simply tried, somehow I got problem. Finally, I use CPanel to restore back to my originally version and works.

after restoration, I found:

below record ( was created by myself)
27 field_taxonomy_forums taxonomy_term_reference taxonomy 1 field_sql_storage field_sql_storage

has been changed to
26 taxonomy_forums taxonomy_term_reference taxonomy 1 field_sql_storage field_sql_storage

above is just to share something I have found

drupalfan2’s picture

Thank you, #50, pt 4 worked for me.