Hacker News new | past | comments | ask | show | jobs | submit | iki23's comments login

regarding a secure router, the .cz tld operator cznic (authors of knot dns) are building high-security high-performance opensource hw/sw router (coming in October) https://www.indiegogo.com/projects/turris-omnia-hi-performan... https://www.turris.cz/en/



Zenbook, cottage veranda or garden, between two rivers 15km from Prague (1h on bike) ... just now, many birds are singing here from March to July


chrome/ff dev tools have source maps support, I can work directly with coffee source the same way, as I work with less source instead of compiled css ... only coffeeconsole is in a separate tab via chrome extension


sure, using source maps in chrome dev tools, I can work directly with coffee source, the same way I work with less source instead of compiled css


+1, CS can be learned in few hours and any questions on what each constuct produces can be quickly resolved in coffeeconsole for chrome

Verification: lead development of 50MD and 300MD mobile html5 apps for major UK TV's and even people who did see CS first time were able to pick it up quickly. I had literally about 5 cases when I had to answer some chat questions on how CS works, and about the same count when I corrected/optimized some CS usage in a code review.

The productivity gain was impressive. In ducktyping, but esp. in __understanding__ the code quickly.

We're not going back.


won't scale for hundreds of feeds; I use thousands


I'm using MSYS http://mingw.org/wiki/msys heavily, it has bash and all file and text processing utils. It's also distributed as a part of Git port http://msysgit.googlecode.com.

Lots of other utils can be also found in GnuWin32 http://gnuwin32.sourceforge.net/packages.html.

Btw, the sed in Gow would deserve update from 3.0.2 ;) https://github.com/bmatzelle/gow/wiki/executables_list


Good coverage. I use it quite often for cache dictionary, it's much simpler API and overall code, than creatng a new class for it. Demo snippet from effbot's site:

  def calculate(a, b, c, memo={}):
    try:
      value = memo[a, b, c] # return already calculated value
    except KeyError:
      value = heavy_calculation(a, b, c)
      memo[a, b, c] = value # update the memo dictionary
      return value


This seems a bit leaky. You're exposing the caching mechanism in the method signature(yeah, ok, in practice it's unlikely to be a problem).


The other option is to create your own cache object and pass that in (and around, if it's a recursive function). Of course, in Python pretty much every cache object follows the dictionary interface anyway, so it doesn't really matter. One of the benefits of duck typing :)


Yes, but why? Actually, it's No, because python culture aims to use one way to do thing, the least surprising one. In this case it's:

  def f(x=None): if x is None: x = []


Because that "if" is a statement whereas the ternary expression is, well, an expression. There are places expressions can be used that statements can't (eg lambdas) and that x or [] won't work (eg when x is False).

That said, people still seem to favor your form as the more Pythonic way. Personally, I think that's just because the ternary expression is relatively new.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: