Adding gif file to existing project

125 views
Skip to first unread message

Gary Roach

unread,
Oct 25, 2015, 10:51:13 PM10/25/15
to django...@googlegroups.com
Django 1.8
Python 3.4
Debian 8 (jessie) with kde desktop
Postresql 9.4
Apache2
venv environment setup
Ninja-IDE

The problem is that I am having trouble getting the image.gif file in
the project to show up in the IDE directory. The project tree is as follows:

.
├── archive
│ ├── archive
│ │ ├── __init__.py
│ │ ├── __pycache__
│ │ │ ├── __init__.cpython-34.pyc
│ │ │ ├── settings.cpython-34.pyc
│ │ │ ├── urls.cpython-34.pyc
│ │ │ └── wsgi.cpython-34.pyc
│ │ ├── settings.py
│ │ ├── urls.py
│ │ └── wsgi.py
│ ├── archive.nja
│ ├── db.sqlite3
│ ├── home
│ │ ├── admin.py
│ │ ├── __init__.py
│ │ ├── migrations
│ │ │ ├── __init__.py
│ │ │ └── __pycache__
│ │ │ └── __init__.cpython-34.pyc
│ │ ├── models.py
│ │ ├── __pycache__
│ │ │ ├── admin.cpython-34.pyc
│ │ │ ├── __init__.cpython-34.pyc
│ │ │ ├── models.cpython-34.pyc
│ │ │ └── views.cpython-34.pyc
│ │ ├── tests.py
│ │ └── views.py
│ ├── __init__.py
│ ├── main
│ │ ├── admin.py
│ │ ├── __init__.py
│ │ ├── migrations
│ │ │ ├── 0001_initial.py
│ │ │ ├── 0002_auto_20151019_1147.py
│ │ │ ├── 0003_auto_20151021_1441.py
│ │ │ ├── __init__.py
│ │ │ └── __pycache__
│ │ │ ├── 0001_initial.cpython-34.pyc
│ │ │ ├── 0002_auto_20151019_1147.cpython-34.pyc
│ │ │ ├── 0003_auto_20151021_1441.cpython-34.pyc
│ │ │ └── __init__.cpython-34.pyc
│ │ ├── models.py
│ │ ├── __pycache__
│ │ │ ├── admin.cpython-34.pyc
│ │ │ ├── __init__.cpython-34.pyc
│ │ │ └── models.cpython-34.pyc
│ │ ├── tests.py
│ │ └── views.py
│ ├── manage.py
│ ├── static
│ │ ├── home
│ │ │ ├── images
│ │ │ │ ├── django.gif
│ │ │ │ └── __init__.py
│ │ │ ├── __init__.py
│ │ │ └── style.css
│ │ └── __init__.py
│ └── templates
│ ├── admin
│ │ ├── base_site.html
│ │ └── __init__.py
│ ├── home
│ │ ├── index.html
│ │ └── __init__.py
│ └── __init__.py

You will notice that there is a django.gif file under static / home /
images. Unfortunately, this file does not show up in the IDE's tree.
I can't seem to figure out why. Below is the settings.py file for the
project. Have I done something wrong here.

_________________________________

# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
import os

BASE_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))


# Quick-start development settings - unsuitable for production
# See https://docs.djangoproject.com/en/1.8/howto/deployment/checklist/

# SECURITY WARNING: keep the secret key used in production secret!
SECRET_KEY = '$ey(n0ld$2v7x*4b+&a2n7!zt#+ub519+km9n=_4yz2f2kd&s5'

# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = True

ALLOWED_HOSTS = []


# Application definition

INSTALLED_APPS = (
'django.contrib.admin',
'django.contrib.auth',
'django.contrib.contenttypes',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'main',
'home',
)

MIDDLEWARE_CLASSES = (
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.common.CommonMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.auth.middleware.SessionAuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'django.middleware.security.SecurityMiddleware',
)

ROOT_URLCONF = 'archive.urls'

TEMPLATES = [
{
'BACKEND': 'django.template.backends.django.DjangoTemplates',
'DIRS': [os.path.join(BASE_DIR, 'templates')],
'APP_DIRS': True,
'OPTIONS': {
'context_processors': [
'django.template.context_processors.debug',
'django.template.context_processors.request',
'django.contrib.auth.context_processors.auth',
'django.contrib.messages.context_processors.messages',
],
},
},
]

WSGI_APPLICATION = 'archive.wsgi.application'


# Database
# https://docs.djangoproject.com/en/1.8/ref/settings/#databases

DATABASES = {
'default': {
'ENGINE': 'django.db.backends.postgresql_psycopg2',
'NAME': 'archivedb',
'USER': 'postgres',
'PASSWORD': 'qatip',
'HOST': '127.0.0.1',
'PORT': '',
}
}


# Internationalization
# https://docs.djangoproject.com/en/1.8/topics/i18n/

LANGUAGE_CODE = 'en-us'

TIME_ZONE = 'America/Los_Angeles'

USE_I18N = True

USE_L10N = True

USE_TZ = True


# Static files (CSS, JavaScript, Images)
# https://docs.djangoproject.com/en/1.8/howto/static-files/

STATIC_URL = '/static/'
STATIC_ROOT = os.path.join(BASE_DIR, 'static')

___________________________________

The IDE tree is identical to the one produced by tree -L 5 at the
command line with the exception of the missing gif file.

Your help will be sincerely appreciated.

Gary R.

Collin Anderson

unread,
Oct 27, 2015, 3:00:56 PM10/27/15
to Django users, gary71...@verizon.net
Hi Gary,

This sounds like an issue with Ninja-IDE. You could try asking on their mailing list: http://groups.google.com/group/ninja-ide/topics

Thanks,
Collin
Reply all
Reply to author
Forward
0 new messages