-
Notifications
You must be signed in to change notification settings - Fork 35
Patches for pdf docs, Pyrex compatibility, dir()/help() fixes #1
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
Open
balajis
wants to merge
3
commits into
cjlee112:master
Choose a base branch
from
balajis:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Do ``cd doc; make`` and open ``doc/latex_new/Pygr.pdf``.
cnestedlist.pyx and cdict.py. Also updated .gitignore to exclude build targets intervaldb.o and libnclist.a. This patch fixes setup.py, which was giving the following output on Mac OS X 10.6 (included below for those with the same error): {{{ $ python setup.py --verbose build running build running build_py not copying pygr/__init__.py (output up-to-date) not copying pygr/annotation.py (output up-to-date) not copying pygr/blast.py (output up-to-date) not copying pygr/classutil.py (output up-to-date) not copying pygr/coordinator.py (output up-to-date) not copying pygr/Data.py (output up-to-date) not copying pygr/dbfile.py (output up-to-date) not copying pygr/downloader.py (output up-to-date) not copying pygr/graphquery.py (output up-to-date) not copying pygr/logger.py (output up-to-date) not copying pygr/mapping.py (output up-to-date) not copying pygr/metabase.py (output up-to-date) not copying pygr/nlmsa_utils.py (output up-to-date) not copying pygr/parse_blast.py (output up-to-date) not copying pygr/schema.py (output up-to-date) not copying pygr/seqdb.py (output up-to-date) not copying pygr/sequence.py (output up-to-date) not copying pygr/sequtil.py (output up-to-date) not copying pygr/sqlgraph.py (output up-to-date) not copying pygr/translationDB.py (output up-to-date) not copying pygr/xnestedlist.py (output up-to-date) not copying pygr/apps/__init__.py (output up-to-date) not copying pygr/apps/catalog_downloads.py (output up-to-date) not copying pygr/apps/leelabdb.py (output up-to-date) not copying pygr/apps/maf2nclist.py (output up-to-date) not copying pygr/apps/maf2VSgraph.py (output up-to-date) not copying pygr/apps/seqref.py (output up-to-date) not copying pygr/apps/splicegraph.py (output up-to-date) not copying pygr/apps/ucsc_ensembl_annot.py (output up-to-date) running build_ext skipping 'pygr.seqfmt' extension (up-to-date) pyrexc pygr/cdict.pyx --> pygr/cdict.c ~/pygr/pygr/cdict.pyx:95:4: __new__ method of extension type will change semantics in a future version of Pyrex. Use __cinit__ instead. ~/pygr/pygr/cdict.pyx:160:4: __new__ method of extension type will change semantics in a future version of Pyrex. Use __cinit__ instead. ~/pygr/pygr/cdict.pyx:212:4: __new__ method of extension type will change semantics in a future version of Pyrex. Use __cinit__ instead. ~/pygr/pygr/cdict.pyx:261:4: __new__ method of extension type will change semantics in a future version of Pyrex. Use __cinit__ instead. ~/pygr/pygr/cdict.pyx:407:4: __new__ method of extension type will change semantics in a future version of Pyrex. Use __cinit__ instead. ~/pygr/pygr/cdict.pyx:212:22: Warning: 'not None' will become the default in a future version of Pyrex. Use 'or None' to allow passing None. building 'pygr.cdict' extension gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c pygr/cgraph.c -o build/temp.macosx-10.6-intel-2.7/pygr/cgraph.o gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c pygr/cdict.c -o build/temp.macosx-10.6-intel-2.7/pygr/cdict.o pygr/cdict.c:1:2: error: #error Do not use this file, it is the result of a failed Pyrex compilation. pygr/cdict.c:1:2: error: #error Do not use this file, it is the result of a failed Pyrex compilation. lipo: can't figure out the architecture type of: ~/tmp/ccWaoUlh.out error: command 'gcc-4.2' failed with exit status 1 }}} There is still a separate warning on the 'or None' argument: {{{ $ python setup.py build --verbose running build running build_py running build_ext pyrexc pygr/cnestedlist.pyx --> pygr/cnestedlist.c ~/pygr/pygr/cnestedlist.pyx:167:42: Warning: 'not None' will become the default in a future version of Pyrex. Use 'or None' to allow passing None. building 'pygr.cnestedlist' extension gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c pygr/intervaldb.c -o build/temp.macosx-10.6-intel-2.7/pygr/intervaldb.o gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c pygr/cnestedlist.c -o build/temp.macosx-10.6-intel-2.7/pygr/cnestedlist.o gcc-4.2 -fno-strict-aliasing -fno-common -dynamic -arch i386 -arch x86_64 -g -O2 -DNDEBUG -g -O3 -I/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c pygr/apps/maf2nclist.c -o build/temp.macosx-10.6-intel-2.7/pygr/apps/maf2nclist.o gcc-4.2 -arch i386 -arch x86_64 -isysroot / -g -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -isysroot / -g build/temp.macosx-10.6-intel-2.7/pygr/intervaldb.o build/temp.macosx-10.6-intel-2.7/pygr/cnestedlist.o build/temp.macosx-10.6-intel-2.7/pygr/apps/maf2nclist.o -o build/lib.macosx-10.6-intel-2.7/pygr/cnestedlist.so }}} Essentially, Pyrex has a transition period where every argument needs to be explicitly declared with 'or None' or 'not None'. This is because the default is currently 'or None', but it will be changed to 'not None'. Explicit declarations will work either way. See: http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/version/Doc/Release_Notes_0.9.9.html
…-the-box. Root cause of the dir() issue was that defaultPath was not getting inspected, which broke expectations set by the tutorial. Root cause of the help() issue is the __getattr__ method in ResourcePath, which did not return a string when asked for __name__ by the help method.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi Chris,
I'm a friend of Titus' and made a few quick changes that significantly increased the out-of-the-box usability of pygr for me.
With these changes, I think people should be able to run the tutorial "as is". Will tell you if that's not the case.