forked from mne-tools/mne-python
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/main' into feature/TD-nirs_snirf
* upstream/main: (824 commits) Add `psd_args` to `plot_ica_sources` and `ICA.plot_sources` (mne-tools#12912) Fix GDF NumPy >= 2 (mne-tools#12909) [pre-commit.ci] pre-commit autoupdate (mne-tools#12908) ENH: Improve report usability (mne-tools#12901) MAINT: Avoid problematic PySide6 (mne-tools#12902) Sync README dependencies with pyproject.toml (mne-tools#12890) remove trailing slash from pybv base URL [ci skip] (mne-tools#12892) Cast tuple of filenames to list to improve error handling (mne-tools#12891) Website (mne-tools#12885) [pre-commit.ci] pre-commit autoupdate (mne-tools#12888) BUG: Fix bugs with coreg (mne-tools#12884) Bump mamba-org/setup-micromamba from 1 to 2 in the actions group (mne-tools#12887) Update spacing for comments in pyproject.toml (mne-tools#12886) make HTML repr for Forward match others (mne-tools#12883) MAINT: Linkchecks [circle deploy] (mne-tools#12882) Update roadmap (mne-tools#12872) [MRG] Require good and bad channels when creating a SpectrumArray object (mne-tools#12877) [pre-commit.ci] pre-commit autoupdate (mne-tools#12879) MAINT: Update code credit (mne-tools#12880) BUG: Fix bug with Path casting (mne-tools#12878) ...
- Loading branch information
Showing
8,133 changed files
with
428,338 additions
and
113,433 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# PR number should follow the commit number so that our code credit | ||
# can parse this file correctly: | ||
d71e497dcf6f98e19eb81e82e641404a71d2d663 # 1420, split up viz.py | ||
203a96cbba2732d2e349a8f96065e74bbfd2a53b # 5862, split utils.py | ||
ff349f356edb04e1b5f0db13deda8d1a20aca351 # 6767, move around manual parts | ||
31a83063557fbd54d898f00f9527ffc547888395 # 10407, alphabetize docdict | ||
e81ec528a42ac687f3d961ed5cf8e25f236925b0 # 11667, black | ||
12395f9d9cf6ea3c72b225b62e052dd0d17d9889 # 11868, YAML indentation | ||
d6d2f8c6a2ed4a0b27357da9ddf8e0cd14931b59 # 12097, isort | ||
e7dd1588013179013a50d3f6b8e8f9ae0a185783 # 12261, ruff format | ||
940ac9553ce42c15b4c16ecd013824ca3ea7244a # 12533, whitespace | ||
e39995d9be6fc831c7a4a59f09b7a7c0a41ae315 # 12588, percent formatting | ||
1c5b39ff1d99bbcb2fc0e0071a989b3f3845ff30 # 12603, ruff UP028 | ||
b8b168088cb474f27833f5f9db9d60abe00dca83 # 12779, PR JSONs | ||
ee64eba6f345e895e3d5e7d2804fa6aa2dac2e6d # 12781, Header unification | ||
362f9330925fb79a6adc19a42243672676dec63e # 12799, UP038 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
node: $Format:%H$ | ||
node-date: $Format:%cI$ | ||
describe-name: $Format:%(describe:tags=true,match=*[0-9]*)$ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
.git_archival.txt export-subst |
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
#!/usr/bin/env python3 | ||
|
||
# Authors: The MNE-Python contributors. | ||
# License: BSD-3-Clause | ||
# Copyright the MNE-Python contributors. | ||
|
||
# Adapted from action-towncrier-changelog | ||
import json | ||
import os | ||
import re | ||
import subprocess | ||
import sys | ||
from pathlib import Path | ||
|
||
from github import Github | ||
from tomllib import loads | ||
|
||
event_name = os.getenv("GITHUB_EVENT_NAME", "pull_request") | ||
if not event_name.startswith("pull_request"): | ||
print(f"No-op for {event_name}") | ||
sys.exit(0) | ||
if "GITHUB_EVENT_PATH" in os.environ: | ||
with open(os.environ["GITHUB_EVENT_PATH"], encoding="utf-8") as fin: | ||
event = json.load(fin) | ||
pr_num = event["number"] | ||
basereponame = event["pull_request"]["base"]["repo"]["full_name"] | ||
real = True | ||
else: # local testing | ||
pr_num = 12318 # added some towncrier files | ||
basereponame = "mne-tools/mne-python" | ||
real = False | ||
|
||
g = Github(os.environ.get("GITHUB_TOKEN")) | ||
baserepo = g.get_repo(basereponame) | ||
|
||
# Grab config from upstream's default branch | ||
toml_cfg = loads(Path("pyproject.toml").read_text("utf-8")) | ||
|
||
config = toml_cfg["tool"]["towncrier"] | ||
pr = baserepo.get_pull(pr_num) | ||
modified_files = [f.filename for f in pr.get_files()] | ||
|
||
# Get types from config | ||
types = [ent["directory"] for ent in toml_cfg["tool"]["towncrier"]["type"]] | ||
type_pipe = "|".join(types) | ||
|
||
# Get files that potentially match the types | ||
directory = toml_cfg["tool"]["towncrier"]["directory"] | ||
assert directory.endswith("/"), directory | ||
|
||
file_re = re.compile(rf"^{directory}({type_pipe})\.rst$") | ||
found_stubs = [f for f in modified_files if file_re.match(f)] | ||
for stub in found_stubs: | ||
fro = stub | ||
to = file_re.sub(rf"{directory}{pr_num}.\1.rst", fro) | ||
print(f"Renaming {fro} to {to}") | ||
if real: | ||
subprocess.check_call(["mv", fro, to]) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
changelog: | ||
exclude: | ||
authors: | ||
- dependabot | ||
- pre-commit-ci | ||
- github-actions |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: autofix.ci | ||
|
||
on: # yamllint disable-line rule:truthy | ||
pull_request: | ||
types: [opened, synchronize, labeled, unlabeled] | ||
|
||
permissions: | ||
contents: read | ||
|
||
jobs: | ||
autofix: | ||
name: Autoupdate changelog entry and headers | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.12' | ||
- run: pip install --upgrade towncrier pygithub gitpython numpy | ||
- run: python ./.github/actions/rename_towncrier/rename_towncrier.py | ||
- run: python ./tools/dev/ensure_headers.py | ||
- uses: autofix-ci/action@dd55f44df8f7cdb7a6bf74c78677eb8acd40cd0a |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
name: Changelog | ||
|
||
on: # yamllint disable-line rule:truthy | ||
pull_request: | ||
types: [opened, synchronize, labeled, unlabeled] | ||
branches: ["main"] | ||
|
||
jobs: | ||
changelog_checker: | ||
name: Check towncrier entry in doc/changes/devel/ | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: scientific-python/action-towncrier-changelog@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
BOT_USERNAME: changelog-bot |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
on: [status] | ||
on: [status] # yamllint disable-line rule:truthy | ||
jobs: | ||
circleci_artifacts_redirector_job: | ||
if: "${{ startsWith(github.event.context, 'ci/circleci: build_docs') }}" | ||
runs-on: ubuntu-20.04 | ||
name: Run CircleCI artifacts redirector | ||
steps: | ||
- name: GitHub Action step | ||
uses: larsoner/circleci-artifacts-redirector-action@master | ||
uses: scientific-python/circleci-artifacts-redirector-action@master | ||
with: | ||
repo-token: ${{ secrets.GITHUB_TOKEN }} | ||
artifact-path: 0/dev/index.html | ||
api-token: ${{ secrets.CIRCLECI_TOKEN }} | ||
artifact-path: 0/html/sg_execution_times.html | ||
circleci-jobs: build_docs,build_docs_main | ||
job-title: Check the rendered docs here! |
Oops, something went wrong.