Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
tusharsadhwani
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
5 ms
·
1.
▲
by
tusharsadhwani
2y ago
that's because it's not a reimplementation, it is cpython recompiled to wasm.
2.
▲
IICT: First Compiler Workshop in India
(compilertech.org)
5 points
by
tusharsadhwani
2y ago
|
0 comments
3.
▲
by
tusharsadhwani
2y ago
I finished this book, wrote the two implementations in Python and Zig, genuinely one of the best set of projects I've ever built.
4.
▲
by
tusharsadhwani
2y ago
This is already the best API testing client that I have found. It's lightweight, it's snappy, it's intuitive, and it can run on a VPS out of the box over an SSH connection, no proxying needed.
5.
▲
by
tusharsadhwani
2y ago
Yup, it's extract, fork process, cleanup. It's also fairly easy to extend the project to create installers and let the user choose a path to extract in, and I plan on doing that. I also believe that sending a signal to the parent
6.
▲
Replacing pyinstaller with 100 lines of code
(tushar.lol)
5 points
by
tusharsadhwani
2y ago
|
0 comments
7.
▲
by
tusharsadhwani
2y ago
This is brilliant stuff, a very nice high level explanation that skips everything that would make it too boring for a first time reader. Adding other resources at the end which explain how it _really_ works under the hood would be great.
8.
▲
by
tusharsadhwani
3y ago
they're beta testing `textual-serve` which does exactly this.
9.
▲
by
tusharsadhwani
3y ago
thanks for the non paywalled link!
10.
▲
by
tusharsadhwani
4y ago
It's true, the truly cursed method should never be used in a project that you actually aim to use. But, I just wanted to see how close I could get to the original idea, regardless of how "bad" the solution ended up being. The
11.
▲
by
tusharsadhwani
4y ago
it does!
12.
▲
by
tusharsadhwani
4y ago
you're welcome!
13.
▲
by
tusharsadhwani
4y ago
If you think about it it's no different than wasm already. And wasm has been accessible for at least 4 years now, and yet nobody has given up react and typescript. wasm is being used to do compute heavy work efficiently, and giving tha
14.
▲
by
tusharsadhwani
4y ago
requirements.txt doesn't support putting your python version in it
15.
▲
by
tusharsadhwani
4y ago
Projects can't keep using an old compilers because of security patches though. At some point, the old versions are too old to keep the security up to date. A more common example, what if a library that you use stops supporting the old
16.
▲
I added C-style for-loops to Python
(sadh.life)
8 points
by
tusharsadhwani
4y ago
|
1 comments
17.
▲
by
tusharsadhwani
4y ago
The idea came from trio's nurseries I believe.
18.
▲
by
tusharsadhwani
4y ago
it's not like they'll have different user account behaviours for someone living in California at the moment, compared to someone living in the EU.
19.
▲
by
tusharsadhwani
5y ago
not very related, but you might want to check out manim: https://github.com/ManimCommunity/manim
20.
▲
by
tusharsadhwani
5y ago
iirc that was AlexNet, ResNet came 3 years later whose refinements ended up making it better than a human at object detection.
21.
▲
by
tusharsadhwani
5y ago
I can't think of any exceptions to this right away, so you might be right. But, not having ctx available as an explicit value would make certain ast manipulations, as well as bytecode generation by the interpreter more complicated. Thi
22.
▲
by
tusharsadhwani
5y ago
That's amazing. I'm interested in C# now
23.
▲
by
tusharsadhwani
5y ago
True! Although there's some lints that would require you to parse tokens, such as checking for single vs. double quotes, or number of spaces used for indentation. However, python has a builtin tokenize module for that as well.
24.
▲
by
tusharsadhwani
5y ago
I'll agree, it's not a good introduction to compilers, but it isn't meant to be. PLY on the other hand is an amazing resource, thanks for linking it here.
25.
▲
by
tusharsadhwani
5y ago
My bad xD, to my credit it's mentioned later in the article. But you're right, I should add that in the beginning.
26.
▲
by
tusharsadhwani
5y ago
The only major changes that I'm aware of since python3 has been the change with keyword arguments in 3.6, and the deprecation of Index and introduction of Constant more recently. Those are big changes, but relatively small and maintain
27.
▲
by
tusharsadhwani
5y ago
tree sitter can definitely help with this problem, but so can regular AST parsers, the idea is the same: just add code or grammar that will parse the "invalid" grammar, mark it as invalid, and continue parsing valid code as soon a
28.
▲
by
tusharsadhwani
5y ago
I really wasn't expecting anyone to read all of it, I was afraid people will either find it too trivial or too complex based on skill level. So that's great to hear.
29.
▲
by
tusharsadhwani
5y ago
Thanks! The stuff that ASTs let you do really flexibly is almost always lost to people because they're not aware of it. A lot of other developers would try to do this with string or regex matching, and that often leads to painful exper
30.
▲
Learn Python ASTs, by building your own linter
(sadh.life)
183 points
by
tusharsadhwani
5y ago
|
32 comments
More ›