Utils

Utility functions for Provider app.

smarter.apps.provider.utils.get_model_verification_for_type(provider_model, verification_type)[source]

Get the model verification for a specific type.

Return type:

ProviderModelVerification

smarter.apps.provider.utils.get_provider_verification_for_type(provider, verification_type)[source]

Get the provider verification for a specific type.

Return type:

ProviderVerification

smarter.apps.provider.utils.set_model_verification(provider_model_verification, is_successful, **kwargs)[source]

Set the model verification status.

Return type:

None

smarter.apps.provider.utils.set_provider_verification(provider_verification, is_successful, **kwargs)[source]

Set the provider verification status.

Return type:

None

smarter.apps.provider.utils.should_log(level)[source]

Check if logging should be done based on the waffle switch.

smarter.apps.provider.utils.test_web_page(url, test_str)[source]

Test a web page to see if it is valid.

Return type:

bool