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

Easy way to get result.Result as JSON/XML? #15

Open
dilawar opened this issue Feb 2, 2025 · 0 comments
Open

Easy way to get result.Result as JSON/XML? #15

dilawar opened this issue Feb 2, 2025 · 0 comments

Comments

@dilawar
Copy link

dilawar commented Feb 2, 2025

Following program prints result in plain text format.

from ratesb_python import check_model

result = check_model("S->P;k1*S")
print(type(result), result)
<class 'results.Results'> _J0:
  Warning 1004: Flux is not decreasing as product increases.

For many developers/users of this package, especially at cli, it would also be very useful to see result.Results as JSON or XML or any other structured format. If you plan to add this functionality, perhaps it can also be highlighted in the documentation. I believe that a json dump will also be useful when using this package as library and not just at CLI.

Ref: openjournals/joss-reviews#7618

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

1 participant