This repository was archived by the owner on Apr 20, 2025. It is now read-only.
File tree 3 files changed +4
-4
lines changed
3 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -178,7 +178,7 @@ def parse_cli(self) -> typing.Tuple[optparse.Values, typing.List[str]]:
178
178
def read_key (self , filename : str , keyform : str ) -> rsa .key .AbstractKey :
179
179
"""Reads a public or private key."""
180
180
181
- print ("Reading {} key from {}" . format (self .keyname , filename ), file = sys .stderr )
181
+ print ("Reading %s key from %s" % (self .keyname , filename ), file = sys .stderr )
182
182
with open (filename , "rb" ) as keyfile :
183
183
keydata = keyfile .read ()
184
184
Original file line number Diff line number Diff line change @@ -140,7 +140,7 @@ def _assert_format_exists(
140
140
except KeyError as ex :
141
141
formats = ", " .join (sorted (methods .keys ()))
142
142
raise ValueError (
143
- "Unsupported format: {!r} , try one of {}" . format (file_format , formats )
143
+ "Unsupported format: %r , try one of %s" % (file_format , formats )
144
144
) from ex
145
145
146
146
def save_pkcs1 (self , format : str = "PEM" ) -> bytes :
Original file line number Diff line number Diff line change @@ -67,7 +67,7 @@ def private_to_public() -> None:
67
67
# Read the input data
68
68
if cli .infilename :
69
69
print (
70
- "Reading private key from {} in {} format" . format (cli .infilename , cli .inform ),
70
+ "Reading private key from %s in %s format" % (cli .infilename , cli .inform ),
71
71
file = sys .stderr ,
72
72
)
73
73
with open (cli .infilename , "rb" ) as infile :
@@ -87,7 +87,7 @@ def private_to_public() -> None:
87
87
88
88
if cli .outfilename :
89
89
print (
90
- "Writing public key to {} in {} format" . format (cli .outfilename , cli .outform ),
90
+ "Writing public key to %s in %s format" % (cli .outfilename , cli .outform ),
91
91
file = sys .stderr ,
92
92
)
93
93
with open (cli .outfilename , "wb" ) as outfile :
You can’t perform that action at this time.
0 commit comments