-
Notifications
You must be signed in to change notification settings - Fork 10
Support Graphviz installed from Anaconda #52
base: master
Are you sure you want to change the base?
Conversation
d9325bc
to
9fee210
Compare
@leycec Could you look at it? I must admit that I didn't use conda so if you can quickly test it, let me know if this is correct solution. In the meantime I'll try to prepare some CI jobs for using pydot-ng with Conda (any known projects that can I use as an inspiration?). |
Humble apologies for the half-month delay, @prmtl. My awesome father-in-law unexpectedly passed away several hours before you submitted this request and, well... cue sad face emoji. The approach you've taken here should, in theory, work. That said, it's not necessarily ideal. That said, the perfect is the enemy of the good. That said, I'm a perfectionist. Building Utopia TogetherIn a perfect world, you wouldn't bother iteratively testing filetypes. Why? Because you don't need to. Also, because you absolutely shouldn't. POSIX-compatible platforms signify executability via the executable bit (e.g., Likewise, Windows users preferring Therefore, the filetype you want is a deterministic function of the current platform + Python environment. Specifically, if the current platform is:
No iteration required. A single Code or It Didn't HappenVery well. You should now be quietly thinking to yourself: "Yes, but everything you've said assumes we can efficiently and reliably test whether the current Python environment is Anaconda-based or not. Can we?" Fear not: we can. Sadly, I'd forgotten how. Happily, I remembered that I already solved this half a year ago (it feels like a lifetime) in a farcical comment chain at ContinuumIO/anaconda-issues#1666. It turns out that a single filesystem access suffices to decide this question:
Given that boolean, your
Boom. When the comments are twice as long as the actual code, @leycec was here. Anaconda for Great Justice
Why, yes, actually: ours. I note that The classic example is Python's scientific stack: NumPy, SciPy, Matplotlib, Pandas, TensorFlow, and so on. Whereas Anaconda's NumPy package is linked against Intel's highly optimized Math Kernel Library (MKL) on all supported platforms (including Windows), NumPy's official binary wheel is only linked against ATLAS' less performant BLAS and LAPACK implementations constrained to SSE2 instructions. Anaconda trivially circumvents these issues. Transitioning your AppVeyor configuration from Should you choose to accept this rewarding mission, the general approach is as follows: requirements-conda.txtAdd a new top-level
Since this is More importantly, whitespace is significant. Ergo, appveyor.ymlSo, you already have an Appveyor configuration. That's great! Sadly, you'll need to completely rewrite it from the ground up to support On the bright side, "completely rewrite it from from the ground up" just means "liberally copy-and-paste somebody else's." Here's ours, for example... complete with verbose commentary guaranteed to make your head explode like a jelly-filled piñata on the Day of the Dead. Our test suite even uses Quotes... from HellLet's get pedantic. You really don't want to reinvent the wheel by attempting to manually implement shell escaping, quoting, and unquoting – especially under Windows, where the syntactic ruleset is infamously inhumane. You'll never get it quite right in a genuinely portable manner. But you don't need to. Whenever you want to munge a string for consumption by a shell interpreter, defer to the existing
Please steal this. Also, you mispelled "qouted;" it's "quoted." shoot me now All's Well that EndsThus ends another doctoral thesis masquerading as GitHub commentary. In reflection, I regret nothing. |
Thanks for the response! I really appreciate it. And I'm sorry for your loss. I just quickly went through it and I found a LOT of new info about Windows & Anaconda. I'll slowly go through them later, read more about the topic and reimplement PR. |
You're most welcome. My wife and I gratefully appreciate the outpouring of support. You're awesome! Since (A) you're awesome, (B) Anaconda now defaults to Python 3.7, (C) Fate has tipped my gnarled arthritic hand. Big Plans for Big MenI accidentally became an idiot savant at all things Anaconda several months ago. Notably, I'm a co-maintainer on the conda-forge
That's just how we roll. But... Why conda-forge?It's a fair question. There already exists an official Anaconda package for
My paternal advice is to stridently ignore the existing Anaconda tl;drI create conda-forge Good plan? Bad plan? A little bit of both? Cogitate and let me know! Until then, thanks for all the volunteerism and have a raucous post-Halloween weekend. 🎃 |
Don't worry too much about my PRs, I'm not using pydot myself, rather helping out with Python upgrades for some of the most-downloaded PyPI packages. Pydot has half a million a month: |
9fee210
to
8f5d826
Compare
Graphviz installed using Conda is using .bat scripts to correctly setup running it on Windows.
8f5d826
to
c8fe7ce
Compare
Thanks for the sacrificial volunteerism, @hugovk! I hate to be the lone pallbearer of sad news, but... erocarrera/pydot is unofficially dead. The sole maintainer, Ioannis Filippidis (@johnyf), went "dark" shortly after completing his doctoral thesis. Dr. Filippidis ceased all online activity at the same exact time. Prior to April 2018, he was heavily active on GitHub, StackOverflow, and Twitter; as of April 2018, he abruptly disappeared from all three sites. According to LinkedIn, he's currently a postdoctoral researcher with Inria. This is a mild relief. He doesn't appear to be physically dead, which is good – only completely inactive online, which is bad. (See pydot/pydot#183 for prior discussion.) In the meanwhile, no one else has push access to erocarrera/pydot. I wouldn't bother posting any further issues or pull requests to that repository. All contributions are being redirected towards Let us shed a collective tear for the Python graphing library that might have been. 😢 |
Ah, so this repo is a fork? It wasn't clear to me. @erocarrera: do you have push access to https://github.com/erocarrera/pydot? At least Ero is a maintainer at https://pypi.org/project/pydot/ And looks like there's a handful of forks! "pydot" is still the most popular: |
I do have push access to https://github.com/erocarrera/pydot anybody wants to jump in? let me know if I need to point pydot in pypi to a working fork or if anybody wants to step in as a maintainer. |
OMG. The Master awakens from his slumber. We've been desperately trying to contact you and @johnyf for the past several months. So, this is a wondrously unexpected development. Thanks for responding so promptly... and invitingly. What do you think, @prmtl? Are you up for maintaining the official
It is good, yes? @erocarrera would retain most (...all?) permissions, @prmtl would receive new administrator permissions, and all existing issues, pull requests, and wiki pages would be preserved as is. If Sebastian Kalinowski (@prmtl) is willing and able, he has my vote for new Go, Team PyDot! Go! |
Good plan! Let me know when I can proceed with the transfer of ownership. |
Sounds like a plan! I really prefer to maintain I've invited @erocarrera and @leycec to the organisation and enabled permission that allow members to create repositories. |
Thanks! |
@erocarrera I think that you should transfer it to |
It should be done, I've transferred it to the |
Awesome! |
Update: I've merged fix for Python 3.7 and dropped support of Python 2.6. Now I'm ready to make a release. I've just need permissions to pydot's PyPI. |
Graphviz installed using Anaconda is using .bat scripts
to correctly setup running it on Windows.