Tend to your personal relationships like a garden, especially when you're younger since it becomes much more difficult to establish meaningful relationships the older you get. It's only my experience, but that is my greatest regret. I think the less important things like career are more easily tackled with a solid foundation of personal relationships.
Also, I've found striving for perfection is fool's gold. Yeah, you may be "that person" that friends/family/colleagues will love name-dropping you every chance they get. The others will probably care little that you're an expert and may even resent you for it.
Throwing this out there for criticism... I use `python3 -m pip install -t .pip -r requirements.txt` and add .pip to my PYTHONPATH. That works for me without having to use any of the python virtual env tooling, basically trying to get something more npm like.
I don't work on any significant python code bases, so I expect it has limitations when compared to the virtual env options like developing with specific (or multiple) python versions.
Hm, this sounds like something I would want to use, but I just tried it with an Ubuntu Bionic server on Dreamhost (Python 3.6) and got an exception installing flask and flup:
distutils.errors.DistutilsOptionError: can't combine user with prefix, exec_prefix/home, or install_(plat)base
I don't understand why this doesn't work, but it seems like it should.
I was able to install those 2 packages in a virtualenv (although weirdly Dreamhost requires you to build your own Python 3 to do that, python3 -m venv doesn't work)
I've been programming Python since 2003 and have no idea what's wrong :-(
TBH I thought I was a luddite for avoiding virtualenv and pip for a long time. I would downloads tarballs and use distutils to build them! But for this project I'm using flask which has more dependencies... Gah. And now I'm seeing all the downsides...
Want more positive cases? Use a higher threshold. Want to scare the population into compliance? Use a higher threshold. Want to demonstrate that person X or policy Y was effective against stopping spread? Use a lower threshold.
Killer keyboard feature for me is ~/Library/KeyBindinds/DefaultKeyBinding.dict - all text controls honor that. Very nice way to get basic emacs shortcuts defined. I've yet to find something half as simple & effective as that in linux desktop land, probably because of the variety of gui toolkits that isn't present in osx.
> If you're going to rely on a fancy shell anyway, why not just throw make out of the loop altogether?
I think can still add value in that scenario as the standard project entrypoint. Someone completely new to the project should be able to `make help`, `make install`, etc. Even if the make targets are simple wrappers to project specific tooling (npm, pip, sbt, etc). If the Makefile is kept simple, then users can treat it as a form of README and should be able to cherry-pick from it as they see fit.
But yeah, I share your sentiment about quirky, non-portable Makefiles potentially being anti-value.
I certainly like it when I encounter a new project, type make, and it just works.
This is rare these days.. honestly at this point there's so much tooling already around that one can't really ever take that for granted. Almost always, I need to look for some readme or look around and figure out what build system is in use (sometimes it's a common system plus custom stuff so just seeing a name you recognize isn't automatically going to mean the standard invocation will work).
In this case, it hardly matters whether I'm going to run make or ./build or make help or ./build help. A simple script, which I'm advocating for simple projects, can double as a form of README just as a Makefile can.
Perhaps it's just a factual element. Or perhaps the intention is `s/python/pragmatic/`. Yeah, python sucks in many ways but is it really so horrible? I know! Let's ask the reader to get intimate with a static compiler. If they're "smart" enough to satisfy (or trick) the compiler, then they've earned the "reward" of being able to execute their program.
There is value is static typing, but there are many instances where that cost is not worth the reward.
I think the grandparent poster was just pointing out that this post has very little to do with python or matplotlib, with the code to generate the plots just thrown in as an afterthought at the end. Which makes it weird to have them in the title. (Whether python is a good tool or not is unrelated to this observation.)
I would expect a post entitled “exploring mathematics with python” to have a whole lot more python code (inline with the text and better explained instead of an uncommented blob at the end) and a whole lot more mathematics.
A more accurately descriptive title for this post might be “counting the repetitions among randomly chosen positive integers”.... which of course isn’t going to get as many clicks or as many reflexive upvotes from non-readers as a post promising “exploring mathematics with python” because it doesn’t sound (and frankly isn’t) all that interesting to most readers. (It might make a decent short project for middle school students though.)
Personally I flagged the post for its misleading title.
What I got out of the post was that exploratory and experimental mathematics is fun and worthwhile and if you haven't tried it, you should, and by the way, this experiment uses Python and matplotlib (which some readers may already know). I think you missed the point of the article.
Every in the title is a major part of the article. The author used Python's matplotlib to investigate mathematics, and share both the math and the Python code.
It's not the author's fault if you bring your own baggage to the words.
> If they're "smart" enough to satisfy (or trick) the compiler, then they've earned the "reward" of being able to execute their program.
This is needlessly dismissive and frankly offensive.
I prefer having errors from a compiler(or static analysis, or...) because it helps me. Not because I am a better programmer but because it helps me be a better programmer.
> Compiler: Hey that type doesn't work there
Oh! Thank you! I meant to use this type instead.
> Compiler: This value is freed here but used right afterward here
I meant to clone it. Whoops. That would have been embarrassing to debug in production!
And so on.
I absolutely recognize that it's a barrier to entry, but it's not one erected to keep people out, it's there to catch your mistakes for you so that you spend less time debugging and more time writing your actual application.
> It's also needlessly dismissive to write as if everyone using Python is making a mistake.
That's true. If I start doing that, please call me out on it. From the HN Guidelines:
> Please respond to the strongest plausible interpretation of what someone says, not a weaker one that's easier to criticize. Assume good faith.[0]
I'm very much not a fan of meaningful whitespace, but I use Python occasionally, and regularly help my friends who are learning it grasp this or that topic. Except where pointing them to a specific library or other tool, I've never said "You shouldn't do that in Python, do it in this other language instead".
I apologize if I misinterpreted what you wrote. It seems you just meant to criticize the title, or...? I'm actually not sure what your above comment was getting at. Sorry if I missed your point.
> I'm actually not sure what your above comment was getting at. Sorry if I missed your point.
I was responding specifically to the content that I quoted, which came from the post that I replied to.
> It seems you just meant to criticize the title, or...?
I should note that I am not the person who started this comment thread.
They were criticizing the post title as they did not believe that the contents within were specific to Python.
They were not criticizing Python either. Rather they were saying that the word Python in the title appears to be used to attract viewers who might otherwise be intimidated by the contents, instead of being relevant to the contents of that article.
I see! Thanks. What I meant to say was that the "'smart' enough" comment seemed to me to be meant in a jocular way and should not be something to take offence at. However, I did indeed misread the thread flow.
My approach is to copy, paste, & tailor the programmable completion for a command that has similar interface to my mine. Can try browsing /usr/local/share/bash-completions/completions or `set` & search for _FOO. Hopefully the special variables like COMPREPLY will be self-explanatory. Also `help compgen`. I'm assuming bash, by the way.
Try `PYTHON -m MODULE` as in `python3 -m pip` if you want to make sure to use python3's pip, `python2 -m pip` for python2, `~/bin/python -m pip` for a personal python install, etc.
Also, I've found striving for perfection is fool's gold. Yeah, you may be "that person" that friends/family/colleagues will love name-dropping you every chance they get. The others will probably care little that you're an expert and may even resent you for it.