Skip to content

Commit

Permalink
JET CI fixes (#84)
Browse files Browse the repository at this point in the history
* JET CI fixes

* CI workflow improvements

* switch JET CI to use not-nightly
  • Loading branch information
Krastanov authored Apr 4, 2023
1 parent 2506d0d commit b7684f7
Show file tree
Hide file tree
Showing 8 changed files with 26 additions and 27 deletions.
8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@

# https://docs.github.com/github/administering-a-repository/configuration-options-for-dependency-updates
version: 2
updates:
- package-ecosystem: "github-actions"
directory: "/" # Location of package manifests
schedule:
interval: "weekly"
19 changes: 5 additions & 14 deletions .github/workflows/CompatHelper.yml
Original file line number Diff line number Diff line change
@@ -1,25 +1,16 @@
name: CompatHelper
on:
schedule:
- cron: 0 0 * * *
- cron: '00 00 * * *'
workflow_dispatch:
jobs:
CompatHelper:
runs-on: ubuntu-latest
steps:
- name: "Install CompatHelper"
run: |
import Pkg
name = "CompatHelper"
uuid = "aa819f21-2bde-4658-8897-bab36330d9b7"
version = "3"
Pkg.add(; name, uuid, version)
shell: julia --color=yes {0}
- name: "Run CompatHelper"
run: |
import CompatHelper
CompatHelper.main()
shell: julia --color=yes {0}
- name: Pkg.add("CompatHelper")
run: julia -e 'using Pkg; Pkg.add("CompatHelper")'
- name: CompatHelper.main()
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
COMPATHELPER_PRIV: ${{ secrets.DOCUMENTER_KEY }}
run: julia -e 'using CompatHelper; CompatHelper.main()'
4 changes: 2 additions & 2 deletions .github/workflows/breakage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ jobs:
pkgversion: [latest]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3

# Install Julia
- uses: julia-actions/setup-julia@v1
with:
version: 1
arch: x64
- uses: actions/cache@v1
- uses: actions/cache@v3
env:
cache-name: cache-artifacts
with:
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/ci-jet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,18 +11,18 @@ jobs:
fail-fast: false
matrix:
version:
- nightly
- '1'
os:
- ubuntu-latest
arch:
- x64
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
- uses: actions/cache@v3
env:
cache-name: cache-artifacts
with:
Expand All @@ -35,8 +35,8 @@ jobs:
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
env:
QUANTUMSAVORY_JET_TEST: true
QUANTUMOPTICS_JET_TEST: true
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v1
- uses: codecov/codecov-action@v3
with:
file: lcov.info
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,12 @@ jobs:
- os: macOS-latest
arch: x86
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: julia-actions/setup-julia@v1
with:
version: ${{ matrix.version }}
arch: ${{ matrix.arch }}
- uses: actions/cache@v1
- uses: actions/cache@v3
env:
cache-name: cache-artifacts
with:
Expand All @@ -41,6 +41,6 @@ jobs:
- uses: julia-actions/julia-buildpkg@v1
- uses: julia-actions/julia-runtest@v1
- uses: julia-actions/julia-processcoverage@v1
- uses: codecov/codecov-action@v1
- uses: codecov/codecov-action@v3
with:
file: lcov.info
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: julia-actions/setup-julia@latest
with:
version: '1'
Expand Down
2 changes: 1 addition & 1 deletion src/operators.jl
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ function embed(basis_l::CompositeBasis, basis_r::CompositeBasis,
start_indices_flat = [i[1] for i in indices]
complement_indices_flat = Int[i for i=1:N if i indices_flat]
operators_flat = AbstractOperator[]
if all([minimum(I):maximum(I);]==I for I in indices)
if all(([minimum(I):maximum(I);]==I)::Bool for I in indices) # type assertion to help type inference
for i in 1:N
if i in complement_indices_flat
push!(operators_flat, identityoperator(T, S, basis_l.bases[i], basis_r.bases[i]))
Expand Down
2 changes: 1 addition & 1 deletion test/test_jet.jl
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ using LinearAlgebra, LRUCache, Strided, Dates, SparseArrays
if get(ENV,"QUANTUMOPTICS_JET_TEST","")=="true"
rep = report_package("QuantumOpticsBase";
report_pass=MayThrowIsOk(), # TODO have something more fine grained than a generic "do not care about thrown errors"
ignored_modules=( # TODO fix issues with these modules or report them upstrem
ignored_modules=( # TODO fix issues with these modules or report them upstream
AnyFrameModule(LinearAlgebra),
AnyFrameModule(LRUCache),
AnyFrameModule(Strided),
Expand Down

0 comments on commit b7684f7

Please sign in to comment.