#795: request_factory and environment_factory options point to files in the
bloodhound source directory
-----------------------+-----------------------
Reporter: rjollos | Owner: rjollos
Type: defect | Status: new
Priority: major | Milestone: Release 8
Component: installer | Version:
Keywords: |
-----------------------+-----------------------
It has been previously discussed on the
[http://markmail.org/message/k46vus3fcqucsbvd mailing list] that the
BloodhoundInstall steps should be modified. The intent of modifying the
instructions is to avoid installing the virtual environment and bloodhound
environment in a directory nested in the source directory (e.g. `apache-
bloodhound-0.7/installer/bloodhound/environments`). Among other things,
this will simplify the BloodhoundUpgrade steps.
Consider the following modified BloodhoundInstall steps:
{{{#!sh
$ tar xzvf apache-bloodhound-0.7.tar.gz
$ virtualenv --system-site-packages .
$ source bin/activate
$ cd apache-bloodhound-0.7/installer
$ pip install -r requirements.txt
$ python bloodhound_setup.py -d sqlite --admin-user=admin --admin-
password=admin
$ cd ../..
}}}
Everything works okay in that case. However we haven't succeeded in
installing the environment outside of the source directory.
We can do that by modifying the last two steps:
{{{#!sh
$ cd ../..
$ python apache-bloodhound-0.7/installer/bloodhound_setup.py -d sqlite
--admin-user=admin --admin-password=admin
}}}
Now the environment is installed to `bloodhound/environments/main`. On
starting `tracd` and navigating to `http://localhost:8000/main`, the
following error is seen:
{{{
Error
TracError: IOError: [Errno 2] No such file or directory
}}}
The options have the following values:
{{{#!ini
environment_factory =
/home/user/Workspace/bloodhound_multiproduct/multiproduct/hooks.py
request_factory =
/home/user/Workspace/bloodhound_multiproduct/multiproduct/hooks.py
}}}
The issue could be fixed in `bloodhound_setup.py`, but it really should
not be necessary to keep the installation source code around after the
install. We've created a directory layout:
{{{
apache-bloodhound-0.7
bin
bloodhound/environments
include
lib
local
}}}
and it should be possible to delete `apache-bloodhound-0.7` without any
harm. This will also help with BloodhoundUpgrade, since we won't have to
modify the two options on upgrade. We should figure out some way to have
the options refer to files within an egg, in the environment (or
global/inherited) directory or instead refer to component classes.
We should also raise a better error message when `environment_factory` or
`request_factory` are incorrect.
--
Ticket URL: <https://issues.apache.org/bloodhound/ticket/795>
Apache Bloodhound <https://issues.apache.org/bloodhound/>
The Apache Bloodhound issue tracker