dpinney / omf

The Open Modeling Framework for smart grid cost-benefit analysis.
https://omf.coop
GNU General Public License v2.0
112 stars 60 forks source link

Rebuild a source distribution package at the end of GOSED #288

Closed cshjin closed 9 years ago

cshjin commented 9 years ago

It should have different versions in dist folder.

dpinney commented 9 years ago

FYI, wiki has full documentation on packaging: https://github.com/dpinney/omf/wiki/Packaging-the-OMF-for-Distribution-(PyPI,-etc.)

PoojaSan commented 9 years ago

In existing setup.py file, install_requires is used to list the dependencies from requirements.txt. The code: install_requires = open("requirements.txt").readlines(),

When I print this list, it has new line character in each dependency name. This could have been a problem. A fix to strip new line characters : a lambda function can be used - reqmt_list = map(lambda s: s.strip(), reqmt_list) Working on this.

dpinney commented 9 years ago
with open('requirements.txt','r') as inFile:
    x = inFile.read().split('\n')
PoojaSan commented 9 years ago

Hi David, I am trying to test the installation on windows VM. What about this change that we made(ref : previous comment) Do I just check-in that change and then get the latest from github to test installation?

PoojaSan commented 9 years ago

Testing installation on Windows VM. Getting error while installing numpy. The issue is duplicate of https://github.com/numpy/numpy/issues/1458

Searching possible solutions for this.

PoojaSan commented 9 years ago

Installed numpy using pip. After installation,upon running web.py, getting following error:

C:\Users\Asus\Desktop\omf-0.2\omf>python web.py Traceback (most recent call last): File "web.py", line 8, in import models, feeder, milToGridlab File "C:\Users\Asus\Desktop\omf-0.2\omf\modelsinit.py", line 14, in <modu le> for name in all: exec('import ' + name) File "", line 1, in File "C:\Users\Asus\Desktop\omf-0.2\omf\models\cvrStatic.py", line 16, in <mod ule> from solvers import gridlabd File "C:\Users\Asus\Desktop\omf-0.2\omf\solversinit.py", line 13, in <mod ule> for name in all: exec('import ' + name) File "", line 1, in File "C:\Users\Asus\Desktop\omf-0.2\omf\solvers\nrelsaminit.py", line 15, in class SSCAPI: File "C:\Users\Asus\Desktop\omf-0.2\omf\solvers\nrelsaminit.py", line 21, in SSCAPI _dll = CDLL(os.path.join(myDir,"ssc32.dll")) File "C:\Python27\lib\ctypesinit.py", line 365, in init self._handle = _dlopen(self._name, mode) WindowsError: [Error 126] The specified module could not be found

PoojaSan commented 9 years ago

Hi David, Can you suggest what may be the cause of this problem?

dpinney commented 9 years ago

It appears you don't have NREL's SAM installed. https://sam.nrel.gov.

PoojaSan commented 9 years ago

No David, I have SAM installed. Looks like its the same problem of C:\Program Files (x86) in path not being recognized after SAM installation. Unfortunately I have forgotten what was my fix last time I got this problem. I am looking for a new fix.

PoojaSan commented 9 years ago

Still the same error. Tried some fixes. Ref: https://sam.nrel.gov/content/sscdll-load-error

dpinney commented 9 years ago

After finding out there's no way to get pip to install some of our requirements, and that the git clone installation path is very fast, let's drop support for the .zip package installation.

I'm updating the install instructions to make them a lot clearer.

Eventually, supporting a set of .exe/.deb/.rpm installation packages could be useful. But not now.

cshjin commented 9 years ago

Maybe one suggestion, you could create a release tag there https://github.com/dpinney/omf/releases if possible and provide a zip file under the release tab seems nice.

dpinney commented 9 years ago

Better to put a set of .exe/.deb/.rpm there. The ultimate goal is one click install.