Skip to content

Commit

Permalink
app_generator: fix missing r for regex raw strings
Browse files Browse the repository at this point in the history
  • Loading branch information
Salamandar committed Sep 15, 2024
1 parent f51ef38 commit cc56a4b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app_generator/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ class GeneralInfos(FlaskForm):
app_id = StringField(
_("Application identifier (id)"),
description=_("Small caps and without spaces"),
validators=[DataRequired(), Regexp("[a-z_1-9]+.*(?<!_ynh)$")],
validators=[DataRequired(), Regexp(r"[a-z_1-9]+.*(?<!_ynh)$")],
render_kw={
"placeholder": "my_super_app",
},
Expand Down Expand Up @@ -139,7 +139,7 @@ class IntegrationInfos(FlaskForm):
# TODO : people shouldnt have to put the ~ynh1 ? This should be added automatically when rendering the app files ?
version = StringField(
_("Version"),
validators=[Regexp("\d{1,4}.\d{1,4}(.\d{1,4})?(.\d{1,4})?~ynh\d+")],
validators=[Regexp(r"\d{1,4}.\d{1,4}(.\d{1,4})?(.\d{1,4})?~ynh\d+")],
render_kw={"placeholder": "1.0~ynh1"},
)

Expand Down

0 comments on commit cc56a4b

Please sign in to comment.