clean up misc linting

This commit is contained in:
Jonathan Wren 2022-05-17 12:58:07 -07:00
parent 1a6afd9f4a
commit fabcd53c6f
6 changed files with 5 additions and 8 deletions

View file

@ -3,7 +3,6 @@ import getpass
import hashlib
import logging
import os
import sys
from typing import Callable
from typing import Optional

View file

@ -6,7 +6,6 @@ import datetime
import logging
import os
import re
import sys
from . import Entry
from . import time

View file

@ -1,7 +1,5 @@
# Copyright (C) 2012-2021 jrnl contributors
# License: https://www.gnu.org/licenses/gpl-3.0.html
import logging
import textwrap
from typing import Union

View file

@ -4,7 +4,6 @@
import os
import re
import sys
from .text_exporter import TextExporter

View file

@ -19,13 +19,16 @@ def create_password(journal_name: str) -> str:
print_msg(Message(MsgText.PasswordCanNotBeEmpty, MsgStyle.WARNING))
continue
elif pw == print_msg(Message(MsgText.PasswordConfirmEntry, MsgStyle.PROMPT), **kwargs):
elif pw == print_msg(
Message(MsgText.PasswordConfirmEntry, MsgStyle.PROMPT), **kwargs
):
break
print_msg(Message(MsgText.PasswordDidNotMatch, MsgStyle.ERROR))
if yesno(Message(MsgText.PasswordStoreInKeychain), default=True):
from .EncryptedJournal import set_keychain
set_keychain(journal_name, pw)
return pw

View file

@ -2,7 +2,6 @@
# License: https://www.gnu.org/licenses/gpl-3.0.html
import os
import sys
from . import Journal
from . import __version__
@ -32,7 +31,7 @@ def backup(filename, binary=False):
print_msg(
Message(
MsgText.BackupCreated, MsgStyle.NORMAL, {"filename": f"filename.backup"}
MsgText.BackupCreated, MsgStyle.NORMAL, {"filename": "filename.backup"}
)
)