Reproduction scenario on fresh CentOS 7 install:
1. Create a new project "project1" from the default project template
2. Install and enable the docman plugin
3. Create a new project using project1 as the template
Trace:
PHP message: PHP Fatal error: Uncaught Error: Call to a member function getGroupId() on null in /usr/share/tuleap/plugins/docman/include/Docman_ItemFactory.class.php:459
Stack trace:
#0 /usr/share/tuleap/plugins/docman/include/Docman_ItemFactory.class.php(641): Docman_ItemFactory->getItemSubTree(NULL, Object(PFUser), false, true, true)
#1 /usr/share/tuleap/plugins/docman/include/Docman_ItemFactory.class.php(1134): Docman_ItemFactory->getItemTree(NULL, Object(PFUser), false, true)
#2 /usr/share/tuleap/plugins/docman/include/Docman_Controller.class.php(157): Docman_ItemFactory->cloneItems(101, 103, Object(PFUser), Array, Array, '/var/lib/tuleap...')
#3 /usr/share/tuleap/plugins/docman/include/Docman_Controller.class.php(133): Docman_Controller->_cloneDocman(101, 103, Array)
#4 /usr/share/tuleap/plugins/docman/include/docmanPlugin.class.php(357): Docman_Controller->installDocman(Array, 103)
#5 /usr/share/tuleap/src/common/Event/EventManager.class.php(130): DocmanPlugin->installNewDocman(Array)
#6 /usr/share" while reading response header from upstream, client: 172.17.0.1, server: tuleap.test, request: "POST /project/register.php HTTP/2.0", upstream: "
fastcgi://127.0.0.1:9000", host: "tuleap.test", referrer: "
https://tuleap.test/project/register.php