Re: tree.io installation with django

1,278 views
Skip to first unread message

Cal Leeming [Simplicity Media Ltd]

unread,
Sep 11, 2012, 6:40:54 AM9/11/12
to django...@googlegroups.com
Looks like an incompatible version of Django perhaps (first glance).

Alternatively, just patch it yourself based on the error given:

@@@
django.core.exceptions.ImproperlyConfigured: You're using the staticfiles app without having set the STATIC_ROOT setting.
@@@


Cal

On Tue, Sep 11, 2012 at 7:22 AM, Fabian Weiss <fabian...@googlemail.com> wrote:
I am using Debian and want to use treeio with my Apache. So I was working with this tutorial: http://fuckyeahcoding.wordpress.com/2011/12/20/install-tree-io-on-ubuntu-with-apache/
But the instructions "make" and "make install" didnt work.. Instead I used the 'python manage.py update_ve' and './bin/patch_' from the INSTALL Howto. So this is the result:

Next stept: root@iss1:/srv/http/de.immersight.project/treeio# ./bin/patch
patching file db/models/fields/related.py

I created a MySQL database, user and password. But where to configure treeio for this? Where shall I enter this informations??

So this is the result of the next step:

I am not sure and dont understand much of it, but for me it seems there already went something wrong..
The tree.io community is not so active, but maybe somebody here can give me a hint!

Thx alot!!

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/wm6J2Ces9BUJ.
To post to this group, send email to django...@googlegroups.com.
To unsubscribe from this group, send email to django-users...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

Fabian Weiss

unread,
Sep 12, 2012, 2:07:54 AM9/12/12
to django...@googlegroups.com
THX alot for your help Cal! Does that STATIC stuff has something to do with the fact that I am using an Apache virtual host?
But that link you gave me is very complicated! Sorry, but I dont understand :( 
What do I have to insert there?
Shall I add now STATICFILES_DIRS = ( "../static") ?

Cal Leeming [Simplicity Media Ltd]

unread,
Sep 12, 2012, 6:14:27 AM9/12/12
to django...@googlegroups.com
Hmm - this should really just work out of the box, but looking at the docs, it doesn't give you much information about running wsgi/fcgi etc.

Try this;

Change this line:
STATIC_DOC_ROOT = path.join(PROJECT_ROOT, 'static')

To this:
STATICFILES_DIRS = ( path.join(PROJECT_ROOT, 'static'), )

That should work i think.

Cal

To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/jS4L0ShvuYYJ.

Fabian Weiss

unread,
Sep 12, 2012, 2:52:48 PM9/12/12
to django...@googlegroups.com
Hi Cal! :)

THX for you reply, but I need more informations! I changed the line you said in settings.py, but what shall I do know? Again python manage.py update_ve and ./bin/patch??
I tried again the last step:

python manage.py installdb
Traceback (most recent call last):
  File "manage.py", line 74, in <module>
    import settings
  File "/srv/http/de.immersight.project/treeio/settings.py", line 59, in <module>
    MEDIA_ROOT = path.join(STATIC_DOC_ROOT, 'media/')
NameError: name 'STATIC_DOC_ROOT' is not defined

when I reload the apache I have still 500 internal error. Here is the errorlog:

tail ../logs/errorlog 
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24] SyntaxError: invalid syntax
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24] mod_wsgi (pid=17796): Target WSGI script '/srv/http/de.immersight.project/treeio/wsgi' cannot be loaded as Python module.
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24] mod_wsgi (pid=17796): Exception occurred processing WSGI script '/srv/http/de.immersight.project/treeio/wsgi'.
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24] Traceback (most recent call last):
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24]   File "/srv/http/de.immersight.project/treeio/wsgi", line 9, in <module>
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24]     import django.core.handlers.wsgi
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24]   File "/usr/local/lib/python3.2/dist-packages/django/core/handlers/wsgi.py", line 131
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24]     path_info = force_unicode(environ.get('PATH_INFO', u'/'))
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24]                                                           ^
[Wed Sep 12 20:46:23 2012] [error] [client 109.193.24.24] SyntaxError: invalid syntax

