First time here? Check out the FAQ!
0

Why do I get errors with "python manage.py makemessages"?

python manage.py makemessages CommandError: This script should be run from the Django Git tree or your project or app tree. If you did indeed run it from the Git checkout or your project or application, maybe you are just missing the conf/locale (in the django tree) or locale (for project and application) directory? It is not created automatically, you have to create it by hand if you want to enable i18n for your project or application.

updated 2013-07-27 05:05:37 -0600
This post is a wiki. Anyone with karma >100 is welcome to improve it.
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

2 Answers

0

Firstly - for Askbot please use command jinja2_makemessages (it's the same, but works with our templates).

The error that you've shown indicates that possibly your python environment has not been initiated properly or you might be lacking the project files such as settings.py, __init__.py, all the files made by the startproject command (or in the case of askbot - with askbot-setup command).

Evgeny's avatar
13.2k
Evgeny
answered 2013-07-28 21:37:03 -0600
edit flag offensive 0 remove flag delete link

Comments

@Evgeny Could you explain more, I'm running the same issue here, and I don't have idea from where to start to solve this.

Mustafa's avatar Mustafa (2013-08-10 12:37:44 -0600) edit
add a comment see more comments
0

I was having the same issue here, and I found that I should run this command in askbot main directory where is 'locale' directory located, in my case I have two directories

/apache/askbot

The main app directory contains the 'templates' and 'locale' directories...etc. and

/apache/http/app

Where 'static' directory located and the manage.py and settings.py files

So in my case to make the following commands work correctly

$ python manage.py jinja2_makemessages 
$ python manage.py compilemessages 
$ python manage.py makemessages

simply do the following

$ cd /apache/askbot
$ python ../http/app/manage.py compilemessages
Mustafa's avatar
48
Mustafa
answered 2013-08-10 13:08:44 -0600
edit flag offensive 0 remove flag delete link

Comments

Work like a charm, thank you very much!.

rallende's avatar rallende (2014-05-04 01:09:37 -0600) edit
add a comment see more comments