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

[BLOAD2] #42

Closed
m-alex-n opened this issue Apr 5, 2021 · 2 comments
Closed

[BLOAD2] #42

m-alex-n opened this issue Apr 5, 2021 · 2 comments

Comments

@m-alex-n
Copy link

m-alex-n commented Apr 5, 2021

The error => [BLOAD2] File book.clp is not a binary construct file.


The code.

from clips import Environment, Symbol

env = Environment()

env.clear()

env.load('book.clp')

env.facts()

env.run()



book.clp file

(deftemplate book
(multislot surname)(slot name)(multislot title)
)

(deffacts initial
(book (surname J.P.)(name Dubreuil)(title History of francmasons))
(book (surname T.)(name Eker)(title Secrets of millionaire mind)))

(defrule find_title
?book<-(book(name Eker))
=>
(printout t ?book crlf)
)


@noxdafox
Copy link
Owner

noxdafox commented Apr 5, 2021

Do you actually get an exception or is it just a log line?

The engine tries first to load it as binary file and then as text file. In certain environment, a spurious message [BLOAD2] File book.clp is not a binary construct file. might show up. Nevertheless, the constructs were actually loaded correctly.

@noxdafox
Copy link
Owner

clipspy 1.0.0 supports an improved load logic which allows to choose whether a file is in binary format or not rather than trying to guess it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants