Completely remove best default trending algorithm

pull/5042/head
Chocobozzz 2022-06-03 14:04:52 +02:00
parent c8fdfab0e3
commit 010382b603
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
7 changed files with 8 additions and 5 deletions

View File

@ -16,6 +16,7 @@
* Add `client.videos.resumable_upload.max_chunk_size` config option [#4857](https://github.com/Chocobozzz/PeerTube/pull/4857)
* Add `object_storage.upload_acl` config option [#4861](https://github.com/Chocobozzz/PeerTube/pull/4861)
* Add ability to set RTMP/RTMPS listening hostname using `rtmp.hostname`/`rtmps.hostname` and public RTMP/RTMPS hostname using `rtmp.public_hostname`/`rtmps.public_hostname`
* Removed `best` default trending algorithm. It is automatically used if using `hot` algorithm with a logged in user
### Docker

View File

@ -173,6 +173,10 @@ export class VideosListCommonPageComponent implements OnInit, OnDestroy, Disable
case 'most-liked':
return '-likes'
// We'll automatically apply "best" sort if using "hot" sort with a logged user
case 'best':
return '-hot'
default:
return '-' + algorithm as VideoSortField
}

View File

@ -181,7 +181,6 @@ trending:
interval_days: 7 # Compute trending videos for the last x days
algorithms:
enabled:
- 'best' # adaptation of Reddit's 'Best' algorithm (Hot minus History)
- 'hot' # adaptation of Reddit's 'Hot' algorithm
- 'most-viewed' # default, used initially by PeerTube as the trending page
- 'most-liked'

View File

@ -177,7 +177,6 @@ trending:
interval_days: 7 # Compute trending videos for the last x days
algorithms:
enabled:
- 'best' # adaptation of Reddit's 'Best' algorithm (Hot minus History)
- 'hot' # adaptation of Reddit's 'Hot' algorithm
- 'most-viewed' # default, used initially by PeerTube as the trending page
- 'most-liked'

View File

@ -165,7 +165,7 @@ describe('Test config API validators', function () {
trending: {
videos: {
algorithms: {
enabled: [ 'best', 'hot', 'most-viewed', 'most-liked' ],
enabled: [ 'hot', 'most-viewed', 'most-liked' ],
default: 'most-viewed'
}
}

View File

@ -367,7 +367,7 @@ const newCustomConfig: CustomConfig = {
trending: {
videos: {
algorithms: {
enabled: [ 'best', 'hot', 'most-viewed', 'most-liked' ],
enabled: [ 'hot', 'most-viewed', 'most-liked' ],
default: 'hot'
}
}

View File

@ -356,7 +356,7 @@ export class ConfigCommand extends AbstractCommand {
trending: {
videos: {
algorithms: {
enabled: [ 'best', 'hot', 'most-viewed', 'most-liked' ],
enabled: [ 'hot', 'most-viewed', 'most-liked' ],
default: 'hot'
}
}