Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(0)  |  Derive(0)  |  Import(1)
validates the same as variable_name_validator, but may also include "-"

        def variable_name_and_dash_validator(value):
    """
    validates the same as variable_name_validator, but may also include "-"
    """
    if not VARIABLE_AND_DASH_REGEX_COMPILED.search(value):
        raise ValidationError('allowed characters: %s' % VARIABLE_AND_DASH_ALLOWED_CHARS)
        


src/d/p/dploi-server-HEAD/dploi_server/models.py   dploi-server(Download)
#-*- coding: utf-8 -*-
import random
from django.db import models
from dploi_server.utils.password import generate_password
from dploi_server.validation import variable_name_validator, variable_name_and_dash_validator