Skip to content

Commit

Permalink
Merge branch 'master' into Universal-Omega-patch-3
Browse files Browse the repository at this point in the history
  • Loading branch information
Universal-Omega authored May 17, 2024
2 parents 907cbea + b58a5cb commit 4b33ebf
Show file tree
Hide file tree
Showing 25 changed files with 420 additions and 134 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/backport.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
)
steps:
- name: Backport
uses: sqren/backport-github-action@v8.9.7
uses: sqren/backport-github-action@v9.5.1
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
auto_backport_label_prefix: backport-to-
6 changes: 3 additions & 3 deletions .github/workflows/codacy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,11 @@ jobs:
steps:
# Checkout the repository to the GitHub Actions runner
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

# Execute Codacy Analysis CLI and generate a SARIF output with the security issues identified during the analysis
- name: Run Codacy Analysis CLI
uses: codacy/codacy-analysis-cli-action@d43127fe38d20c527dc1951ae5aea23148bab738
uses: codacy/codacy-analysis-cli-action@3ff8e64eb4b714c4bee91b7b4eea31c6fc2c4f93
with:
# Check https://github.com/codacy/codacy-analysis-cli#project-token to get your project token from your Codacy repository
# You can also omit the token and run the tools that support default configurations
Expand All @@ -55,6 +55,6 @@ jobs:

# Upload the SARIF file generated in the previous step
- name: Upload SARIF results file
uses: github/codeql-action/upload-sarif@v2
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: results.sarif
24 changes: 12 additions & 12 deletions .github/workflows/mediawiki-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,10 +97,10 @@ jobs:
experimental: false
stage: qunit

# Latest stable MediaWiki - PHP 7.4 (composer-test)
- mw: 'REL1_39'
php: 7.4
php-docker: 74
# Latest stable MediaWiki - PHP 8.1 (composer-test)
- mw: 'REL1_41'
php: 8.1
php-docker: 81
experimental: false
stage: composer-test

Expand All @@ -115,11 +115,11 @@ jobs:

steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.11.0
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}

- uses: actions/checkout@v3
- uses: actions/checkout@v4

# /home/runner/cache/ Cache
# /home/runner/src/ Mediawiki installation
Expand Down Expand Up @@ -155,12 +155,12 @@ jobs:
if [ -e .github/workflows/dependencies ] && [ "${{ matrix.stage }}" == 'phan' ]; then
cd .github/workflows
curl -sL https://raw.githubusercontent.com/wikimedia/integration-config/master/zuul/parameter_functions.py -o pf.py
curl -sL https://raw.githubusercontent.com/Universal-Omega/scripts/master/mediawiki/resolve_dependencies.py -o rd.py
curl -sL https://raw.githubusercontent.com/WikiForge/ci-scripts/master/mediawiki/resolve_dependencies.py -o rd.py
echo "DEPENDENCIES=$(python3 rd.py)" >> $GITHUB_ENV
fi
- name: Cache docker image
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: /home/runner/docker-images/${{ env.DOCKER_IMAGE }}
key: ${{ env.DOCKER_IMAGE }}:${{ env.DOCKER_LATEST_TAG }}
Expand All @@ -172,7 +172,7 @@ jobs:
- name: Cache quibble docker image
if: ${{ matrix.stage == 'coverage' || matrix.stage == 'phan' }}
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: /home/runner/docker-images/${{ env.QUIBBLE_DOCKER_IMAGE }}
key: ${{ env.QUIBBLE_DOCKER_IMAGE }}:${{ env.QUIBBLE_DOCKER_LATEST_TAG }}
Expand Down Expand Up @@ -208,10 +208,10 @@ jobs:
git -C src/ log -n 1 --format="%H"
- name: Cache dependencies (composer and npm)
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: /home/runner/cache
key: ${{ runner.os }}-${{ env.MEDIAWIKI_VERSION }}-${{ hashFiles('**/*.lock') }}
key: ${{ runner.os }}-${{ env.MEDIAWIKI_VERSION }}-${{ hashFiles('**/*.json') }}

