Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.
+5 votes
3.4k views
in Q2A Core by
edited by

I've installed a q2a plugin (Notification Pro) and after that I've launched a database initialization process required by it.

The db initialization was successful, but on the error_log I noticed this entry :

PHP Warning: session_start(): Cannot send session cache limiter - headers already sent (output started at /var/www/question2answer/qa-include/qa-db-install.php:1464) in /var/www/question2answer/qa-include/qa-app-users.php on line 150

Since I've already seen many complaints about this issue on q2a, I begin to think that it's a q2a bug.....

I'm using the default Snow theme, not modified, and I have no BOMs in my files.

The message is clear. A flush of bytes for the http response has already been done.

In fact, you can see at line 1464 of qa-db-install.php :

echo qa_html($text).str_repeat('    ', 1024)."<br><br>\n";
flush();
 

After that a "session start" seems to be executed :

if (!isset($_SESSION))
session_start();

($_SESSION still not set ?)

This should not happen, right ?

Well, I know I posted an error related to a plugin that is not free, but I think that this error happened so many times also in other situations.

So I decided to share it all the same.

I think that there are some paths in the q2a install process code that lead to this condition.

Bug ?

I think that, if a bug is confirmed, it could have a low priority : the installation process seems to be successful (at least in my case).

 

Q2A version: 1.6.2
related to an answer for: installation error
by
Any solution for this?

1 Answer

+1 vote
by
Similar, maybe this will fix the issue too: https://github.com/q2a/question2answer/issues/440

Add

     $userid = qa_get_logged_in_userid();

in the beginning of the file.
...