Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement fallback for Categories web-scraping #161

Merged
merged 1 commit into from May 1, 2019

Conversation

dagwieers
Copy link
Collaborator

@dagwieers dagwieers commented Apr 30, 2019

This PR includes:

  • Provide better Studio names
  • Fall back to hardcoded list of CATEGORIES if web-scraping fails
  • A hardcoded list of channels (both tv as radio)
  • Clean up of codebase to use both CHANNELS and CATEGORIES
  • Generate list of live streams from CHANNELS
  • Include unit test to ensure hard-coded CATEGORIES is identical to web-scraped list

We could now run our tests on an hourly basis to confirm that category-listing scraping works and our internal representation is correct and complete.

This implements #57 (comment)

PS The fallback mechanism does not support thumbnails. We could do that, but I expect the thumbnails to change more often.

@dagwieers dagwieers force-pushed the channels branch 4 times, most recently from 3822867 to 2f0f7dc Compare April 30, 2019 11:39
@dagwieers dagwieers changed the title Include list of channels and categories Implement fallback for Categories web-scraping Apr 30, 2019
@dagwieers dagwieers added the enhancement New feature or request label Apr 30, 2019
@dagwieers dagwieers mentioned this pull request Apr 30, 2019
@dagwieers dagwieers force-pushed the channels branch 2 times, most recently from eb20df4 to 21660c2 Compare April 30, 2019 11:52
@dagwieers
Copy link
Collaborator Author

@mediaminister @pietje666 Interested to hear opinions about this one.

@dagwieers
Copy link
Collaborator Author

dagwieers commented Apr 30, 2019

I discovered the unit tests were not actually testing anything (except a function call) as the used examples were invalid.

Update: Moved to #163

@dagwieers dagwieers force-pushed the channels branch 8 times, most recently from 80badd3 to 3dfa14f Compare May 1, 2019 01:02
This PR includes:
- Provide better Studio names
- Fall back to hardcoded list of CATEGORIES if web-scraping fails
- A hardcoded list of channels (both tv as radio)
- Clean up of codebase to use both CHANNELS and CATEGORIES
- Generate list of live streams from CHANNELS
- Include unit test to ensure hard-coded CATEGORIES is identical to
  web-scraped list
@mediaminister
Copy link
Collaborator

Very nice improvement. Okay to merge.

@dagwieers dagwieers merged commit bf7d5be into add-ons:master May 1, 2019
@dagwieers dagwieers added this to the 1.9.0 milestone May 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants