aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild/modules/fs.py
diff options
context:
space:
mode:
Diffstat (limited to 'mesonbuild/modules/fs.py')
-rw-r--r--mesonbuild/modules/fs.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/mesonbuild/modules/fs.py b/mesonbuild/modules/fs.py
index fd1e99b..9594460 100644
--- a/mesonbuild/modules/fs.py
+++ b/mesonbuild/modules/fs.py
@@ -113,7 +113,7 @@ class FSModule(ExtensionModule):
def hash(self, state: 'ModuleState', args: T.Tuple[str, str], kwargs: T.Dict[str, T.Any]) -> ModuleReturnValue:
file = self._resolve_dir(state, args[0])
if not file.is_file():
- raise MesonException('{} is not a file and therefore cannot be hashed'.format(file))
+ raise MesonException(f'{file} is not a file and therefore cannot be hashed')
try:
h = hashlib.new(args[1])
except ValueError:
@@ -127,7 +127,7 @@ class FSModule(ExtensionModule):
def size(self, state: 'ModuleState', args: T.Tuple[str], kwargs: T.Dict[str, T.Any]) -> ModuleReturnValue:
file = self._resolve_dir(state, args[0])
if not file.is_file():
- raise MesonException('{} is not a file and therefore cannot be sized'.format(file))
+ raise MesonException(f'{file} is not a file and therefore cannot be sized')
try:
return ModuleReturnValue(file.stat().st_size, [])
except ValueError: