skysight-inc/HackerNews huggingface dataset:
No, it goes beyond taste. The inability to reliably cut-and-paste example code and the total mess you get when people have combined spaces and tabs which could result in ambiguous code is a danger that could have been side-stepped quite handily.

It's like driving on the autobahn without guardrails. You may only need them once or twice in your life and yet, you're happy the guardrails are there. Just in case.

Allowing both tabs and spaces was simply a mistake but it is too late to turn the clock back on that now.

http://wiki.c2.com/?PythonWhiteSpaceDiscussion

In general, significant whitespace isn't fantastic but at least now we have widespread version control which helps in case of accidental deletion/insertion of a space or a tab or a newline.
Competitive programming is good practice and makes you a better programmer if you solve the problem before you start writing any code and then just implement your solution to prove that it works. This creates good habits and also shows you how trivial it is to implement something once you know what to do.
Phoenix flights cancelled because it's too hot for planes
Exactly, decorators are just a syntaxic sugar for foo = bar(foo). Nothing bad about it.
While I understand why you changed the link, I don't completely agree with the executive action.

I don't like having my name attached to a link I didn't want shared. Vice is a high-quality publication, and it brought a compelling angle to the iFixit review. As the OP, I wanted to share the Vice article (which links to the iFixit review).
Happy customer of Jetbrains as well, they make great IDEs if you have lots of RAM to spare.
Hah.

It's not just HN. When I talk to other companies I often get asked "are you in the Valley or the city?" Answer: we are in SoCal, so keep going South. Sometimes they are surprised, though they seem to find it reassuring that we're still in California. If we were in Texas or North Carolina I could see that being disorienting to some people.
Abolishing Switch-Case Statement and Pattern Matching in C# 7.0
That's the opposite of the spectrum.
I've noticed a new phenomena when it comes to posts on HN that criticize or complain about something I like. I find myself really drawn to it because I know that the comments will have people respectfully disagreeing and proposing alternatives that have a high chance of being useful to others. I used to downvote those kinds of posts on reddit back in the day, but this community makes disagreement progressive. You guys rock.
I have seen some ridiculous templates in C++. Isn't STL Turing complete?
Stack Clash flaws blow local root holes in loads of top Linux programs
Don't most major cities in the US (and the world) have dozens of these?
I don't know about OP but you don't even need to go to the level of checked exceptions, with their pain.

In Python, you are encouraged to follow Easier-to-Ask-Permission-than-Forgiveness and catch specific exceptions. Doing either / both requires you actually know what exceptions to catch so you don't hide bugs. The problem is that the docs rarely mention the expected exceptions. You have to resort to discovering them experimentally and hope that that exception was an intended part of the API contract and not an implementation detail.
I am unable to find an answer to my question in what you just said.
Subtitles for theatre – Mac App for creating surtitles in theatre shows
In some cases I suspect it depends a lot on the hardware. I did a bit of research into the "Integer minimum" algorithm. Given the following straightforward implementation:

int min(int x, int y) { return y < x ? y : x; }

..most compilers will produce something very much like the following for x86-64 (from Compiler Explorer https://gcc.godbolt.org using -Ofast -march=haswell):

min(int, int):
cmp esi, edi
mov eax, edi
cmovle eax, esi
ret

Compare that to the generated instructions for the algorithm listed in the "Integer minimum or maximum" section (x+(((y-x)>>(WORDBITS-1))&(y-x))):

min(int, int):
sub esi, edi
mov eax, esi
sar eax, 31
and eax, esi
add eax, edi
ret

It's not immediately obvious to me which one is likely to be faster (I'm not an expert on x86-64 assembly).
So, this shortens down to "I don't want people touching my private class members", "I want multi-line lambdas", and "I want types".

WRT private class members, I can understand why this might be frustrating for library writers. But it's just so damned useful to be able to reach into a library and get functionality the library's writer didn't think I'd need, that I'll personally never consider this to be bad.

Multi-line lambdas would certainly be nice, but most of it can be handled with a scope-level function. It adds, on average, one line of boilerplate. As for syntax, no need to use Ruby's syntax, just incorporate parenthesis (a well established continuation construct within Python):

with(open("foo.txt"), lambda f: (
print(f)
print("I am a teapot")
))

The sinatra example doesn't really make the writer's argument about decorators to me; since the Flask example exposes a bit more functionality for only two lines of code - I now have a distinct app object, and can create more, or explicitly access attributes of the app itself. I can even add authentication to that function with just two lines:

auth = flask.ext.httpauth.HTTPBasicAuth()

@app.route("/")
@auth.login_required
def handle_route():
return "I am a tea pot"

No, Python isn't Ruby; it doesn't support the same degree of metaprogramming. That's good, IMO. Metaprogramming is the source of exponentially more technical debt (and bugs) than is reasonable, frankly.

As for the lack of a type system, yeah, that is definitely Python's biggest weakness for large programs. A lot of it is resolved with the type hints in Python3, but a lot of it is just Python itself. Love it or hate it, that's how Python is, was, and will be.

As for the example error - there is a typo. Of course it's going to throw a traceback. The error message is even more explicit than I expected, frankly. It pointed out the missing function name, which would make the typo rather easy to find.
Sure. You can argue that it was democratic, but I personally do not choose to lose my citizenship, therefore my citizenship is being taken from me, forcibly.
9 amazing holiday apps you need to live like a local
"Kappa" is from the game streaming site Twitch. Unless it means something else entirely and I'm out of the loop.
Robots Are Eating Money Managers’ Lunch
Agentology, the referral network for real estate agents, closes on $4.5M
It might feel like a building a castle out of sand, without context, but it's very often like building a castle with

from castles import CastleWithMoat
c = CastleWithMoat('eyy')

It's just not meant to replace C++, but I think it beats php, perl, R, and lots of things in readability and package coverage. It lets me do GIS, number crunching, and web serving all in one system. Equivalent functionality in Python is a fraction of lines of complexity implementing from scratch in "strongly typed serious code", for a huge swath of problems.
Scientist Who Connected Litvinenko's Murder to the Kremlin “Assassinated” in UK
OK, sure, but people are pitching Python not just as a language to write scripts but also one to do development of large projects on large teams, and I think this property makes it somewhat ill suited for that.
The geographes I know would never, ever be able to do in lisp what they do in Python. They are not computer minded at all.
None of the company I worked for had any ORM like in place and they were all doing crud app.
I'm certainly not advocating against the rule of law, rather that we already have plenty of counter-terrorism laws, the sum total of which doesn't seem to stopped terrorist attacks from happening. I believe that in order to reduce the threat of terrorism in the UK, what we need is not more laws against it, but spend that time and energy tackling the root causes of radicalisation - poverty, mental health issues, education, wartime atrocities committed overseas, and other factors. Preventing people from becoming radicalised is safer and much more cost-effective than trying to find and track people who already are. Both approaches are necessary, but all the rhetoric is focussed on the latter, the former being not such a vote winner as a 'tough on crime/terror' stance.
"sense of shared identity" may be a bit loose; I meant in the sense of not feeling a constituent part of a common political community. Plenty consider themselves European (I suspect rather more in the UK since the Brexit vote made the question a bit more salient) but I doubt there are many whose principal allegiance is to the European Union, rather than France, the UK, England or Yorkshire. And yes, this is an informed assumption rather than based on a particular survey.

In practical terms, as someone else stated, European Parliament elections are conducted as a series of more-or-less isolated national campaigns, with a weak sense of a body of citizens making a decision as a continental group.

This is perhaps beginning to change, with the Europarties nominating explicit lead candidates for the presidency of the Commission at the last Parliament election, which provides a certain cross-border unifying factor. It's notable that in my country (the UK) these candidates were barely mentioned, though, and the race was treated as a proxy fight for future control of the Westminster parliament, or as a chance to elect eurosceptics to protest the EU as a whole.
The UK is still an active member of the EU. We haven't left yet.
Pip and pip files provide a basic dependency management system. To cargo and bundle are the guild standard, but this at least gets the job done.

PyCharm has some autocompletion. But it's for some reason way behind what I'm used from Rubymine (fair comparison) and light-years from let's say IntelliJ (a little unfair comparison).
But isn't this the same issue with Net Neutrality regulations? We're asking the state to enforce net neutrality, but it opens a can of worms. Tomorrow it would be "all data should be treated equally, except for govt data which should be prioritized above all."
"All data should be treated equally, except for terrorist data, which should be prioritized/blocked".
Python type hinting is a nice newish feature. It needs to go further, though. PHP (gasp!!) for example is making the right strides when it comes to runtime checking.
(I apologize for the long post. I hope it is thought provoking nonetheless.)

I think it is useful to consider the difference between "Who made this?" and "How was this made?"

As a coder, when I see a program that achieves something I didn't know was possible, it makes me very interested in how it was accomplished. I say, "Great job, that is awesome. How did you do that? Where is the source code?"

In the same way, I see the complexity of life: the required components and all the intricate processes (Search for ""Inner Life of a Cell" on Youtube, it's really amazing).

I try to comprehend the level of complexity and I quickly realize that even Scientific Notation cannot express it appropriately.

So, when I appreciate the Creator and say, "Well done, that is insanely awesome!" I also say, "How did you do that?" "How was that made?" "How does this work?" "What can I do with it?" "Can I hack it to do something else?"

---

As far as complexity of faith, the difference is a matter of simple set theory:

Define 2 Sets:

- All things that are made (the Universe) (U)

- All things that are not made (the Eternal) (E)

You have stated that it requires more faith to believe that there are 2 sets (U,E). However, it could be argued that absolutely denying the possibility of the existence of one set (E) requires a stronger choice of faith.

Also, the 2 sets (U,E) makes sense to me, but I see a contradiction in the single set (U only).

It's simple logic:

If (U only) is the set of all things that are made, then the question begs to be answered: "Where did it come from?"

If (U,E), then the answer is obvious: The set of all things that was made (U), came from the set of things that were never made (E).

I often hear: "Ok, where did E come from then?" Well, by definition E was not made. E is not U.

Also, beyond basic logic, if we consider the theory of the big bang which fits with out measurements of an infinitely accelerating expanding universe: The big bang itself points to a specific point in time where the Universe began (or at least was transformed from a singleton to an accelerating expansion).

So if you limit the choice to only (U), again you are faced with a question, "What prompted the initial bang?"

One possibility is that (U=E). Another words, the universe itself must be eternal.

In that case, we would expect an eternal cycle to be observed (something like the Bang-Bang Theory). However, our best measurements indicate an expanding universe that will never collapse and bang again. There is no support for a Bang-Bang theory which would indicate an eternally cyclic universe.

Everything we can measure indicates the universe had a beginning and that it will continue to accelerate it's expansion infinitely.

So the most logical explanation I see is (U,E): that the universe was created (by something that was not created i.e. The Eternal One - aka God).

And that makes me even more curious: I want to explore all the beauty inside the box because now I have someone to direct my appreciation to say, "Well done! That's amazing!".
Toshiba to pick government-led Japan-US-Korea group to buy chips unit: source
I use Intellij idea with the Python plugin, it gives you some hints, but for complex things it is just useless. And I cannot use MyPy because I have to use python, if I can choose other language or thing I would go with something not under development and far from python.
"How do I follow conflicting laws? One country says "keep all data for 90 days to aid law enforcement" the other says "delete it immediately" which is it?"

GDPR is EU wide regulation that trumps national privacy laws. It doesn't even need to be approved by individual members, so when it goes into effect on 25 May 2018, it will be working EU-wide on the same day. Furthermore, it affects companies all over the world that serves EU citizens. There's much skepticism on how EU will enforce this law worldwide, but for now it was quite successful dealing with big companies, remember: Microsoft vs EU (paid €561 million fine), multiple cases of Google vs EU (right to be forgotten, Ireland tax rulling, ongoing case vs Android), Facebook/WhatsApp vs EU (€110 million fine) etc. To answer your question: no, there will be no conflicting laws - if you serve EU citizens, you must follow GDPR. From my personal perspective, GDPR is one of those not-so-often moments that I'm proud of EU.
Please read what I am saying. I am replying not to argue with you but to try to spread knowledge and education on the topic. Like if replying to a Stack Overflow question. If you are not reading this because you actually want to learn more and instead trying to argue with me, please let me know so I can stop wasting my time.

It sounds like you already made up your mind that blockchain is just marketing hype without actually understanding how it works.

> I can configure my database to require a private key be verified before data is committed to the database.

Absolutely not the same. As I explicitly said in my last reply, that is not the purpose of blockchain. That is not a blockchain, that is just encryption.[1]

The thing that makes it a block chain is that the hash of the new transaction is dependent on the hash of previous transactions therefor the history of transactions is immutable. Hence the "chain" part.

That CAN actually be done with a traditional RDBs IFF:

- You store a cryptographic signature with each row.

- You completely disable DELETE and UPDATE queries.

In other words. Blockchain is much more restrictive of what can and can't be done.

But to truly be a blockchain you also need to include previous hashes in row your signature. Something that is not easy to do in distributed systems without batch committing. Hence The "block" part of blockchain.

> The only efficiency provided by the blockchain in your scenario is that it allows you to use blockchain terminology in marketing materials.

The blockchain is not designed to provide efficiency in storage. That's not it's use case. In fact it is incredibly inefficient at that. The blockchain is designed to allow a party to be able to trust the data at a specific point of time without having to rely on absolute trust of the party sending the data and without having to pre-share keys.

It does no know who the person at the other side of a transaction is, it only knows that the transaction is allowable (or not).

The type of encryption you describe relies on both parties being known to each other and having shared secrets.

I have more I could say but books can be (and have been) written about this.

[1] Also I really hope it's not verifying the private key... private keys should never be sent to the server. They can be verified independently using signed data and a public key.
May I ask what is the purpose of this app?
Alan Kay on What was it like to be at Xerox PARC when Steve Jobs visited?
You have the same problem of space/tabs in all other languages, except there is no error and it can silently mislead you in badly understanding code, or just make it harder to read for hours on big project created by several generations of dev.
In a past life, I ran a consulting team at a BigCo whose business centered on T&M contracts like OP's. BigCo had 10k employees, mostly associated 1:1 to contracts with the same "bill exactly 40 hrs, but never overhead" constrains.

Our little team had 100 employees, but we matrixed those guys across all our contracts. While the clients disliked the idea of not having "their guy," they really liked having access to the technical depth of 100 guys vs. just the 10 they could afford. Turns out being able to have a Linux kernel guy, OS X kernel guy, Android kernel guy, database expert and hardware hacker on call at all times is incredibly valuable.

Since we matrixed across contracts, we managed to instuitionalize the "overtime hack." The guys were exempt status, so they didn't get time and a half for hours over 40, but they did get paid for every hour they worked. It was a phenomenal hack - guys were routinely making 20-50% more than their base salary. We intentionally understaffed by a bit, to make sure there were always extra hours to burn.

That team is 15 years into existence at a BigCo, and the hack still lives. If you find yourself in a consulting org and think you can make something like this work, don't think for just yourself, but shoot for the moon - set it up so it works for everyone and outlasts you.
> as the Chinese characters are directly inside the movie.

Yep, same with TV shows, and soft-copies of transcripts are difficult to come by, hence my interest in something like this.

I just watched the video. When used on a video does it keep a history of all OCRed text?

Finally, you might also like to try posting this on http://www.chinese-forums.com If it mostly works well for TV and films, I'm sure there will be quite a few people there who are interested in it.
This is (annoyingly) common in a lot of software packages. Protip: Keep your documentation's links canonical. Currently running into the same thing for Polymer. Just keep the old links and do a permanent redirect to Polymer 2.0, with a clear indication of what version you're on. Also looking at Angular here.
Again, the win the traditional military conflict and that is their primary responsibility. They are not equipped to do Nation building and they don't have the political support to do it. That's why they never exit a conflict very well, but they always crush in the beginning.

Korea was the last time they had a real problem winning the traditional military conflict.
Most executives and managers don't know how, or don't want to, solve problems. So they dump those problems onto employees, vendors, even customers. Anyone to avoid having to do their job. Their most valued employee is the one in whom they can see value without having to work at it.
Do smaller companies get less onerous requirements? This is achievable for mid and large companies to comply with but may further stifle EU innovation.

I think this is a good set of data protections and hope there are ways to make compliance incredibly low friction.
Sounds like a plain-old ASP.NET site with Razor partials.
Put $150 a month into a RothIRA. Every month.
Well I wasn't commenting on age of particular projects. I had not heard of Beego so now I still feel there is a bit of over growth. Leads to confusion over what to use when you do want better routing which I think is pretty much every project. Perhaps routing will continue to improve in the standard library such that it does not feel like I need to pick a package or roll my own.
In my experience, pip inside virtualenv manages dependencies very well.

Completely agree on type checking point though.
I absolutely disagree for a number of reasons.

First, let's stop pretending that 50 state disclosure laws create some massive undue burden for a company that's big enough to be an ISP in all 50 states.

That would be a similar argument to saying that states shouldn't have minimum wages because it's "too hard" for Walmart to have 50 different state minimum wage laws. The only difference is disclosure laws are vastly more simple than labor laws.

Second, even if you assume the cable industry should have a single uniform standard, that's up to Congress, not the FCC to determine, so not only should Big Cable lose this on the grounds that state-level consumer protections are a good thing, they should on the grounds that the FCC has absolutely no authority to do this.
pip is too basic and it doesn't manage well when dependencies requires different version of the same package. Not even an error.

I am used to IntelliJ with java/kotlin. So the autocomplete and type checking is far away, but I think it is because the language itself.
I love decorators so much (when used well).

For example, I used a decorator the other day that I called `@logperf` that I can pin to any function, which will `logger.info` the approximate time it takes to run the whole function. It doesn't mutate what the function does, it just adds a side effect.
IMHO, I wouldn't consider yourself late to the party. There's a ton of work being done on the EVM (Ethereum Virtual Machine) and new languages are coming out for it (like Viper). The biggest challenge at the moment is knowing which resources are still relevant and worth grokking. As long as you stay curious, I'd say there's a great chance your future in the market will be mildly prosperous at worst.
You're definitely talking about TMP, template metaprogramming. The STL is a set of useful libraries that do specific things. Like represent strings or vectors. Or sort, or generate random numbers. If anything the STL is too small.

TMP, on the other hand, is an entirely separate language within C++ that allows you to create monstrous, arcane code that's incredibly hard to debug or understand. Some of the STL uses TMP. But it sounds like custom TMP is the thing you don't like.
Ok so you are argued that OP or one of his coworkers should be fired, so OP can get his 3% raise. And on top of that, his workload now went up 10%, as there are less people to do the work.

Got it. Sounds like good decision making.
How is it better than - let's say - PowerPoint?
That types criticism is a little bit old now. 3.6 will happily accept type annotations, and mypy can check them.

While I get what the decorator complaint was about, the example was just weird... My first follow up question would be: so how do I route 2 paths to that function?

@route ('/')
@route ('other')
def ...

seems like a trivial answer. Now, how do I do that with that block-taking function? Maybe I can pass in an array of paths, maybe not...
I suspect they're using Tesseract as they've written a gui for it ( https://ocr.space/blog/p/free-ocr-windows.html ) but there's no way to find more.