Skip to content

Commit

Permalink
api: add punctuation.whitespace to invalidChars
Browse files Browse the repository at this point in the history
  • Loading branch information
tschaume committed Aug 31, 2022
1 parent ec6fa1b commit 6278f38
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions mpcontribs-api/mpcontribs/api/__init__.py
Expand Up @@ -23,16 +23,15 @@
from mongoengine import ValidationError
from mongoengine.base.datastructures import BaseDict
from itsdangerous import URLSafeTimedSerializer
from string import punctuation
from string import punctuation, whitespace
from boltons.iterutils import remap, default_enter
from notebook.utils import url_path_join
from notebook.gateway.managers import GatewayClient
from requests.exceptions import ConnectionError


delimiter, max_depth = ".", 7 # = MAX_NESTING + 2 from client
invalidChars = set(punctuation.replace("*", ""))
invalidChars.add(" ")
invalidChars = set(punctuation.replace("*", "") + whitespace)
is_gunicorn = "gunicorn" in os.environ.get("SERVER_SOFTWARE", "")
SMTP_HOST, SMTP_PORT = os.environ.get("SMTP_SERVER", "localhost:587").split(":")

Expand Down

0 comments on commit 6278f38

Please sign in to comment.