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

Error loading 'pyutilib.component' entry points: 'type object 'PluginGlobals' has no attribute 'push_env #58

Closed
eli241 opened this issue Aug 2, 2017 · 6 comments

Comments

@eli241
Copy link

eli241 commented Aug 2, 2017

Hi
I am trying to use OptiType and get the error:

Error loading 'pyutilib.component' entry points: 'type object 'PluginGlobals' has no attribute 'push_env''
Traceback (most recent call last):
File "OptiTypePipeline.py", line 124, in
from model import OptiType
File "/home/usr/OptiType/model.py", line 19, in
from pyomo.environ import ConcreteModel, Set, Param, Var, Binary, Objective, Constraint, ConstraintList, maximize
File "/home/python2.7/site-packages/pyomo/environ/init.py", line 14, in
from pyomo.core import *
File "/home/python2.7/site-packages/pyomo/core/init.py", line 11, in
from pyomo.util.plugin import PluginGlobals
File "/home/python2.7/site-packages/pyomo/util/init.py", line 11, in
from pyomo.util._task import pyomo_api, PyomoAPIData, PyomoAPIFactory
File "/home/python2.7/site-packages/pyomo/util/_task.py", line 21, in
import pyutilib.workflow
File "/home/python2.7/site-packages/pyutilib/workflow/init.py", line 11, in
pyutilib.component.core.PluginGlobals.push_env("pyutilib.workflow")
AttributeError: type object 'PluginGlobals' has no attribute 'push_env'

All dependencies are already installed
Thanks for the help
Eli

@b-schubert
Copy link
Contributor

Hi Eli,

could you tell us which versions of the python package you are using, in particular Pyomo?

Best,
Benni

@eli241
Copy link
Author

eli241 commented Aug 6, 2017 via email

@b-schubert
Copy link
Contributor

Sorry for responding so late.

I couldn't reproduce the error. I tested the specification on a new virtual Python environment but the simple test files all ran through...

Have you tried setting up a clean Python environment? If that does not work either, you could use our Docker container.

@eli241
Copy link
Author

eli241 commented Aug 27, 2017

Thanks for the reply.
I managed to fix this problem but now I have a new one of "No executable found for solver 'glpk'".
Still trying to solve it if you by any chance have any idea.

Best,
Eli

@b-schubert
Copy link
Contributor

This probably means that the Path to the GLPK binary has not been added to the PATH variable of your system.

Can you execute GLPK on the command line, if you type in glpsol ?

@eli241
Copy link
Author

eli241 commented Sep 5, 2017

Yep. It finally works!
The problem was with the glpk version. I updated it to 4.61 and the errors stopped.
Thanks a lot

@eli241 eli241 closed this as completed Sep 5, 2017
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

2 participants