Hi,
We updated Eviews 13 with the "Patch Date : 2024-01-08", but now we can`t run our python codes with the PYEVIEWS library (function GETFASPYTHON is not working anymore). Could you please update your pyeviews library asap, some important processes depend on our python codes for business.
df_data = evp.GetWFAsPython(app=eviewsapp, wfname=dict_inf['wf_name'],pagename=dict_inf['page_name'],namefilter=dict_inf['name_filter'])
File ~\AppData\Local\anaconda3\lib\site-packages\pyeviews\__init__.py:422 in GetWFAsPython
app.Run('string ' + str(tempvar) + ' = ' + str(var).strip() + '.@attr("' + str(attr) + '")')
COMError: (-2147221490, 'compobj.dll is too old for the ole2.dll initialized', ('Syntax error in "STRING TEMP = AUDUSD.@ATTR(""SECURITY")".', 'EViews.Application.13.Run', None, 0, None))
It is this section of the "__init__.py" :
# get all attribute names
for var in names:
attrnames = app.Get('=@attrnames("*", "' + str(var) + '")').split()
if attrnames and not ispanel:
attrvals = []
for attr in attrnames:
tempvar = app.Get('=@getnextname("TEMP")')
app.Run('string ' + str(tempvar) + ' = ' + str(var).strip() + '.@attr("' + str(attr) + '")')
attrvals.append(app.Get(str(tempvar)))
app.Run('delete ' + str(tempvar))
data.attrs.update(dict(zip(attrnames, attrvals)))
# close the workfile
#app.Run("wfclose")
return data
Regards,
LC
Pyeviews not working with new eviews 13 update
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
Pyeviews not working with new eviews 13 update
Last edited by leocaza on Tue Jan 09, 2024 1:47 pm, edited 3 times in total.
Re: Pyeviews not working with new eviews 13 update
We are on python 3.9.18 or 3.9.12 (coworkers)
Re: Pyeviews not working with new eviews 13 update
Hi,
If there is no feedback until next week, we will just have to "cancel" Pyeviews and run with CSVs all over our processes. I don't know yet if I need to consider this. We will see... Plan A, Plan B... The @Tic @Toc of business, of busyness.
Regards,
LC
If there is no feedback until next week, we will just have to "cancel" Pyeviews and run with CSVs all over our processes. I don't know yet if I need to consider this. We will see... Plan A, Plan B... The @Tic @Toc of business, of busyness.
Regards,
LC
-
- EViews Developer
- Posts: 821
- Joined: Tue Sep 16, 2008 3:00 pm
- Location: Irvine, CA
Re: Pyeviews not working with new eviews 13 update
Sorry, I didn't see this until now. I'll take a quick look to see if I can replicate it.
By the way, do you also have any other older versions of EViews (such as 12 or 11) on your machine?
By the way, do you also have any other older versions of EViews (such as 12 or 11) on your machine?
-
- EViews Developer
- Posts: 821
- Joined: Tue Sep 16, 2008 3:00 pm
- Location: Irvine, CA
Re: Pyeviews not working with new eviews 13 update
Ok i did some quick testing in a brand-new Anaconda environment using the following:
and my call to GetWFAsPython works as expected. If you're comfortable sharing your source workfile, please send that to me in an email to steve@eviews.com and provide the wfname, pagename, and namefilter string values you were using in your call to GetWFAsPython so i can try to replicate the issue.
Otherwise, I would double-check your package versions and make sure you update any that are out of date (in particular the comtypes package). Once updated, try running your python script again. Even better would be to create a new Anaconda environment yourself with just these libraries and see if the error continues.
If you're sure this worked before you installed the latest EViews 13 patch, try down-grading to see if that resolves the issue for you. You can find the previous 2 patches here:
Dec 19, 2023 build: https://cdn2.eviews.com/EViews13Patch_121923.exe
November 28, 2023 build: https://cdn2.eviews.com/EViews13Patch_112823.exe
Steve
Code: Select all
Conda 23.11.0
Python 3.9.18 64-bit
pyeviews 1.0.5
numpy 1.26.3
pandas 2.1.4
comtypes 1.1.14
EViews 13 build date Jan 8, 2024
Windows 11 Pro x64
Otherwise, I would double-check your package versions and make sure you update any that are out of date (in particular the comtypes package). Once updated, try running your python script again. Even better would be to create a new Anaconda environment yourself with just these libraries and see if the error continues.
If you're sure this worked before you installed the latest EViews 13 patch, try down-grading to see if that resolves the issue for you. You can find the previous 2 patches here:
Dec 19, 2023 build: https://cdn2.eviews.com/EViews13Patch_121923.exe
November 28, 2023 build: https://cdn2.eviews.com/EViews13Patch_112823.exe
Steve
Who is online
Users browsing this forum: No registered users and 1 guest