I really urgently have to set up this system :(
Would be great if I can accomplish this!! Thanks alot for your help!
Greetings Fabian




Am Mittwoch, 12. September 2012 12:14:51 UTC+2 schrieb Cal Leeming [Simplicity Media Ltd]:
Hmm - this should really just work out of the box, but looking at the docs, it doesn't give you much information about running wsgi/fcgi etc.

Try this;

Change this line:...

Cal Leeming [Simplicity Media Ltd]

unread,
Sep 12, 2012, 3:06:04 PM9/12/12
to django...@googlegroups.com
I think this looks like an incompatible Django version to be honest, coupled with some other weird/wonderful problems.

The invalid syntax thing is also a bit odd, as it looks valid to me.

My advice would be to start again from scratch with the installation tutorial, and see if you can get any further - 

Cal

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/django-users/-/6aEUH98wPG0J.

Fabian Weiss

unread,
Sep 15, 2012, 4:41:06 PM9/15/12
to django...@googlegroups.com
And it works! :) 

I tried again all I could find in the net for treeio, but nothing works :(
How can I totally remove all my steps? Is it just to delete the directories? Or is there something to do in a database?

Maybe I have a version of django which is too new? It is 1.4.1

Nick Apostolakis

unread,
Sep 15, 2012, 5:31:42 PM9/15/12
to django...@googlegroups.com


On Sat, Sep 15, 2012 at 11:41 PM, Fabian Weiss <fabian...@googlemail.com> wrote:
And it works! :) 

I tried again all I could find in the net for treeio, but nothing works :(
How can I totally remove all my steps? Is it just to delete the directories? Or is there something to do in a database?

Maybe I have a version of django which is too new? It is 1.4.1



Why don't you use django 1.3 as it is described in the requirements file?
Thats a simple way to see if you problems stem from django version incompatibility

--
-----------------------------------------------------------------------
                    Nick Apostolakis
email:nick...@oncrete.gr
Web Site: http://nick.oncrete.gr
-----------------------------------------------------------------------

Fabian Weiss

unread,
Sep 16, 2012, 5:01:41 AM9/16/12
to django...@googlegroups.com, nick...@oncrete.gr
I would like to do, but my Debian Distribution just offers 1.4! Maybe I can install another one, but than I probably get Version missmatch.. :/


Am Samstag, 15. September 2012 23:32:06 UTC+2 schrieb Nick Apostolakis:


On Sat, Sep 15, 2012 at 11:41 PM, Fabian Weiss <fabian...@googlemail.com> wrote:
And it works! :) 

I tried again all I could find in the net for treeio, but nothing works :(
How can I totally remove all my steps? Is it just to delete the directories? Or is there something to do in a database?

Maybe I have a version of django which is too new? It is 1.4.1



Why don't you use django 1.3 as it is described in the requirements file?
Thats a simple way to see if you problems stem from django version incompatibility

--
-----------------------------------------------------------------------
                    Nick Apostolakis

Nick Apostolakis

unread,
Sep 16, 2012, 7:54:28 AM9/16/12
to django...@googlegroups.com
On 16/09/2012 12:01 μμ, Fabian Weiss wrote:
> I would like to do, but my Debian Distribution just offers 1.4! Maybe I can
> install another one, but than I probably get Version missmatch.. :/
>
>
You could install any version you like through the use of pip an virtual env
Check it out. Its quite simple and it is a very valuable technique


--
--------------------------------------------------------------
Nick Apostolakis
e-mail: nick...@oncrete.gr

Fabian Weiss

unread,
Sep 16, 2012, 4:53:49 PM9/16/12
to django...@googlegroups.com, nick...@oncrete.gr
Allright, I didnt know that! So here are the requirments! I deinstalled django debian packet and used pip. Works very well! But some of the requiered software is also available and installed on my system through APT! For example python-dateutil. What to do? Deinstall it and install it with pip??

I did like this "pip install -U Django==1.3" for the hole list:

Django==1.3
Pygments==1.3.1
south
jinja2==2.5.2
coffin
hashlib
PIL
html5lib==0.90
oauth2
whoosh
python-dateutil
django-dajax
django-dajaxice
django-piston==0.2.2
django-simple-captcha
unidecode
django-websocket
docutils
simplejson
sphinx
johnny-cache
django-pandora

Than I startet again from scratch. I created the treeio dir and went into this. I started the configure as root, works well. Then the patch, and this time it made trouble!
Datei oder Verzeichnis nicht gefunden = File or directory not found.

As usual I just continued with "python manage.py installdb" and "python manage.py loaddata data.json" and as usual I got the same error: "django.core.exceptions.ImproperlyConfigured: You're using the staticfiles app without having set the STATIC_ROOT setting."

Sorry, but: I STILL DONT KNOW WHERE TO ENTER MY MYSQL INFORMATION!???

But, this time I can see something!!! :) http://project.immersight.de/
But what I now wrong??

Mike Dewhirst

