Structure learning for numerical type of data

Bellow I have some code, where the code works with categorical data but produces the error (for the numerical data): Error in data.type(x) : variable chas is not supported in bnlearn (type: integer).

How can I apply Structure learning for numerical type of data

#This does work
library(bnlearn)
bn_df <- data.frame(coronary)
res <- hc(bn_df)
plot(res)
#This does not work
library(MASS)
attach(Boston)
res <- hc(Boston)
plot(res)