mirror of
https://github.com/google-deepmind/alphafold3.git
synced 2025-10-20 13:23:47 +08:00
Validate that a non-loop CIF key has only a single value
PiperOrigin-RevId: 802455341 Change-Id: I089c4e0a9a52862b5eba6d26023184a4a34efc96
This commit is contained in:
committed by
Copybara-Service
parent
7b816f4035
commit
0ea324ce74
@ -443,6 +443,10 @@ absl::StatusOr<CifDict> CifDict::FromString(absl::string_view cif_string) {
|
||||
}
|
||||
if (key.empty()) {
|
||||
key = token;
|
||||
if (!absl::StartsWith(key, "_")) {
|
||||
return absl::InvalidArgumentError(
|
||||
absl::StrCat("Key '", key, "' does not start with an underscore."));
|
||||
}
|
||||
} else {
|
||||
cif[key].emplace_back(token);
|
||||
key = "";
|
||||
|
Reference in New Issue
Block a user