Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MRG] Fix nightly build #570

Merged
merged 8 commits into from
Feb 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions .github/workflows/nightly_cron.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ jobs:
fail-fast: false
matrix:
os: [windows-latest, macos-latest, ubuntu-latest]
python-version: ['3.11']
python-executable: ['cp311']
python-version: ['3.12']
python-executable: ['cp312']
defaults:
run:
shell: bash
Expand Down Expand Up @@ -59,7 +59,7 @@ jobs:
shell: bash

- name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.9.0 # TODO: Do we want this pinned?
run: python -m pip install cibuildwheel

- name: Generating dependency table
id: dependency-table # Needed to set output of job
Expand All @@ -78,6 +78,7 @@ jobs:
CIBW_ARCHS_LINUX: "x86_64"
CIBW_ARCHS_MACOS: "x86_64"
CIBW_ARCHS_WINDOWS: "AMD64"
CIBW_BEFORE_ALL: make version
CIBW_BEFORE_BUILD: >
for dependency in ${{ steps.dependencies.outputs.latest_dependencies }}; do
pip install $dependency
Expand Down
12 changes: 8 additions & 4 deletions pmdarima/arima/tests/test_validation.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
# -*- coding: utf-8 -*-

import warnings

import numpy as np
import pytest

Expand Down Expand Up @@ -42,7 +44,7 @@ def test_check_information_criterion(ic,
assert any('information_criterion cannot be' in s
for s in pytest_warning_messages(w))
else:
with pytest.warns(None) as w:
with warnings.catch_warnings(record=True) as w:
res = val.check_information_criterion(ic, ooss)
assert not w

Expand Down Expand Up @@ -90,7 +92,7 @@ def test_check_m(m, seasonal, expect_error, expect_warning, expected_val):
assert any('set for non-seasonal fit' in s
for s in pytest_warning_messages(w))
else:
with pytest.warns(None) as w:
with warnings.catch_warnings(record=True) as w:
res = val.check_m(m, seasonal)
assert not w

Expand All @@ -114,7 +116,7 @@ def test_check_n_jobs(stepwise, n_jobs, expect_warning, expected_n_jobs):
assert any('stepwise model cannot be fit in parallel' in s
for s in pytest_warning_messages(w))
else:
with pytest.warns(None) as w:
with warnings.catch_warnings(record=True) as w:
res = val.check_n_jobs(stepwise, n_jobs)
assert not w

Expand Down Expand Up @@ -199,5 +201,7 @@ def test_warn_for_D(d, D, expected):
assert any(expected in w for w in warning_msgs)

else:
with pytest.warns(None):
with warnings.catch_warnings():
# Ensure no warnings are emitted if not expected
warnings.simplefilter("error")
val.warn_for_D(d=d, D=D)
Loading