- name: Setup PHP Action
if: ${{ matrix.stage == 'phan' }}
Expand Down Expand Up @@ -307,7 +307,7 @@ jobs:
- name: Upload coverage to Codecov
if: ${{ matrix.stage == 'coverage' }}
uses: codecov/codecov-action@v3
uses: codecov/codecov-action@v4
with:
directory: /home/runner/cover

Expand Down
3 changes: 2 additions & 1 deletion .phan/config.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
);

$cfg['suppress_issue_types'] = [
'SecurityCheck-ReDoS',
// Temporary
'MediaWikiNoEmptyIfDefined',
'SecurityCheck-LikelyFalsePositive',
'PhanAccessMethodInternal',
];
Expand Down
11 changes: 10 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -809,4 +809,13 @@ Many thanks to GreenReaper on GitHub for reporting and finding issues with core
* Added a PHPUnit test for the `notuses` parameter

# Version 3.5.2
* Added support for PHP 8.0 and PHP 8.1
* Add support for PHP 8.0 and PHP 8.1
* phan: enable `SecurityCheck-ReDoS`
* Use ExtensionRegistry::getAllThings() to get version
* Only check for buffer overflow
* Fix `usedby` query returns all templates
* Don't return the viewer's IP address as %USER% if rev_actor is 0.
* Cleanup in en.json
* Fix minoredits=exclude
* Fix "PHP Deprecated: Using ${var} in strings is deprecated, use {$var} instead"
* Fix "PHP Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated"
11 changes: 6 additions & 5 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
"composer/installers": ">=1.0.1"
},
"require-dev": {
"mediawiki/mediawiki-codesniffer": "40.0.1",
"mediawiki/mediawiki-phan-config": "0.12.0",
"mediawiki/minus-x": "1.1.1",
"mediawiki/mediawiki-codesniffer": "43.0.0",
"mediawiki/mediawiki-phan-config": "0.14.0",
"mediawiki/minus-x": "1.1.3",
"php-parallel-lint/php-console-highlighter": "1.0.0",
"php-parallel-lint/php-parallel-lint": "1.3.2"
"php-parallel-lint/php-parallel-lint": "1.4.0"
},
"scripts": {
"fix": [
Expand All @@ -31,7 +31,8 @@
"prepend-autoloader": false,
"optimize-autoloader": true,
"allow-plugins": {
"composer/installers": true
"composer/installers": true,
"dealerdirect/phpcodesniffer-composer-installer": true
}
}
}
2 changes: 1 addition & 1 deletion extension.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "DynamicPageList3",
"version": "3.5.2",
"version": "3.5.3",
"author": [
"'''Universal Omega'''",
"Alexia E. Smith",
Expand Down
4 changes: 2 additions & 2 deletions i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@
"dpl_log_3": "Error: Too many categories! Maximum: $1. Help: increase <code>$wgDplSettings['maxCategoryCount']</code> to specify more categories or set <code>$wgDplSettings['allowUnlimitedCategories'] = true;</code> for no limitation. (Set the variable in the wiki's <code>LocalSettings.php</code> configuration file.)",
"dpl_log_4": "Error: Too few categories! Minimum: $1. Help: decrease <code>$wgDplSettings['minCategoryCount']</code> to specify fewer categories. (Set the variable in the wiki's <code>LocalSettings.php</code> configuration file.)",
"dpl_log_5": "Error: No selection criteria found! You must use at least one of the following parameters: category, namespace, titlematch, linksto, uses, createdby, modifiedby, lastmodifiedby, or their 'not' variants",
"dpl_log_6": "Error: At least one category must be chosen if to use 'addfirstcategorydate=true' or 'ordermethod=categoryadd'.",
"dpl_log_6": "Error: At least one category must be chosen to use 'addfirstcategorydate=true' or 'ordermethod=categoryadd'.",
"dpl_log_7": "Error: If you include more than one category, you cannot use 'addfirstcategorydate=true' or 'ordermethod=categoryadd'.",
"dpl_log_8": "Error: Only one date type can be added at a time.",
"dpl_log_9": "Error: The paramater '$1' must be used with 'ordermethod=[ $2 ]'",
"dpl_log_10": "Error: The index for the dominant section must be between 1 and the number of arguments of includepage ($0 in this case)",
"dpl_log_11": "Error: Cannot perform logical operations on the Uncategorized pages (f.e. with the 'category' parameter) because the $0 view does not exist on the database! Help: have the database administrator execute this query: <code>$1</code>.",
"dpl_log_11": "Error: Cannot perform logical operations on the Uncategorized pages (e.g. with the 'category' parameter) because the $0 view does not exist on the database! Help: have the database administrator execute this query: <code>$1</code>.",
"dpl_log_12": "Error: Specifying \"openreferences\" is incompatible with another option specified. Please remove that other option or \"openreferences\". See the manual for details.",
"dpl_log_13": "Warning: Unknown parameter '$1' was ignored. Help: available parameters: <code>$2</code>.",
"dpl_log_14": "Warning: Skipping bad option '$2' for parameter '$1'.",
Expand Down
54 changes: 54 additions & 0 deletions i18n/he.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
{
"@metadata": {
"authors": [
"Amire80",
"מקף"
]
},
"intersection-desc": "רשימה עם תבליטים של הפריטים האחרונים המצויים בקטגוריה, או חיתוך של כמה קטגוריות",
"intersection_toomanycats": "שגיאה: יותר מדי קטגוריות!",
"intersection_toofewcats": "שגיאה: מעט מדי קטגוריות!",
"intersection_noresults": "שגיאה: אין תוצאות!",
"intersection_noincludecats": "שגיאה: יש לכלול לפחות קטגוריה אחת, או לציין מרחב שם!",
"intersection_pcerror": "לא ניתן להציג את הרשימה הזאת, משום שהשרתים עמוסים מדי. נא לנסות שוב מאוחר יותר.",
"dpl-desc": "מחולל דו\"חות גמיש מאוד עבור אתרי מדיה־ויקי",
"dpl_log_1": "טעות: פרמטר \"$1\" לא נכון: \"$2\"! עזרה: <code>$1= <i>מחרוזת ריקה</i> (ראשי)$3</code>.",
"dpl_log_2": "טעות: פרמטר \"$1\" לא נכון: \"$2\"! עזרה: <code>$1= <i>שם הדף המלא</i></code>.",
"dpl_log_3": "שגיאה: יותר מדי קטגוריות! המספר המרבי: $1. עזרה: יש להגדיל את <code dir=\"ltr\">$wgDplSettings['maxCategoryCount']</code> כדי לציין קטגוריות נוספות, או להגדיר את <code dir=\"ltr\">$wgDplSettings['allowUnlimitedCategories'] = true;</code> להסרת המגבלות. (יש להגדיר את המשתנה בקובץ התצורה <code>LocalSettings.php</code> של הוויקי.)",
"dpl_log_4": "שגיאה: יותר מדי קטגוריות! המספר המזערי: $1. עזרה: יש להקטין את <code dir=\"ltr\">$wgDplSettings['minCategoryCount']</code> כדי לציין פחות קטגוריות. (יש להגדיר את המשתנה בקובץ התצורה <code>LocalSettings.php</code> של הוויקי.)",
"dpl_log_5": "שגיאה: לא נמצאו תנאים לבחירה! יש להשתמש לפחות באחד מהפרמטרים הבאים: <span dir=\"ltr\">category, <span dir=\"ltr\">namespace</span>, <span dir=\"ltr\">titlematch</span>, <span dir=\"ltr\">linksto</span>, <span dir=\"ltr\">uses</span>, <span dir=\"ltr\">createdby</span>, <span dir=\"ltr\">modifiedby</span>, <span dir=\"ltr\">lastmodifiedby</span>, או באפשרויות ה־not שלהם",
"dpl_log_6": "שגיאה: יש לבחור לפחות קטגוריה אחת כדי להשתמש ב־\"addfirstcategorydate=true\" או ב־\"ordermethod=categoryadd\".",
"dpl_log_7": "שגיאה: כשכוללים יותר מקטגוריה אחת, לא ניתן להשתמש ב־'addfirstcategorydate=true' או ב־'ordermethod=categoryadd'.",
"dpl_log_8": "שגיאה: ניתן להוסיף רק סוג תאריך אחד בכל פעם.",
"dpl_log_9": "שגיאה: יש להשתמש בפרמטר \"$1\" עם \"<span dir=\"ltr\">ordermethod=[ $2 ]</span>\"",
"dpl_log_10": "שגיאה: המפתח עבור הקטע הדומיננטי חייב להיות בין 1 לבין מספר הארגומנטים של includepage ($0 במקרה הזה)",
"dpl_log_11": "שגיאה: לא ניתן לבצע פעולות לוגיות על הדפים ללא קטגוריות (למשל עם פרמטר \"category\") כי view בשם $0 אינו קיים במסד הנתונים! עזרה: בקשו מהמנהל מסד הנתונים לבצע את השאילתה הזאת: <code>$1</code>..",
"dpl_log_12": "שגיאה: הגדרת \"openreferences\" אינה תואמת לאפשרות אחרת. נא להסיר את האפשרות האחרת או את \"openreferences\". ר' את המדריך לפרטים.",
"dpl_log_13": "אזהרה: לפרמטר הלא־ידוע \"$1\" לא הייתה השפעה. עזרה: פרמטרים זמינים: <code>$2</code>.",
"dpl_log_14": "אזהרה: דילוג על אפשרות לא טובה \"$2\" עבור הפרמטר \"$1\".",
"dpl_log_15": "אזהרה: פרמטר \"$1\" שגוי: '$2'! תשמש ברירת מחדל: \"$3\" (ללא הגבלה). עזרה: <code>$1= <i>empty string</i> (no limit) | n</code>, כאשר <code>n</code> הוא מספר שלם חיובי.",
"dpl_log_16": "אזהרה: אין תוצאות.",
"dpl_log_17": "אזהרה: פרמטרים של add*‎ (כגון \"adduser\"‏, \"addeditdate\" וכו') ו־\"includepage\" לא משפיעים על \"mode=category\". אפשר לראות רק את מרחב השמות ואת הכותרת של הדף במצב הזה.",
"dpl_log_18": "אזהרה: \"headingmode=$1\" לא משפיע כאשר יש \"ordermethod\" על רכיב בודד. משמש: \"$2\". עזרה: אפשר להשתמש בערכי \"headingmode\" שאינם $2 עם \"ordermethod\" על כמה רכיבים. הרכיב הראשון משמש לכותרות. למשל \"<span dir=\"ltr\">ordermethod=category,<i>comp</i></span>\" (ו־<i>comp</i> הוא רכיב אחר) לכותרות של קטגוריות.",
"dpl_log_19": "אזהרה: \"debug=$1\" לא נמצא במקום הראשון באלמנט DPL. הגדרות החדשות לניפוי שגיאות לא יחולו עד שכל הפרמטרים הקודמים פוענחו ונבדקו.",
"dpl_log_20": "אזהרה: לולאת הכללה אינסופית נוצרה על־ידי הדף \"$0\".",
"dpl_log_21": "שאילתה: <code dir=\"ltr\">$0</code>",
"dpl_log_22": "אזהרה: לא סופקה אפשרות פרמטר עבור \"$1\". (חסר \"=\")",
"dpl_log_23": "שגיאה: הרשימה הזאת אינה יכולה להיות מוצגת כי השרתים עמוסים מדי. נא לנסות שוב מאוחר יותר.",
"dpl_log_24": "שגיאה: <code dir=\"ltr\">$wgDplSettings['runFromProtectedPagesOnly']</code> מוגדר, אבל הדף \"$1\" אינו מוגן מפני עריכה.",
"dpl_log_25": "שגיאה: $1",
"dpl_articlecount": "יש {{PLURAL:$1|ערך אחד|$1 ערכים}} בכותרת הזאת.",
"action-dpl_param_update_rules": "להשתמש בפרמטר \"updaterules\"",
"action-dpl_param_delete_rules": "להשתמש בפרמטר \"deleterule\"",
"dpl_query_error": "ההרחבה DynamicPageList3 (גרסה $1) יצרה משפט SQL שהוביל לשגיאה במסד נתונים.<br/>הסיבה עשויה להיות שגיאה פנימית של DynamicPageList3 או שגיאה שלך; במיוחד כאשר משתמשים בפרמטרים כמו \"categoryregexp\" או \"titleregexp\". שימוש בתבניות <code dir=\"ltr\">*?</code> חמדניות (greedy) אינו נתמך.<br/>הודעת השגיאה הייתה:<br/><tt>$2</tt>",
"dpl-tag-tracking-category": "דפים המשתמשים בתג מפענח DynamicPageList3",
"dpl-intersection-tracking-category": "דפים המשתמשים בתג המפענח Intersection של DynamicPageList3",
"dpl-parserfunc-tracking-category": "דפים המשתמשים בתג מפענח של DynamicPageList3",
"dplnum-parserfunc-tracking-category": "דפים המשתמשים בתג המפענח dplnum של DynamicPageList3",
"dplvar-parserfunc-tracking-category": "דפים המשתמשים בתג המפענח dplvar של DynamicPageList3",
"dplreplace-parserfunc-tracking-category": "דפים המשתמשים בתג המפענח dplreplace של DynamicPageList3",
"dplchapter-parserfunc-tracking-category": "דפים המשתמשים בתג dplchapter של DynamicPageList3",
"dplmatrix-parserfunc-tracking-category": "דפים המשתמשים בתג המפענח dplmatrix של DynamicPageList3",
"right-dpl_param_delete_rules": "מחיקת דפים המונית באמצעות DynamicPageList3",
"right-dpl_param_update_rules": "עדכון דפים המוני באמצעות DynamicPageList3"
}
4 changes: 2 additions & 2 deletions i18n/ia.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@
"dpl_log_3": "Error: Troppo de categorias! Maximo: $1. Adjuta: augmenta <code>$wgDplSettings['maxCategoryCount']</code> pro specificar plus categorias o defini <code>$wgDplSettings['allowUnlimitedCategories'] = true;</code> pro non haber alcun limitation. (Defini iste variabile in the file de configuration <code>LocalSettings.php</code> del wiki.)",
"dpl_log_4": "Error: Troppo poc categorias! Minimo: $1. Adjuta: diminue <code>$wgDplSettings['minCategoryCount']</code> pro specificar minus categorias. (Defini iste variabile in le file de configuration <code>LocalSettings.php</code> del wiki.)",
"dpl_log_5": "Error: Nulle criterios de selection trovate! Tu debe usar al minus un del sequente parametros: category, namespace, titlematch, linksto, uses, createdby, modifiedby, lastmodifiedby, o lor variantes 'not' (non).",
"dpl_log_6": "Error: Al minus un categoria debe esser eligite si se usa 'addfirstcategorydate=true' o 'ordermethod=categoryadd'.",
"dpl_log_6": "Error: Al minus un categoria debe esser eligite pro usar ‘addfirstcategorydate=true o ordermethod=categoryadd.",
"dpl_log_7": "Error: Si tu include plus de un categoria, tu non pote usar 'addfirstcategorydate=true' o 'ordermethod=categoryadd'.",
"dpl_log_8": "Error: Solmente un typo de datos pote esser addite al vice.",
"dpl_log_9": "Error: Le parametro '$1' debe esser usate con 'ordermethod=[ $2 ]'",
"dpl_log_10": "Error: Le indice del section dominante debe esser inter 1 e le numero de argumentos de includepage ($0 in iste caso)",
"dpl_log_11": "Error: Non pote exequer operationes logic sur le paginas non categorisate (p.ex. con le parametro 'category') perque le vista $0 non existe in le base de datos! Adjuta: demanda al administrator del base de datos de executar le consulta sequente: <code>$1</code>.",
"dpl_log_11": "Error: Non pote exequer operationes logic sur le paginas non categorisate (p.ex. con le parametro category) perque le vista $0 non existe in le base de datos! Adjuta: demanda al administrator del base de datos de executar le consulta sequente: <code>$1</code>.",
"dpl_log_12": "Error: Specificar \"openreferences\" es incompatibile con un altere option specificate. Per favor remove ille altere option o \"openreferences\". Vide le manual pro detalios.",
"dpl_log_13": "Advertimento: Le parametro incognite '$1' ha essite ignorate. Adjuta: parametros disponibile: <code>$2</code>.",
"dpl_log_14": "Advertimento: Mal option '$2' saltate pro parametro '$1'.",
Expand Down
Loading

0 comments on commit 4b33ebf

Please sign in to comment.