Код: Выделить всё
reference = "file"
modifier = "read"
print(f"unknown pattern") # Should output "file.read" since modifier is not empty
modifier = ""
print(f"unknown modifier") # Should output "file" (not "file.") since modifier is empty
Подробнее здесь: https://stackoverflow.com/questions/790 ... ng-a-value