-
Notifications
You must be signed in to change notification settings - Fork 17
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
Build fails after changes in modernjson #140
Comments
Do we get the same error message with pybind11_json included?
|
Using pybind11_json, the issue is fixed for double, but I still get the same error for RationalNumber. |
I believe that it is nice to not have an std::string for a json object and then the need to parse it. In particular, our json objects contain rational numbers and if we cast them to a string and then parse them, they will likely be a float. So, I guess there is value in having these bindings. Now my main problem is that I do not understand the error message. Looking up solutions for this error message brought me to https://en.cppreference.com/w/cpp/string/basic_string_view, but I dont know what to do with that. |
I also saw that we are using the json object quite often in stormpy and not just in a few isolated places (as I initially thought). So I agree that we want to keep this functionality. I am also not sure how to address this issue. I tried compiling Storm/stormpy with C++20 but this does not make a difference (or I need to do more than |
I might have found the issue:
note that |
Ah cool, that seems to be the root cause. Apparently the wrong |
Interestingly, the "wrong" |
@volkm Does upgrading it to the latest pybind version fix things? |
No, I tried pybind 2.11.1 from July, and it does not make a difference, same with the master branch which also has the same issue. |
The update of the modernjson library (see moves-rwth/storm#424) leads to build failures:
Adding the pybind11_json header file seems to resolve the problem for ValueType double, but not for RationalNumber.
A more general question could be whether we need Python bindings for the
storm::json
object or whether it would suffice to directly export json as string within C++.The text was updated successfully, but these errors were encountered: