Alexa Media Player ADDED - #421 - Added some test Notifications. (HA restart targetted notification)

This commit is contained in:
ccostan
2020-05-03 16:23:17 -04:00
parent 0c8345389b
commit 457bc114e8
41 changed files with 315 additions and 126 deletions

View File

@@ -30,7 +30,9 @@ async def get_info_md_content(repository):
info = info.content.replace("<svg", "<disabled").replace("</svg", "</disabled")
return render_template(info, repository)
except (AIOGitHubException, Exception): # pylint: disable=broad-except
return ""
if repository.hacs.action:
raise HacsException("No info file found")
return ""
async def get_repository(session, token, repository_full_name):
@@ -84,11 +86,19 @@ async def get_integration_manifest(repository):
repository.data.manifest_name = manifest["name"]
repository.data.homeassistant = manifest.get("homeassistant")
if repository.hacs.action:
if manifest.get("documentation") is None:
raise HacsException("manifest.json is missing documentation")
if manifest.get("homeassistant") is not None:
raise HacsException(
"The homeassistant key in manifest.json is no longer valid"
)
# Set local path
repository.content.path.local = repository.localpath
except KeyError as exception:
raise HacsException(f"Missing expected key {exception} in 'manifest.json'")
raise HacsException(f"Missing expected key {exception} in '{manifest_path}'")
def find_file_name(repository):