these 3 derivations will be built: /nix/store/qhi7cwj2wi36haha2951xl4f23llm4xr-treefmt.toml.drv /nix/store/xlqi0jjy6nfq62fsjyncz1hbd09wbmmm-treefmt.drv /nix/store/9waidlwcq17s7ps8m81zm5p0rq2s1i1h-treefmt-check.drv these 55 paths will be fetched (134.6 MiB download, 413.2 MiB unpacked): /nix/store/4x7kv1j70s905hj9aq93sz6r98fsa2jm-deadnix-1.3.2 /nix/store/4az1iwdggg2f6bsi3khyj5dlzq1vxmcl-deno-2.9.4 /nix/store/q3pvpkn0qmin7x572p3z32hxz9yny73i-git-2.55.0 /nix/store/jbfpbknl5qh0cm5zg48gxgb6fzhwvq04-git-2.55.0-doc /nix/store/ravvpa3yq597bf5szpf761ic2xnmkwcj-git-lfs-3.7.1 /nix/store/dnvwhqgbyg8vhxmkjdfxfjlf77lq13pn-gmp-with-cxx-6.3.0 /nix/store/w0pibr5hh7yk8s7fh03yr3af07rwv5xz-jemalloc-5.3.1 /nix/store/ximcq9mlp6ca47n56pvf8w4qk78rnvqb-json2x-0.1.0 /nix/store/nqra5cnmqrg4h80zzbmx0pdaixy417wg-lcms2-2.19.1 /nix/store/bz0n3a4wzb8b52xi3y457ypn9w07dkqr-nixfmt-1.4.0 /nix/store/k9b8y08gg5bma5rzv6cifz98j909xlv4-numactl-2.0.18 /nix/store/5mh24sqy6bfigfnxd0z2f34ayjldhgg1-perl5.42.0-Authen-SASL-2.1900 /nix/store/1hpmxrk1h6z0disn5645ldszhmy07y5g-perl5.42.0-CGI-4.59 /nix/store/wl8zbbcqv05a0wcf3vj3s2xsydc2ikfi-perl5.42.0-CGI-Fast-2.16 /nix/store/adlx3ngvaz0xik8120q7cwdis6md9jjz-perl5.42.0-Clone-0.46 /nix/store/h0zfxbpl0p5r10dlyahxz9mzgf1md268-perl5.42.0-Compress-Raw-Bzip2-2.218 /nix/store/gnzifmzb5r72ajwbbvpbkwvyf45sqhjp-perl5.42.0-Compress-Raw-Zlib-2.222 /nix/store/72sra5sw8a2aspnn72r6vjwxbm80x9gd-perl5.42.0-Crypt-URandom-0.55 /nix/store/vz99vl0g4v7jpynwnlmvgrs1y7gwi23f-perl5.42.0-Digest-HMAC-1.05 /nix/store/bxxw1906hsa770igjyzvhh5zgwknal3h-perl5.42.0-Encode-Locale-1.05 /nix/store/65zg8l2r3vx34zxr0gzzxlgxxbwmq0zy-perl5.42.0-FCGI-0.82 /nix/store/y0gr2a2rv8yr2aszr7qqlqhvwr1zwmcy-perl5.42.0-FCGI-ProcManager-0.28 /nix/store/d52k7x1yyqgygv4cha58bv9ckgc2pisj-perl5.42.0-File-Listing-6.16 /nix/store/k1i8np1y3raiavx3nbvd7f3m8hmvmlks-perl5.42.0-HTML-Parser-3.85 /nix/store/pr8yxkg38z8xgz0q6z53fh4iydsf7jsp-perl5.42.0-HTML-TagCloud-0.38 /nix/store/fi3wcrkma5cpnp53dxzaly0846bg0rmq-perl5.42.0-HTML-Tagset-3.20 /nix/store/nc72i3ffndprkfxcxmsdcx9la9zbmvr3-perl5.42.0-HTTP-CookieJar-0.014 /nix/store/s6zqpsc8cf48vw0q8s8zd2330m8q69f1-perl5.42.0-HTTP-Cookies-6.10 /nix/store/jlaimr9p20cjgl7waab20gb6h5b6jga4-perl5.42.0-HTTP-Daemon-6.17 /nix/store/wavmkdswdv8v1kdilnbazill9b77agkb-perl5.42.0-HTTP-Date-6.06 /nix/store/sxapy4d2xzq6akwrkrd2ksxx7dv3jg00-perl5.42.0-HTTP-Message-7.02 /nix/store/i91sc1fprvrqhya9h7f19lww2vngqnlp-perl5.42.0-HTTP-Negotiate-6.01 /nix/store/fwk4bgd1v892v488vmvyxwlhsn2216l3-perl5.42.0-IO-Compress-2.221 /nix/store/0afw57kj1dypiawnygqhiv4m6phln0dm-perl5.42.0-IO-HTML-1.004 /nix/store/3yj2yr6plb7q0xn3mfpvdfy6hi70pazf-perl5.42.0-IO-Socket-SSL-2.083 /nix/store/8l49xc65lv36r3l7vgl5hn6jisj8jvry-perl5.42.0-LWP-MediaTypes-6.04 /nix/store/5vwn85gq3niq9gxc4fvdhqaq3gj73p29-perl5.42.0-Mozilla-CA-20230821 /nix/store/w4jh2b0crsxqk58bj6s9l0cwblmv0cd4-perl5.42.0-Net-HTTP-6.23 /nix/store/zwrvfq06cg9sffvmqsc3sqkjz4mhm907-perl5.42.0-Net-SMTP-SSL-1.04 /nix/store/gx0lskzy7a13r8rhb0hqngnfrhaz9c81-perl5.42.0-Net-SSLeay-1.92 /nix/store/5chj8dwgz2p7a31r7vzrg23pf675in5z-perl5.42.0-TermReadKey-2.38 /nix/store/ch6gyavxaji48yyfdgdvyzhb9878301p-perl5.42.0-Test-Fatal-0.017 /nix/store/h73acc4phd6fy12nsyrnray727wpvmwa-perl5.42.0-Test-Needs-0.002010 /nix/store/7j80zc5807d96ldm5sv0q7qs5mipli22-perl5.42.0-Test-RequiresInternet-0.05 /nix/store/xpc4a1dchff70fn9d05ws4v2ipc12cq2-perl5.42.0-TimeDate-2.33 /nix/store/0qkacffjmc7588calz6x7a092hdbvg49-perl5.42.0-Try-Tiny-0.31 /nix/store/k7c84b0jrp0yjgnawpprmcd7kj243vfg-perl5.42.0-URI-5.21 /nix/store/vpxrgyxi44znlpq75imiyaklw2g4xcyi-perl5.42.0-WWW-RobotRules-6.02 /nix/store/ghs8dpbw5c818hdwjyr41q4l1jfdvv14-perl5.42.0-libnet-3.15 /nix/store/394gj35jpp6dg48v6kpmbijxgw2lqywc-perl5.42.0-libwww-perl-6.83 /nix/store/9pfxvv9zwlny32xlvg31q81ywv387fnm-ruff-0.16.2 /nix/store/ni99f5g4r74wx0ggjxfagkngk3yr88vm-shellcheck-0.11.0-bin /nix/store/8hzki9sgxlz7m50yfaf1h78a5h0irnj6-shfmt-3.13.1 /nix/store/ms6ily2r9sw6rbbksxca4hm03436nb3m-treefmt-2.5.0 /nix/store/5xpc78q9g89ksxpnz2dn78xdc8lgxc1g-yamlfmt-0.21.0 building '/nix/store/qhi7cwj2wi36haha2951xl4f23llm4xr-treefmt.toml.drv' treefmt.toml> tribuchet: building on eliza treefmt.toml> structuredAttrs is enabled building '/nix/store/xlqi0jjy6nfq62fsjyncz1hbd09wbmmm-treefmt.drv' treefmt> tribuchet: building on eliza building '/nix/store/9waidlwcq17s7ps8m81zm5p0rq2s1i1h-treefmt-check.drv' treefmt-check> tribuchet: building on eliza treefmt-check> treefmt v2.5.0ERRO formatter | ruff-check: failed to apply with options '[check --fix]': exit status 1 treefmt-check> treefmt-check> PIE810 Call `startswith` once with a `tuple` treefmt-check> --> checks/linkcheck/main.py:49:12 treefmt-check> | treefmt-check> 47 | continue treefmt-check> 48 | treefmt-check> 49 | if title.startswith("User:") or title.startswith("Talk:"): treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> 50 | root.remove(page) treefmt-check> 51 | continue treefmt-check> | treefmt-check> help: Merge into a single `startswith` call treefmt-check> treefmt-check> EXE005 Shebang should be at the beginning of the file treefmt-check> --> modules/nixos-wiki/update-extensions.py:2:1 treefmt-check> | treefmt-check> 1 | #!/usr/bin/env nix-shell treefmt-check> 2 | #!nix-shell -i python3 -p nixfmt-rfc-style python3 python3Packages.requests python3Packages.beautifulsoup4 gh treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> 3 | import json treefmt-check> 4 | import os treefmt-check> | treefmt-check> treefmt-check> TRY002 Create your own exception treefmt-check> --> modules/nixos-wiki/update-extensions.py:34:15 treefmt-check> | treefmt-check> 32 | content = soup.find(id="mw-content-text") treefmt-check> 33 | if content and "does not exist" in content.get_text(): treefmt-check> 34 | raise Exception( treefmt-check> | _______________^ treefmt-check> 35 | | f"Extension '{extension_name}' does not exist for MediaWiki version REL{mediawiki_version}" treefmt-check> 36 | | ) treefmt-check> | |_________^ treefmt-check> 37 | treefmt-check> 38 | # Look for download links - the class is now a list ['external', 'free'] treefmt-check> | treefmt-check> treefmt-check> TRY002 Create your own exception treefmt-check> --> modules/nixos-wiki/update-extensions.py:47:11 treefmt-check> | treefmt-check> 45 | return urllib.parse.urlparse(href) treefmt-check> 46 | treefmt-check> 47 | raise Exception( treefmt-check> | ___________^ treefmt-check> 48 | | f"Could not find download URL for extension '{extension_name}' version REL{mediawiki_version}" treefmt-check> 49 | | ) treefmt-check> | |_____^ treefmt-check> treefmt-check> FURB122 Use of `f.write` in a for loop treefmt-check> --> modules/nixos-wiki/update-extensions.py:73:13 treefmt-check> | treefmt-check> 71 | r.raise_for_status() treefmt-check> 72 | with open(local_filename, "wb") as f: treefmt-check> 73 | / for chunk in r.iter_content(chunk_size=8192): treefmt-check> 74 | | # If you have chunk encoded response uncomment if treefmt-check> 75 | | # and set chunk_size parameter to None. treefmt-check> 76 | | # if chunk: treefmt-check> 77 | | f.write(chunk) treefmt-check> | |______________________________^ treefmt-check> 78 | return local_filename treefmt-check> | treefmt-check> help: Replace with `f.writelines` treefmt-check> treefmt-check> TRY002 Create your own exception treefmt-check> --> modules/nixos-wiki/update-extensions.py:116:19 treefmt-check> | treefmt-check> 114 | data = response.json() treefmt-check> 115 | if not data: treefmt-check> 116 | raise Exception(f"No tags found for {repo}") treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> 117 | latest_tag = data[0]["name"] treefmt-check> 118 | return f"https://github.com/{repo}/archive/refs/tags/{latest_tag}.zip" treefmt-check> | treefmt-check> treefmt-check> TRY002 Create your own exception treefmt-check> --> modules/nixos-wiki/update-extensions.py:120:15 treefmt-check> | treefmt-check> 118 | return f"https://github.com/{repo}/archive/refs/tags/{latest_tag}.zip" treefmt-check> 119 | else: treefmt-check> 120 | raise Exception(f"Unknown extension type: {extension_type}") treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> treefmt-check> TRY002 Create your own exception treefmt-check> --> modules/nixos-wiki/update-extensions.py:144:11 treefmt-check> | treefmt-check> 142 | else: treefmt-check> 143 | return Extension(name=extension_name, hash=hash, url=download_url) treefmt-check> 144 | raise Exception("Failed to fetch extension, see above") treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> treefmt-check> TRY002 Create your own exception treefmt-check> --> modules/nixos-wiki/update-extensions.py:173:11 treefmt-check> | treefmt-check> 171 | else: treefmt-check> 172 | return Extension(name=extension_name, hash=hash, url=mirror_url) treefmt-check> 173 | raise Exception("Failed to fetch extension, see above") treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> treefmt-check> EXE001 Shebang is present but file is not executable treefmt-check> --> pkgs/wiki-user-search/wiki-user-search.py:1:1 treefmt-check> | treefmt-check> 1 | #!/usr/bin/env python3 treefmt-check> | ^^^^^^^^^^^^^^^^^^^^^^ treefmt-check> 2 | """ treefmt-check> 3 | MediaWiki User Search Tool treefmt-check> | treefmt-check> treefmt-check> Found 27 errors (17 fixed, 10 remaining). treefmt-check> No fixes available (2 hidden fixes can be enabled with the `--unsafe-fixes` option). treefmt-check> treefmt-check> traversed 71 files treefmt-check> emitted 55 files for processing treefmt-check> formatted 52 files (2 changed) in 670ms treefmt-check> Error: failed to finalise formatting: formatting failures detected error: Cannot build '/nix/store/9waidlwcq17s7ps8m81zm5p0rq2s1i1h-treefmt-check.drv'. Reason: builder failed with exit code 1. Output paths: /nix/store/d49sw3366794i6lk4v43r8rbfpglsyzg-treefmt-check Last 25 log lines: > > TRY002 Create your own exception > --> modules/nixos-wiki/update-extensions.py:173:11 > | > 171 | else: > 172 | return Extension(name=extension_name, hash=hash, url=mirror_url) > 173 | raise Exception("Failed to fetch extension, see above") > | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ > > EXE001 Shebang is present but file is not executable > --> pkgs/wiki-user-search/wiki-user-search.py:1:1 > | > 1 | #!/usr/bin/env python3 > | ^^^^^^^^^^^^^^^^^^^^^^ > 2 | """ > 3 | MediaWiki User Search Tool > | > > Found 27 errors (17 fixed, 10 remaining). > No fixes available (2 hidden fixes can be enabled with the `--unsafe-fixes` option). > > traversed 71 files > emitted 55 files for processing > formatted 52 files (2 changed) in 670ms > Error: failed to finalise formatting: formatting failures detected For full logs, run: nix log /nix/store/9waidlwcq17s7ps8m81zm5p0rq2s1i1h-treefmt-check.drv