diff --git a/.ameba.yml b/.ameba.yml index 36d7c48f..96cbc8f0 100644 --- a/.ameba.yml +++ b/.ameba.yml @@ -20,13 +20,6 @@ Lint/ShadowingOuterLocalVar: Excluded: - src/invidious/helpers/tokens.cr -Lint/NotNil: - Enabled: false - -Lint/SpecFilename: - Excluded: - - spec/parsers_helper.cr - # # Style @@ -38,29 +31,6 @@ Style/RedundantBegin: Style/RedundantReturn: Enabled: false -Style/RedundantNext: - Enabled: false - -Style/ParenthesesAroundCondition: - Enabled: false - -# This requires a rewrite of most data structs (and their usage) in Invidious. -Naming/QueryBoolMethods: - Enabled: false - -Naming/AccessorMethodName: - Enabled: false - -Naming/BlockParameterName: - Enabled: false - -# Hides TODO comment warnings. -# -# Call `bin/ameba --only Documentation/DocumentationAdmonition` to -# list them -Documentation/DocumentationAdmonition: - Enabled: false - # # Metrics @@ -69,4 +39,50 @@ Documentation/DocumentationAdmonition: # Ignore function complexity (number of if/else & case/when branches) # For some functions that can hardly be simplified for now Metrics/CyclomaticComplexity: - Enabled: false + Excluded: + # get_about_info(ucid, locale) => [17/10] + - src/invidious/channels/about.cr + + # fetch_channel_community(ucid, continuation, ...) => [34/10] + - src/invidious/channels/community.cr + + # create_notification_stream(env, topics, connection_channel) => [14/10] + - src/invidious/helpers/helpers.cr:84:5 + + # get_index(plural_form, count) => [25/10] + - src/invidious/helpers/i18next.cr + + # call(context) => [18/10] + - src/invidious/helpers/static_file_handler.cr + + # show(env) => [38/10] + - src/invidious/routes/embed.cr + + # get_video_playback(env) => [45/10] + - src/invidious/routes/video_playback.cr + + # handle(env) => [40/10] + - src/invidious/routes/watch.cr + + # playlist_ajax(env) => [24/10] + - src/invidious/routes/playlists.cr + + # fetch_youtube_comments(id, cursor, ....) => [40/10] + # template_youtube_comments(comments, locale, ...) => [16/10] + # content_to_comment_html(content) => [14/10] + - src/invidious/comments.cr + + # to_json(locale, json) => [21/10] + # extract_video_info(video_id, ...) => [44/10] + # process_video_params(query, preferences) => [20/10] + - src/invidious/videos.cr + + + +#src/invidious/playlists.cr:327:5 +#[C] Metrics/CyclomaticComplexity: Cyclomatic complexity too high [19/10] +# fetch_playlist(plid : String) + +#src/invidious/playlists.cr:436:5 +#[C] Metrics/CyclomaticComplexity: Cyclomatic complexity too high [11/10] +# extract_playlist_videos(initial_data : Hash(String, JSON::Any)) diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 9ca09368..7a2c3760 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -6,7 +6,7 @@ docker/ @unixfox kubernetes/ @unixfox README.md @thefrenchghosty -config/config.example.yml @SamantazFox @unixfox +config/config.example.yml @thefrenchghosty @SamantazFox @unixfox scripts/ @syeopite shards.lock @syeopite diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 02bc3795..4c1a6330 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -10,10 +10,8 @@ assignees: ''