Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
Nuovo sito
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
16
Issues
16
List
Boards
Labels
Milestones
Merge Requests
2
Merge Requests
2
Analytics
Analytics
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gruppo Web
Nuovo sito
Commits
73e60439
Commit
73e60439
authored
Mar 25, 2020
by
Mattia Rizzolo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use the 'htmlmin' python module, instead of 'django-htmlmin'
Signed-off-by:
Mattia Rizzolo
<
mapreri@ubuntu.com
>
parent
8266ccb8
Pipeline
#191
passed with stage
in 0 seconds
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
1 deletion
+9
-1
setup.py
setup.py
+1
-1
uitwww/utils.py
uitwww/utils.py
+8
-0
No files found.
setup.py
View file @
73e60439
...
...
@@ -39,7 +39,7 @@ setuptools.setup(
"pyyaml"
,
"requests"
,
"toml"
,
"
django-
htmlmin"
,
"htmlmin"
,
],
packages
=
[
...
...
uitwww/utils.py
View file @
73e60439
...
...
@@ -22,6 +22,14 @@ from htmlmin import minify as html_minify
import
gunicorn.app.base
as
baseapp
# check that the html_minify we imported is a real function
# (i.e., no the html_minify that comes from django-htmlmin)
try
:
assert
callable
(
html_minify
)
except
AssertionError
:
raise
ImportError
(
"html_minify is not callable"
)
def
random_key
(
length
):
"""Generate a random key of a given length"""
rng
=
random
.
SystemRandom
()
# Use /dev/urandom
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment