Update profile valdiator

This commit is contained in:
SoftFever 2025-01-16 19:25:43 +08:00
parent f8698d89a4
commit 26a55a1267
2 changed files with 5 additions and 0 deletions

View File

@ -147,6 +147,8 @@ int main(int argc, char* argv[])
std::cout << "Validation failed" << std::endl;
return 1;
}
// Report loaded presets
std::cout << "Total loaded vendors: " << preset_bundle->vendors.size() << std::endl;
if (generate_user_preset) {
generate_custom_presets(preset_bundle, app_config);

View File

@ -4215,6 +4215,9 @@ bool PresetBundle::has_errors() const
for (auto& preset : filaments) {
if (!preset.is_system)
continue;
// It's per design that the Orca Filament Library can have the empty compatible_printers.
if(preset.vendor->name == PresetBundle::ORCA_FILAMENT_LIBRARY)
continue;
auto* compatible_printers = dynamic_cast<const ConfigOptionStrings*>(preset.config.option("compatible_printers"));
if (compatible_printers == nullptr || compatible_printers->values.empty()) {
has_errors = true;