django-dynamic-link / dynamicLink /

import version
import os
import django
import sys

__version__ = VERSION = version.VERSION

    __doc__ = open(os.path.join(os.path.dirname(__file__), 'README_COPY')).read()
    __docformat__ = 'reStructuredText'
except IOError:
    __doc__ = 'For full documentation review the README file in your package or go to:'
    __docformat__ = 'txt'

def CKINST():
    print('I try to find errors for you!')
    djv = django.VERSION
    greatest_dlv = version.RELEASE_DJANGO[0]
    smalest_dlv = version.RELEASE_DJANGO[0]

    # find greatest and smallest possible django version for dynamic link
    for dlv in version.RELEASE_DJANGO:
        if greatest_dlv < dlv:
            greatest_dlv = dlv
        if smalest_dlv > dlv:
            smalest_dlv = dlv

    # check dynaic link dependences
    if djv < smalest_dlv:
        print('Django %s is not supported. With this version of dynamicLink, Django %s is recommended. Use "pip install django==%s.X"'\
        % (str(djv), str(greatest_dlv).strip('()').replace(' ', ''), str(greatest_dlv).strip('()').replace(' ', '') ))
    elif djv > greatest_dlv:
        print('This Version of dynamicLink (try: dynamicLink.VERSION) needs an older Django release (try: dynamicLink.RELEASE_DJANGO). \
        Try "pip install --upgrade django-dynamic-link" or use "pip install django==%s.X". '\
        % str(greatest_dlv).strip('()').replace(' ', ''))
    elif sys.version_info < version.PYTHON:
        print('dynamicLink depends on python %s or higher.' % str(version.PYTHON))
        print("No errors. All seems fine!")
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.