I like how your parent comment has positive karma for saying that "it's fake; who cares," but I'm downvoted into negative for saying "it's fake; I care" : https://news.ycombinator.com/item?id=18735972
> Most new US production is higher cost (fracking), so the drop in market share is at least met with a stronger price floor for all.
Not to be rude, but this is really off the mark. The only reason that we're not still in a cartel market regime of $100 barrels is fracking being invented/discovered and efficiently improved. It cut the price floor well in half.
Fracking is not the cheapest, but it's also not the most expensive (see Canada's oil sands). When you compare fracked WTI (basically the USA-sourced index) to offshore Brent (North Sea, off the coast of UK), the costs are apples to oranges because fracking can be readily tapped at a relative drop of the hat (if prices spike in a short term period), but offshore is a huge multi-million/billion endeavor where you have to depreciate costs over a really long time horizon (same with oil sands, but different tech).
This was pretty obvious imo, based on a cursory viewing of the original video when it came out. I immediately blocked the dude's Twitter account as I only use it for following fintwits. People wanted to believe it was true for whatever reason; just take a step back, and you'll see how obviously staged the whole thing was. Don't feed the troll.
This is completely off subject, but as a personal rule of thumb, 99% of articles that include the first person, such as "Why I [did xyz]..." or "How we can...", are clickbait.
Ime, the best case scenario is Acme Tech Co. "blogging" about "why we used abc codebase," but the reality is that it's simply rehashing well known information in narrative form for the purposes of PR, and worst case scenario is that it's just unoriginal op-ed garbage.
See: "We should replace Facebook with personal websites," which is currently trending at #10 for HN, above this OP at #16.
EFF is a great organization and can't say that it's surprising to see that this is the first time in a long time to come across an exception to the rule.
Please be honest and admit that this is solely about yourself; your kids having nothing to do with this except with respect to your own benefit. Even Walter White "did everything for his family."
I've always just used `sys.stdout.write("\r%i/%i" %(c, n)); sys.stdout.flush()`
That is exactly what this library does: "tqdm does not require any dependencies (not even curses!), just Python and an environment supporting carriage return \r and line feed \n control characters." -- https://github.com/tqdm/tqdm
Seems unnecessary imo to depend on an external library just to wrap and auto-prettify those 2 stdout commands.
import sys
def writeToTerminal(txt, line_len=79):
# line_len is the max num of characters that can fit onto a terminal line without overflowing to a newline
# overwrite the line with blank spaces
# this takes care of the case where len(txt) is fewer than the [ len(txt) when this function was last called ]
sys.stdout.write( "\r" + " "*line_len )
sys.stdout.flush()
# write the txt, trimming to line_len
sys.stdout.write( "\r" + txt.replace("\t", " ")[:line_len] )
sys.stdout.flush()
Example usage:
from time import sleep
L = list(range(10))
for c, i in enumerate(L, start=1):
writeToTerminal("%i / %i" %(c, len(L)))
sleep(1)
it shows a progress indicator,
which is functionally the same from a user perspective.
the visual display of this progress indicator is different yes -
This method doesn't need any notion of terminal width because it
just prints 'N / N' at the beginning of the current line where the cursor is when called.
I tend to side with your opinion (obviously, based on the above code), but detaro does have a point, which is that the progress message will "overflow" onto a new/next line in the console if the message has more characters than will fit on a single of the terminal.
fwiw, line_len=79 is the default on both windows and linux ime. You would only encounter overflow if you (1) shrunk the terminal from its default width and (2) printed a message that was longer than that shrunken width.
If you really needed to have a progress bar that accounted for a shrunken display, it could be accomplished trivially with Python 3.? and less-trivially with Py2.
I could see depending on this library if the application was client facing and needed to be automagically pretty.
Also, one thing to note is that tqdm only fetches the console width when init'ing a progress bar... if you shrink the terminal while a progress bar is still "in progress," you will encounter the same overflow issue.
How would that work? A secret search engine? Or Google pretending to give in under pressure from employees, then turn around and tell them (and everyone else) "haha, we lied" and launching it? How would that not create far larger harm than just not giving in in the first place?
> Or Google pretending to give in under pressure from employees, then turn around and tell them (and everyone else) "haha, we lied" and launching it? How would that not create far larger harm than just not giving in in the first place?
Google hasn't pretended to give in to pressure from employees. Project Dragonfly is still being worked on:
> In recent weeks, teams working on Dragonfly have been told to use different datasets for their work. They are no longer gathering search queries from mainland China and are instead now studying “global Chinese” queries that are entered into Google from people living in countries such as the United States and Malaysia
...and Google has made no promises that they won't launch it in the future:
> Pichai stated that “right now” there were no plans to launch the search engine, though refused to rule it out in the future. Google had originally aimed to launch Dragonfly between January and April 2019. Leaks about the plan and the extraordinary backlash that ensued both internally and externally appear to have forced company executives to shelve it at least in the short term...
I think the title overstates the situation. This doesn't seem so much like an end to the project than an internal political squabble. It seems like 265.com was purchased to do exactly what the Google Privacy Team has forbidden. I don't know Google's internal politics, but I'd be surprised if its privacy team has enough power to hobble one of the CEO's priorities enough to actually kill it.
> Relational databases are brilliant, but SQL is terrible and I don't understand how it hasn't gone the way of COBOL yet.
Having written extensive amounts of SQL and greater than zero lines of COBOL (f. you, Lawson), this really couldn't be further from the truth.
> For a start, the bizarrely English-oriented structure forces a completely different ordering of the code than what comes out, and the syntax appears to completely ignore the underlying tabular concepts.
Every language has keywords; I'm not sure how you expect to write code that doesn't involve English in some form. Is the concept of `SELECT this_data FROM this_source WHERE true_conditions ORDER BY columns` really that convoluted? Sure, it definitely gets more complicated, but is there really a significantly better way to do it that doesn't involve taking away low-level control from the programmer, in exchange for something sexier and easier to pick up?
> Not to mention that IMO joining on foreign keys shouldn't be a thing--the database should be able to figure out what you want when you write `order.customer.address.taxRegion.rate`
Why can't you have a key-value storage engine that doesn't involve using keys to look up values?! (Is that really your question?) Okay, just as an example, what if you have more than one address for a customer? You need a way to tell the engine which address(es) you want.
> There's just so much awkwardness in trying to write a SQL query that I can definitely see why people would avoid it.
While I don't claim that SQL is easy (or always intuitive), saying that it is "terrible" for the above reasons is like saying that C is terrible because it's not Pythonic.
The author whines about all the problems of the modern world, enlightens us with the emotional turmoil endured when watching a movie, and then concludes with a "won't someone please think of the children?!" In this diatribe, neither are the author's specific moral convictions shared with the reader nor are any solutions offered except to remind you that Trump is bad.