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

possible pyecharts compatibility sulotion for all python versions #182

Merged
merged 2 commits into from
Apr 1, 2024
Merged

possible pyecharts compatibility sulotion for all python versions #182

merged 2 commits into from
Apr 1, 2024

Conversation

qwerty258
Copy link
Contributor

@qwerty258 qwerty258 commented Mar 23, 2024

Force install pyecharts 1.9.1 in python 3.11.8 venv, the module worked fine as code below:

#!/usr/bin/env python3

import xalpha

def main():
    info=xalpha.fundinfo("000692")
    print(info)
    print(info.info())
    print(info.price[info.price['date']<='2015-01-01'])
    info.v_netvalue()

if __name__ == "__main__":
    main()

This is a possible solution for issue #173

@refraction-ray
Copy link
Owner

I run the pytest with pyecharts 1.9.1 and find one api compatibility issue

>       bar.add_yaxis(series_name="买入", yaxis_data=buydata)
E       TypeError: add_yaxis() got an unexpected keyword argument 'yaxis_data'

the "yaxis_data" was changed to "y_axis" from pyecharts 1.7.1 to 1.9.1,
but the parameter position did not change
@qwerty258
Copy link
Contributor Author

qwerty258 commented Mar 29, 2024

The parameter keyword yaxis_data was changed to y_axis from pyecharts 1.7.1 to 1.9.1.

Hopefully pyechats will maintain parameter position compatibility.

This will be a temporary fix for python3.9+

@refraction-ray refraction-ray merged commit b37e2fc into refraction-ray:master Apr 1, 2024
@refraction-ray
Copy link
Owner

thanks for the contribution, will take this as a temporary workaround

@qwerty258 qwerty258 deleted the pyecharts-compatibility branch April 1, 2024 08:57
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

Successfully merging this pull request may close these issues.

2 participants