|
Meta tags:
description=Fixes python/core-workflow#505.
Fixes #60283.
Add Ruff to the CI (via pre-commit) to check Lib/test/ for F811 Redefinition of unused name . Ruff (47s) is faster than Flake8 (1m39s).
This will help find copy/pasted test_* method names, which results in one of them not being run.
It also finds redefined variables, which ISTR people were in favour of.
There are some files which fail to lint or parse, and have been excluded. Some of these are intentional and should never be checked (e.g. Lib/test/badsyntax_pep3120.py), some are due to new 3.12+ syntax not yet supported by the Ruff linter (e.g. Lib/test/test_type_aliases.py). I think we can be pragmatic and exclude any that add new syntax until such a time the linter supports the new version. (This may also help drive adoption of new syntax by the linter.)
This currently fails due to duplicated tests in test_monitoring, which will be fixed in #109139 and has been left as a demonstration in the meantime.
All other test_* duplicates have been fixed (see links in python/core-workflow#505).
Some files have duplicate variables, I ve excluded those and they can be fixed and re-included in the future.
Issue: gh-60283;
Headings (most frequently used words):
uh, oh, for, navigation, gh, 60283, check, redefined, test, names, in, ci, 109161, footer, diff, view, menu, repository, there, are, no, files, selected, viewing, filter, by, extension,
Text of the page (most frequently used words):
file (39), github (31), this (23), #hugovk (23), line (18), 2023 (17), diff (16), sep (16), the (15), for (15), hidden (15), characters (15), unicode (15), and (15), commit (14), show (14), that (13), reload (12), test (12), ruff (12), applied (11), open (11), pre (11), while (10), number (10), bidirectional (10), resolved (9), loading (9), please (8), check (8), changes (8), all (8), there (8), toml (8), files (8), config (8), you (7), suggestion (7), cannot (7), suggestions (7), comments (7), change (7), code (7), was (7), error (7), page (7), learn (7), about (7), view (7), expand (7), yaml (7), yml (7), build (7), sign (7), python (6), name (6), true (6), what (6), review (6), more (6), lib (6), security (5), pull (5), marked (5), add (5), support (5), conversation (5), comment (5), original (5), contains (5), text (5), may (5), interpreted (5), compiled (5), differently (5), than (5), appears (5), below (5), editor (5), reveals (5), desktop (5), delete (5), edit (5), workflows (5), commits (5), your (5), can (4), from (4), only (4), https (4), com (4), fix (4), f811 (4), failed (4), lint (4), exclude (4), alexwaygood (4), thread (4), with (4), deletions (4), down (4), nbsp (4), redefined (4), names (4), copilot (4), community (3), navigation (3), request (3), pending (3), batch (3), cpython (3), redefinition (3), unused (3), select (3), additions (3), hooks (3), codeowners (3), hide (3), whitespace (3), extension (3), filter (3), 109161 (3), 60283 (3), merged (3), account (3), quality (3), another (3), tab (3), window (3), refresh (3), session (3), developers (3), changelog (3), customer (3), enterprise (3), grade (3), features (3), not (2), contact (2), status (2), privacy (2), terms (2), footer (2), now (2), order (2), single (2), one (2), viewing (2), invalid (2), toggle (2), annotations (2), test_monitoring (2), __init__ (2), test_ctypes (2), parse (2), encoded_modules (2), types (2), rev (2), repo (2), args (2), run (2), repos (2), workflow (2), git (2), origin (2), github_base_ref (2), grep (2), qve (2), rst (2), doc (2), misc (2), echo (2), run_tests (2), github_output (2), issues (2), into (2), addition (2), selected (2), apply (2), split (2), unified (2), load (2), retry (2), jump (2), temporarily (2), remove (2), its (2), move (2), tree (2), issue (2), insights (2), projects (2), actions (2), repository (2), signed (2), universe (2), training (2), integrations (2), stories (2), center (2), documentation (2), business (2), fixes (2), products (2), secret (2), perform, action, time, share, personal, information, manage, cookies, docs, 2026, inc, right, back, later, queued, merge, multi, reviews, has, been, outdated, must, existing, create, valid, applying, deleted, lines, supported, per, subset, closed, because, were, made, notes, 109139, time_hashlib, test_yield_from, test_unittest, testmock, testpatch, test_typing, test_subclassinit, test_pkg, test_keywordonlyarg, test_import, test_grammar, test_genericclass, test_functools, test_enum, test_descr, test_dataclasses, test_functions, test_arrays, test_buffer, test__opcode, todo, test_fstring, socket_helper, badsyntax_3131, module_koi8_r, module_iso_8859_1, badsyntax_pep3120, extend, variable, useful, finding, methods, same, end, fixer, test_tomllib, exit, non, zero, 288, astral, cancel, progress, group, head_ref, run_id, concurrency, ruff_format, force_color, env, contents, read, permissions, push, pull_request, workflow_dispatch, should, hypothesis, tests, core, 373, branch, anyway, jobs, deletion, configure, erlend, aasland, corona10, system, are, conversations, clear, filters, viewed, manifest, d9dff8d, some, exclusions, which, 6ba396d, bump, 0889959, colour, logs, readability, 932f2c1, clarify, job, scope, 0bf3e3e, let, tomllib, look, after, own, 3839aea, don, validate, intentionally, 9b1b43a, update, 66e1172, 8fd293a, 83904af, 1bdae72, autofix, setting, cb8237c, rule, d14c002, relevant, subdirectory, localise, rules, 0dcdd08, a37828c, jun, 4cd4803, hold, shift, click, range, changed, checks, main, already, clicking, agree, our, occasionally, send, related, emails, statement, service, free, maintainers, have, question, project, new, items, requests, message, dismiss, alert, switched, accounts, out, appearance, settings, search, pricing, event, talks, workshops, next, partners, company, forum, events, webinars, blog, resource, connect, resources, premium, advanced, ons, trust, why, evaluate, see, industries, government, manufacturing, financial, services, healthcare, industry, nonprofits, startups, team, enterprises, stage, businesses, source, latest, improvements, across, place, developer, articles, sponsors, trending, explore, customize, certifications, scanning, leak, prevention, protection, vulnerability, detection, remediation, secure, cloud, development, environments, codespaces, analysis, enforcement, automation, ship, coding, agent, tasks, automated, work, hosting, collaboration, platform, menu, skip, content,
|