diff --git a/.github/PULL_REQUEST_TEMPLATE/code_review.md b/.github/PULL_REQUEST_TEMPLATE/code_review.md new file mode 100644 index 00000000..d88d2ae6 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE/code_review.md @@ -0,0 +1,11 @@ +## Docker +- [] spotcast integration load successfully +- [] spotcast sensor load successfully +- [] static uri request working +- [] search request working + +## Raspberry Pi +- [] spotcast integration load successfully +- [] spotcast sensor load successfully +- [] static uri request working +- [] search request working \ No newline at end of file diff --git a/Makefile b/Makefile index 7fd1b1aa..d68bcee8 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -__VERSION__ = "3.6.21" +__VERSION__ = "3.6.23" bump: bump2version --allow-dirty --current-version $(__VERSION__) patch Makefile custom_components/spotcast/manifest.json diff --git a/custom_components/spotcast/manifest.json b/custom_components/spotcast/manifest.json index b2768bca..a789856f 100644 --- a/custom_components/spotcast/manifest.json +++ b/custom_components/spotcast/manifest.json @@ -7,7 +7,7 @@ "requirements": [ "spotify_token==1.0.0" ], - "version": "v3.6.22", + "version": "v3.6.23", "dependencies": [ "spotify" ], diff --git a/custom_components/spotcast/spotcast_controller.py b/custom_components/spotcast/spotcast_controller.py index 28131e8c..6f7bd16b 100644 --- a/custom_components/spotcast/spotcast_controller.py +++ b/custom_components/spotcast/spotcast_controller.py @@ -206,6 +206,14 @@ def get_spotify_device_id(self, account, spotify_device_id, device_name, entity_ ) return spotify_device_id + + def _clean_uri(self, uri): + + # remove anything after ? + uri = uri.split("?")[0] + + return uri + def play( self, client, @@ -220,6 +228,10 @@ def play( uri, spotify_device_id, ) + + # clean uri + uri = self._clean_uri(uri) + if uri.find("show") > 0: show_episodes_info = client.show_episodes(uri) if show_episodes_info and len(show_episodes_info["items"]) > 0: diff --git a/setup.cfg b/setup.cfg index 10af6db7..cb81a57d 100644 --- a/setup.cfg +++ b/setup.cfg @@ -1,5 +1,5 @@ [bumpversion] -current_version = 3.6.21 +current_version = 3.6.23 [flake8] exclude = .venv,.git,.tox,docs,venv,bin,lib,deps,build