unread,
Sep 16, 2012, 8:02:35 PM9/16/12
to django...@googlegroups.com
On 16/09/2012 6:41am, Fabian Weiss wrote:
> The invalid syntax thing is also a bit odd, as it looks valid to me.
>

I haven't followed this thread but whenever I get an invalid syntax
error with valid syntax it is usually a problem with an earlier line. In
my cases it is often a missing comma or mis-matched parenthesis.


Fabian Weiss

unread,
Sep 17, 2012, 1:35:27 AM9/17/12
to django...@googlegroups.com
Well, I really dont know what to do :( All I can show you is the Apache log:

[Sun Sep 16 21:45:58 2012] [error] /usr/local/lib/python2.7/dist-packages/jinja2/__init__.py:31: UserWarning: Module hashlib was already imported from /usr/lib/python2.7/hashlib.pyc, but /usr/local/lib/python2.7/dist-packages is being added to sys.path
[Sun Sep 16 21:45:58 2012] [error]   __version__ = __import__('pkg_resources') \\

Mike Dewhirst

unread,
Sep 17, 2012, 1:53:10 AM9/17/12
to django...@googlegroups.com
On 17/09/2012 3:35pm, Fabian Weiss wrote:
> Well, I really dont know what to do :( All I can show you is the Apache log:
>
> [Sun Sep 16 21:45:58 2012] [error]
> /usr/local/lib/python2.7/dist-packages/jinja2/__init__.py:31:
> UserWarning: Module hashlib was already imported from
> /usr/lib/python2.7/hashlib.pyc, but
> /usr/local/lib/python2.7/dist-packages is being added to sys.path

Things being incorrectly added to sys.path should only be a problem if
there is a difference in version AND the position in the sys.path list
means they get imported ahead of the correct version. Otherwise it
doesn't matter apart from being inelegant.

> [Sun Sep 16 21:45:58 2012] [error] __version__ =
> __import__('pkg_resources') \\

I'm out of my depth on this.

Have you checked every line in the code ahead of the line which
generated the syntax error?

>
>
> Am Montag, 17. September 2012 01:59:09 UTC+2 schrieb Mike Dewhirst:
>
> On 16/09/2012 6:41am, Fabian Weiss wrote:
> > The invalid syntax thing is also a bit odd, as it looks valid to me.
> >
>
> I haven't followed this thread but whenever I get an invalid syntax
> error with valid syntax it is usually a problem with an earlier
> line. In
> my cases it is often a missing comma or mis-matched parenthesis.
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "Django users" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/django-users/-/UUfBUZPpXcgJ.

Nick Apostolakis

unread,
Sep 17, 2012, 9:22:05 AM9/17/12
to django...@googlegroups.com
when you use virtualenv your system configuration is bypassed altogether.
I have installed tree.io three days ago (after seeing your first email
to the list) using the source code and the instructions at github

https://github.com/treeio/treeio


I should say that you need to follow the instructions closely otherwise
you will get errors.

Fabian Weiss

unread,
Sep 18, 2012, 1:41:22 AM9/18/12
to django...@googlegroups.com, nick...@oncrete.gr
WOHOOOOO! THX Guys! :)
This worked! Why is the INSTALL of the tarball other than the instruction on git???
So now it works and I am happy! :)

Fabian Weiss

unread,
Sep 18, 2012, 1:47:11 AM9/18/12
to django...@googlegroups.com, nick...@oncrete.gr
Just I cannot login! :-D
admin/admin doesn't work.. :/
Does it has something to do with settings.py?

ADMINS = (
    # ('Your Name', 'your_...@domain.com'),
)
 
Should I done this before I start installation??

Nick Apostolakis

unread,
Sep 18, 2012, 1:53:42 PM9/18/12
to django...@googlegroups.com
during my installation it failed to install the initial mysql data
so i have done a manual import of mysql initial data using this command

mysql -u treeiouser -p< sql/mysql-treeio-current.sql treeio

maybe your problem is the same

Fabian Weiss

unread,
Sep 18, 2012, 3:33:18 PM9/18/12
to django...@googlegroups.com, nick...@oncrete.gr
YES! I got this error: http://snipurl.com/251cbjb
After doing your MySQL Code it WORKS!! :)
THX alot!

Nick Apostolakis

unread,
Sep 19, 2012, 1:22:53 PM9/19/12
to django...@googlegroups.com
On 18/09/2012 10:33 οΏ½οΏ½, Fabian Weiss wrote:
> YES! I got this error: http://snipurl.com/251cbjb
> After doing your MySQL Code it WORKS!! :)
> THX alot!
>
>
>

You are welcome :)

Fabian Weiss

