Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
04ed6285
Commit
04ed6285
authored
Feb 13, 2016
by
Michal Čihař
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Compatibility with Python 3
Signed-off-by:
Michal Čihař
<
michal@cihar.com
>
parent
713b5427
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
2 deletions
+4
-2
weblate/lang/models.py
weblate/lang/models.py
+4
-2
No files found.
weblate/lang/models.py
View file @
04ed6285
...
...
@@ -20,6 +20,8 @@
from
__future__
import
unicode_literals
import
io
from
django.db
import
models
,
transaction
from
django.db.utils
import
OperationalError
from
django.utils.encoding
import
python_2_unicode_compatible
,
force_text
...
...
@@ -305,9 +307,9 @@ class LanguageManager(models.Manager):
Checks database language definitions with supplied ones.
"""
errors
=
[]
with
open
(
filename
)
as
handle
:
with
io
.
open
(
filename
)
as
handle
:
for
line
in
handle
:
line
=
line
.
strip
()
.
decode
(
'utf-8'
)
line
=
line
.
strip
()
parts
=
[
part
.
strip
()
for
part
in
line
.
split
(
','
)]
if
len
(
parts
)
!=
3
:
continue
...
...
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