Skip to content

Conversation

@larsoner
Copy link
Member

@larsoner larsoner commented Apr 7, 2022

While working on mne-tools/mne-qt-browser#105 I kept getting unexpected errors on CIs. The first time I ran the tests locally on my macOS machine, I could replicate the issue. The second time, however, I could not. I realized this was because the MNE_BROWSE_RAW_SIZE config var on my system was being overwritten (!). This PR fixes this by:

  1. Setting the _MNE_CONFIG_FAKE_HOME_DIR at the session level to prevent overwriting people's config vars
  2. Setting the MNE_BROWSE_RAW_SIZE to standardize browser sizes across all systems. This should make things more repeatable in testing across different people's systems (which could otherwise have different MNE_BROWSE_RAW_SIZE). In an ideal world, this value would not matter, but in practice our _fake_clicks are not so well generalized to arbitrary window sizes.
  3. Monkey-patching the native to-fullscreen methods for the two backends so that fullscreen mode is never called. This helps with testing on macOS a bit, where the fullscreen mode messes with focus a bit. (I think we can trust mpl and Qt to test their own fullscreen methods.)
  4. Removing fullscreen keypress tests from epochs and ica, leaving for raw. Again I think we can trust our own abstraction here so we don't have to monkeypatch in three places.

@agramfort
Copy link
Member

@larsoner I let you merge and backport 🙏

@larsoner larsoner requested a review from sappelhoff as a code owner April 8, 2022 14:05
@larsoner larsoner merged commit 321cafc into mne-tools:main Apr 8, 2022
@larsoner larsoner deleted the rep branch April 8, 2022 18:09
larsoner added a commit that referenced this pull request Apr 8, 2022
@larsoner larsoner added backported and removed backport-candidate on-merge: backport to maint/1.11 labels Apr 8, 2022
larsoner added a commit to wmvanvliet/mne-python that referenced this pull request Apr 19, 2022
* upstream/main: (40 commits)
  FIX: Flake (mne-tools#10540)
  FIX: Correct link (mne-tools#10536)
  DOC: Update installers (mne-tools#10535)
  ENH: Add dark mode to website (mne-tools#10523)
  WIP: Copy BEM surfaces by default (don't symlink) (mne-tools#10531)
  Avoid lowpass=0 in brainvision data (mne-tools#10517)
  DOC: Update installers [skip azp] [skip actions] (mne-tools#10528)
  FIX: Fix for old build (mne-tools#10527)
  Fix line noise at wrong frequencies (mne-tools#10525)
  FIX : read fids in eeglab (mne-tools#10521)
  MAINT: Prefer PySide6 in testing (mne-tools#10513)
  ENH: Add overview_mode support (mne-tools#10501)
  MRG: Updates for qtpy in mne-qt-browser (mne-tools#10509)
  BUG: Fix bug with themes on macOS (mne-tools#10500)
  MAINT: Bump installer links (mne-tools#10511)
  Add metadata to combine_channels (mne-tools#10504)
  MAINT: Standardize tests (mne-tools#10502)
  CI: Test circle (mne-tools#10506)
  ENH: Use HiDPI splash screen on HiDPI screens (mne-tools#10503)
  WIP,MNT: Add support for QtPy (mne-tools#10430)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants