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

help /// #5

Open
zzme110 opened this issue Jun 23, 2019 · 12 comments
Open

help /// #5

zzme110 opened this issue Jun 23, 2019 · 12 comments

Comments

@zzme110
Copy link

zzme110 commented Jun 23, 2019

An Error Has Occurred,when i ran this dode: dhitools/notebooks/dfs012_analysis.ipynb,
and my version of python is 3.7. (anconda) Can u help me solve this error?,thanks
error:
File "C:\ProgramData\Anaconda3\lib\site-packages\dhitools\dfs.py", line 45, in dfs_info
self.num_items = dfs_object.ItemInfo.Count
AttributeError: 'list' object has no attribute 'Count'

@famiuer
Copy link

famiuer commented Jun 23, 2019

Which version of SDK do you install? Which line does this error occur? I think this error comes from the SDK dependency settings.

@zzme110
Copy link
Author

zzme110 commented Jun 23, 2019

My sdk is 2019. I will check the mistake according to your suggestion tomorrow. My programming skills are poor. It took a long time and it was frustrating. Thank you for your help!

@maximlt
Copy link

maximlt commented Jun 23, 2019

Which version of pythonnet do you have?

@zzme110
Copy link
Author

zzme110 commented Jun 24, 2019

pythonnet 2. 4.0

@zzme110
Copy link
Author

zzme110 commented Jun 24, 2019

image

@zzme110
Copy link
Author

zzme110 commented Jun 24, 2019

I can run the program now, but I don't fully understand the principle. This time I used conda install -c pythonnet instead of pip install pythonnet and then it worked. I just wonder why conda install -c pythonnet pythonnet must be used.

@maximlt
Copy link

maximlt commented Jun 24, 2019

When you download pythonnet through the pythonnet channel, you get the 2.3 version, while you get the 2.4 version with pip. Different versions, hence different behaviours apparently, that's why your code broke.
If you prefer to use conda, you could download pythonnet on the conda-forge channel (conda install -c conda-forge pythonnet)

@zzme110
Copy link
Author

zzme110 commented Jun 24, 2019

Thank you ! and i want to know how can i get the information of sdk's methods or functions ? Because I want to make some other tools.

@zzme110
Copy link
Author

zzme110 commented Jun 27, 2019

The mistake happened again, After my test, the attribute of iteminfo cannot be explained, The pythonnet 2.4.0 has been installed and other uninstalled. I used the anconda running it . I retested it on a different computer and got the same result

@zzme110
Copy link
Author

zzme110 commented Jun 27, 2019

I found the answer that 2.4 version leads this error.

@ywh641952
Copy link

@robjameswall @maximlt @zzme110 @Felix-James which tech guru can send me the MIKE 2019 SDK

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

4 participants