unread,
Sep 20, 2012, 1:31:56 AM9/20/12
to django...@googlegroups.com, nick...@oncrete.gr
The trouble is still not over :( :(
When I click on Calendar or Projects I get the error in the top: "Something went wrong..."
Exactly because of these two features I installed the software.. :/
So I remove the # in the link to activate the debug output and I get: http://snipurl.com/251x8oz
(1054, "Unknown column 'projects_task.depends_id' in 'field list'")
Does somebody know a solution?

Nick Apostolakis

unread,
Sep 20, 2012, 2:32:17 PM9/20/12
to django...@googlegroups.com
On 20/09/2012 08:31 πμ, Fabian Weiss wrote:
> The trouble is still not over :( :(
> When I click on Calendar or Projects I get the error in the top: "Something
> went wrong..."
> Exactly because of these two features I installed the software.. :/
> So I remove the # in the link to activate the debug output and I
> get: http://snipurl.com/251x8oz
> (1054, "Unknown column 'projects_task.depends_id' in 'field list'")
> Does somebody know a solution?
>
>
I think that there is a south migration you have to perform
try python manage.py migrate projects

Fabian Weiss

unread,
Sep 20, 2012, 3:36:47 PM9/20/12
to django...@googlegroups.com, nick...@oncrete.gr
And YES again! :) That solved it! 
No alomost everything works! :)
Just when I go to /calendar/settings/integration I see: "available resources: loading.." Is it normal?

Greetings and THX :)

Nick Apostolakis

unread,
Sep 20, 2012, 4:06:36 PM9/20/12
to django...@googlegroups.com
On 20/09/2012 10:36 οΏ½οΏ½, Fabian Weiss wrote:
> And YES again! :) That solved it!
> No alomost everything works! :)
> Just when I go to /calendar/settings/integration I see: "available
> resources: loading.." Is it normal?
>
> Greetings and THX :)
>
>
You are welcome.
The calendar app as far as I understand is supposed to be able to sync
with google cal.
That however has not worked for me, I think that this feature is broken.
There was another glitch with the helpdesk module although I didn't try
enough to resolve that.
I have installed tree.io mostly for the project management, and helpdesk
support if it supported anonymous user's ticket creation of something
like that.
I think that the app does not support anonymous helpdesk, so I will use
it for project management only for the moment.
It works reasonably well, although I have not managed yet to isolate my
users from viewing each others projects.
I admit that I have dedicated only a small amount of time in the user
separation issue, since my installation has only a few trusted users,
so project isolation is not a must have.

I am glad you have a working installation...

Nick Apostolakos

unread,
Sep 16, 2012, 5:54:42 AM9/16/12
to Fabian Weiss, django...@googlegroups.com
Just use pip and virtualenv. You
don have to lock yourself in your distro packaged django

Fabian Weiss <fabian...@googlemail.com> wrote:

>I would like to do, but my Debian Distribution just offers 1.4! Maybe I
>can
>install another one, but than I probably get Version missmatch.. :/
>
>Am Samstag, 15. September 2012 23:32:06 UTC+2 schrieb Nick Apostolakis:
>>
>>
>>
>> On Sat, Sep 15, 2012 at 11:41 PM, Fabian Weiss
><fabian...@googlemail.com<javascript:>
>> > wrote:
>>
>>> I do so! I tried now this one:
>>>
>http://blog.stannard.net.au/2010/12/11/installing-django-with-apache-and-mod_wsgi-on-ubuntu-10-04/
>>> And it works! :)
>>> http://project.immersight.de/
>>>
>>> I tried again all I could find in the net for treeio, but nothing
>works :(
>>> How can I totally remove all my steps? Is it just to delete the
>>> directories? Or is there something to do in a database?
>>>
>>> Maybe I have a version of django which is too new? It is 1.4.1
>>>
>>>
>http://nopaste.immersight.de/?34b6a29be67dd853#dvMCsmIWwYZUWV2qKMFxGLMI4pq+O3PiPy2iHAp3ZzQ=
>>>
>>>
>>>
>> Why don't you use django 1.3 as it is described in the requirements
>file?
>> Thats a simple way to see if you problems stem from django version
>> incompatibility
>>
>> --
>>
>-----------------------------------------------------------------------
>> Nick Apostolakis
>> email:n...@oncrete.gr <javascript:>
>> Web Site: http://nick.oncrete.gr
>>
>-----------------------------------------------------------------------
>>


--
Sent from my Android phone with K-9 Mail. Please excuse my brevity.
Reply all
Reply to author
Forward
0 new messages