Skip to content

Commit

Permalink
Merge pull request #99 from abg/feature/avoid_unicode_literals
Browse files Browse the repository at this point in the history
Remove unicode_literals imports from dbsake.cli
  • Loading branch information
abg committed Oct 10, 2016
2 parents 6ac3b8d + 1300bc3 commit 6e3618b
Show file tree
Hide file tree
Showing 16 changed files with 9 additions and 30 deletions.
8 changes: 8 additions & 0 deletions HISTORY.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@
History
=======

2.1.1 (unreleased)
------------------

Bugs fixed:

* Remove unicode_literals usage in cli to avoid noisy warnings from click
(Issue #96)

2.1.0 (2015-01-28)
------------------

Expand Down
2 changes: 0 additions & 2 deletions dbsake/cli/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
Main dbsake cli entrypoint
"""
from __future__ import unicode_literals

import logging
import sys

Expand Down
2 changes: 0 additions & 2 deletions dbsake/cli/cmd/frm.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
Dump schema from MySQL .frm files
"""
from __future__ import unicode_literals

import sys

import click
Expand Down
2 changes: 0 additions & 2 deletions dbsake/cli/cmd/fs.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@
Commands for interacting with the local filesystem
"""
from __future__ import unicode_literals

import sys

import click
Expand Down
2 changes: 0 additions & 2 deletions dbsake/cli/cmd/mycnf.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
MySQL option file utilitie
"""
from __future__ import unicode_literals

import sys

import click
Expand Down
2 changes: 0 additions & 2 deletions dbsake/cli/cmd/sandbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
Command interface to create isolated MySQL "sandbox" instances
"""
from __future__ import unicode_literals

import os
import sys

Expand Down
2 changes: 0 additions & 2 deletions dbsake/cli/cmd/sieve.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@
Advanced filtering of mysqldump backup files
"""
from __future__ import unicode_literals

import errno
import signal
import sys
Expand Down
1 change: 0 additions & 1 deletion dbsake/cli/cmd/unpack.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
"""
from __future__ import print_function
from __future__ import unicode_literals

import sys

Expand Down
4 changes: 1 addition & 3 deletions tests/frmdump/test_frm.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from __future__ import print_function

import codecs
Expand Down Expand Up @@ -45,14 +44,13 @@ def test_frm_decode(frm_path, expected_sql):


def test_frm_tablename():
sample = 'Настройки'
sample = u'Настройки'
expected_encoding = b'@T0@g0@x0@y0@w0@u0@p0@q0@o0'

result = tablename.encode(sample)

assert result == expected_encoding

print("result => %r" % (result, ))
orig = tablename.decode(result)

assert orig == sample
2 changes: 0 additions & 2 deletions tests/test_dbsake.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Test dbsake cli
"""
from __future__ import unicode_literals

from click.testing import CliRunner

import dbsake
Expand Down
2 changes: 0 additions & 2 deletions tests/test_fs.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Test dbsake sandbox
"""
from __future__ import unicode_literals

from click.testing import CliRunner

from dbsake.cli.cmd import fs as fs_cli
Expand Down
2 changes: 0 additions & 2 deletions tests/test_pycompat.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Test dbsake.pycompat
"""
from __future__ import unicode_literals

import errno
import os
import shutil
Expand Down
2 changes: 0 additions & 2 deletions tests/test_sandbox.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Test dbsake sandbox
"""
from __future__ import unicode_literals

import os
import tarfile

Expand Down
2 changes: 0 additions & 2 deletions tests/test_sieve.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Test dbsake cli
"""
from __future__ import unicode_literals

import os

from click.testing import CliRunner
Expand Down
2 changes: 0 additions & 2 deletions tests/test_upgrademycnf.py
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
"""
Test dbsake sandbox
"""
from __future__ import unicode_literals

import os

from click.testing import CliRunner
Expand Down
2 changes: 0 additions & 2 deletions tests/test_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
Test dbsake.util.compression
"""
from __future__ import unicode_literals

from dbsake.util import compression


Expand Down

0 comments on commit 6e3618b

Please sign in to comment.