Commit cd9291e
committed
fix: Make fields added in PR ocaml-sf#320 optional
This ensures learn-ocaml-client.master is still able to query a server
version learn-ocaml.0.12.
Minimal working example:
cd .../learn-ocaml
docker run --name=locaml -d -it -p 8080:8080 -v "$PWD/demo-repository:/repository" ocamlsf/learn-ocaml:0.12
TOKEN=$(docker logs locaml | grep -e 'Initial teacher token created:' | sed -e 's/^.*: //')
# then
git checkout 42d8127
opam install . --deps-only --locked -y
opam install -y opam-installer.$(opam config var opam-version)
eval $(opam env)
make
make opaminstall
learn-ocaml-client init -s http://localhost:8080 -t "$TOKEN"
touch demo.ml
learn-ocaml-client grade demo.ml
Output before the fix:
Fatal error: exception Json_encoding.Cannot_destruct(_)
Called from unknown location
Called from unknown location
Called from unknown location
Called from unknown location
Called from unknown location
Called from unknown location
Called from unknown location1 parent c00a3ab commit cd9291e
1 file changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
37 | 37 | | |
38 | 38 | | |
39 | 39 | | |
40 | | - | |
41 | | - | |
| 40 | + | |
| 41 | + | |
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
| |||
0 commit comments