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

St/wip #33

Merged
merged 4 commits into from
Oct 20, 2023
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
16 changes: 8 additions & 8 deletions .github/workflows/ci-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,19 +10,19 @@ jobs:
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
python-version: ${{ 3.9 }}
- name: Conda install clingo
shell: bash -l {0}
run: |
conda install -c potassco clingo==5.5.2
conda install -c potassco clingo==5.6.2
- name: Conda install clingo-dl
shell: bash -l {0}
run: |
conda install -c potassco clingo-dl==1.3.0
conda install -c potassco clingo-dl==1.4.0
- name: Conda install clingcon
shell: bash -l {0}
run: |
conda install -c potassco clingcon==5.0.0
conda install -c potassco clingcon==5.2.0
- name: Build
run: |
export CLINGO_LIBRARY_PATH=/usr/share/miniconda/envs/test/lib
Expand All @@ -41,19 +41,19 @@ jobs:
- uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
python-version: ${{ 3.9 }}
- name: Conda install clingo
shell: bash -l {0}
run: |
conda install -c potassco clingo==5.5.2
conda install -c potassco clingo==5.6.2
- name: Conda install clingo-dl
shell: bash -l {0}
run: |
conda install -c potassco clingo-dl==1.3.0
conda install -c potassco clingo-dl==1.4.0
- name: Conda install clingcon
shell: bash -l {0}
run: |
conda install -c potassco clingcon==5.0.0
conda install -c potassco clingcon==5.2.0
- name: Build
run: |
export CLINGO_LIBRARY_PATH=/usr/local/miniconda/envs/test/lib
Expand Down
4 changes: 1 addition & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ edition = "2018"
publish = false

[dependencies]
clingo = "0.7.0"
clingo = "=0.8.0"
clingo-dl-plugin = { git = "https://github.com/potassco/clingo-dl-theory-rs", branch = "master" }
clingcon-plugin = { git = "https://github.com/potassco/clingcon-theory-rs", branch = "master" }
rocket = { version = "0.5.0-rc.2", features = ["json"] }
Expand All @@ -16,5 +16,3 @@ libloading = "0.7"
serde = "1.0"
serde_json = "1.0"
serde_derive = "1.0"


10 changes: 5 additions & 5 deletions src/utils.rs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
use clingcon_plugin::ConTheory;
use clingo::{
ast, control, ClingoError, Configuration, ConfigurationType, Control, Id, Model, Part,
ShowType, SolveHandle, SolveHandleWithEventHandler, SolveMode, SolverLiteral, Statistics,
StatisticsType, Symbol, SymbolicAtoms, TruthValue,
ast, control, ClingoError, Configuration, ConfigurationType, Control, DefaultCtx,
GenericSolveHandle, Id, Model, Part, ShowType, SolveHandle, SolveMode, SolverLiteral,
Statistics, StatisticsType, Symbol, SymbolicAtoms, TruthValue,
};
use clingo_dl_plugin::DLTheory;
type DLSolveHandle = SolveHandleWithEventHandler<DLEventHandler>;
type ConSolveHandle = SolveHandleWithEventHandler<ConEventHandler>;
type DLSolveHandle = GenericSolveHandle<DefaultCtx, DLEventHandler>;
type ConSolveHandle = GenericSolveHandle<DefaultCtx, ConEventHandler>;
use clingo::theory::Theory;
use rocket::response::{self, Responder};
use rocket::serde::json::Json;
Expand Down
2 changes: 1 addition & 1 deletion taskassignment.lp
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ seq((T2,ST2),(T1,ST1),Time2) :- assign(T1,ST1,M), assign(T2,ST2,M), T1<T2, execu
&diff{0-(T,M)} <= 0 :- task(T), machine(M), bound(B).
&diff{(T,M)-0} <= B :- task(T), machine(M), bound(B).

&show_assignment{}.
% &show_assignment{}.
#show.

% instance tai4_4_1.lp
Expand Down
Loading