Comments (3)
The key is to execute your tests as the argument to flux start
. Without any arguments flux start
launches an interactive shell -- I'm not sure what would happen in a non-interactive environment like Github CI, possibly a hang or an error like you are seeing.
In your example repo above, you run flux start
, then flux submit
in a separate shell. This won't work because only the shell or program started by flux start
has access to the test instance that has been created.
The rmsi_init
error is from hwloc, I'm not sure why you see Exception caught
with it, when I've seen it, it is a harmless error message.
For more background, flux start
starts a flux instance (mostly for testing) with one or more brokers (e.g. you can start a test instance with 4 brokers with flux start --test-size=4
) and launches an interactive shell with access to that instance (by setting FLUX_URI
to the URI of the rank 0 broker for the newly created instance). This allows multiple instances to be started on a single system in parallel without interfering with each other. If flux start
is given an argument then this script is run instead of an interactive shell, and the instance terminates automatically when the script is complete (we call this an "initial program" and it works very much like a batch script).
The flux-core testsuite and the tests of many of its subprojects use flux start
to run automated tests in CI. Our testsuite is based on sharness, I'd be happy to go into more detail how it works if you'd like. You could then decide if borrowing the framework would work for your testing purposes.
from flux-core.
Oh great, I thought the error message meant that flux was not able to start the broker. All I had to do was change the run: |
line to run: >
. Just in case somebody else wants to reproduce the environment:
name: Flux
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: conda-incubator/[email protected]
with:
python-version: "3.11"
mamba-version: "*"
channels: conda-forge
miniforge-variant: Mambaforge
channel-priority: strict
auto-update-conda: true
environment-file: "environment.yml"
- name: Install flux
shell: bash -l {0}
run: mamba install -y flux-core
- name: Test
shell: 'script -q -e -c "bash -l {0}"'
timeout-minutes: 5
run: >
flux start
flux submit sleep 1
sleep 2
flux jobs -a
flux resource list
from flux-core.
Great!
I'm still not sure that's going to do exactly what you want since won't it run basically
flux start flux submit sleep 1 sleep 2 flux jobs -a flux resource list
If so, the flux start
will start exiting immediately after flux submit
is successful. The submitted job itself will fail since sleep 1 sleep 2 flux jobs -a...
is being submitted.
from flux-core.
Related Issues (20)
- Flux bootstrapping error on IBM LSF machines (Lassen) with flux-core>=0.46 HOT 1
- requested duration exceeds policy limit of 3e+01m HOT 7
- shell: just implement the pmi2 wire protocol already HOT 4
- job-info: get internal representation of R
- "is not a tty" when starting flux programmatically HOT 3
- FAIL: t2602-job-shell.t 21 - job-shell: test shell kill event handling: SIGKILL
- src/modules: module arg parsing
- idea: broker module dependency management HOT 6
- ZMQ library issues when compiling flux-core HOT 12
- build: missing checks in configure HOT 2
- drop libsodium-dev requirement
- flux fails in rc1 when BASH_ENV includes code that is not -e (exit on error) clean HOT 1
- Issues when testing manual installation HOT 19
- Idea: job-info: add streaming RPC to "watch" R HOT 10
- `/etc/flux/rc1` fails with >1 file in `/etc/flux/rc1.d` HOT 2
- Build failure Python 3.12 HOT 1
- checking for cffi.__version_info__ >= (1,1) in python module cffi... no HOT 9
- LBANN mpi-catch-test hangs in MPI_Finalize with ompi 4.1.2 and simple PMI HOT 10
- default begin-time dependency format in `flux jobs` HOT 2
- flux run segfaults if user is not in password file on compute node HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from flux-core.