Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
miguelgrinberg
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
6 ms
·
1.
▲
by
miguelgrinberg
25d ago
For those on version 15 LTS, this fix was released with v15.0.8.
2.
▲
by
miguelgrinberg
7mo ago
> One thing I’ve noticed is that different people get wildly different results with LLMs, so I suspect there’s some element of how you’re talking to them that affects the results. It's always easier to blame the prompt and convince
3.
▲
by
miguelgrinberg
10mo ago
The OWASP CSRF prevention cheat sheet page does mention SameSite cookies, but they consider it defense in depth: https://cheatsheetseries.owasp.org/cheatsheets/Cross-Site_Re... .
4.
▲
by
miguelgrinberg
10mo ago
Hi, author here. This was actually a mistake. If you look at the OWASP cheat sheet today you will see that Fetch Metadata is a top-level alternative to the traditional token-based protection. I'm not sure I understand why, but the chea
5.
▲
by
miguelgrinberg
10mo ago
Okay, now I understand where you are coming from. Confession, I did not read the PR. I assumed that what is currently published in the cheatsheet is the same as the PR. This is what guided my analysis. I will update my article to be in agre
6.
▲
by
miguelgrinberg
10mo ago
When I said "the maintainer is warming up to the idea" I meant to the idea of upgrading Fetch Metadata from the current status of defense-in-depth to a full solution that can replace the token-based approaches. It is pretty clear
7.
▲
by
miguelgrinberg
10mo ago
Hi, blog post author here. With regard to state-changing GET requests, I do not recommend their use and I agree that they create some problems for CSRF protection, but you are correct that I did include tests that verify that they can be en
8.
▲
by
miguelgrinberg
1y ago
That tells you how much I know about the feature. :) But in any case, I'm positive that the flag was enabled, so my results are with tail calls. I suppose part of the difference between 3.13 and 3.14 could be thanks to this.
9.
▲
by
miguelgrinberg
1y ago
FastAPI is a web framework, which by definition is (or should be!) an I/O bound process. My benchmark evaluates CPU, so it's a different thing. There are a ton of web framework benchmarks out there if you are interested in FastAPI
10.
▲
by
miguelgrinberg
1y ago
There is no "realistic" benchmark, all benchmarks are designed to measure in a specific way. I explain what my goals were in the article, in case you are curious and want to read it.
11.
▲
by
miguelgrinberg
1y ago
The build of Python that I used has tail calls enabled (option --with-tail-call-interp). So that was in place for the results I published. I'm not sure if this optimization applies to recursive tail calls, but if it does, my Fibonacci
12.
▲
by
miguelgrinberg
1y ago
Thank you so much!
13.
▲
by
miguelgrinberg
1y ago
Keep in mind that the two scripts that I used in my benchmark are written in pure Python, without any dependencies. This is the sweet spot for pypy. Once you start including dependencies that have native code their JIT is less efficient. Ne
14.
▲
by
miguelgrinberg
1y ago
One reason is that I did not spend much time optimizing the Node and Rust versions, I just translated the Python logic as directly and quickly as I could. At least I did not ask an LLM to do it for me, which I hope counts. ;-) Edit: fixed a
15.
▲
by
miguelgrinberg
1y ago
You have made my day, sir. :)
16.
▲
by
miguelgrinberg
1y ago
This is true for any kind of project, regardless of hardware or software stack. You always need to evaluate the performance for the specific use case you are targeting to make sure it falls in the expected range, and it is your job to do th
17.
▲
by
miguelgrinberg
1y ago
You got it backwards. If I were to release a benchmark for Microdot, everyone would say that it is biased! The article you are referring to is intended to benchmark microcontrollers running MicroPython. Nothing to do with Microdot. I'm
18.
▲
by
miguelgrinberg
1y ago
It's important to note that for most small devices that run MicroPython asyncio is the only available method of concurrency. These devices have no concept of processes, your application is the only thing that runs. Most devices do not
19.
▲
by
miguelgrinberg
1y ago
Right. Microdot just gives you the support to build the web application. This is built on top of the standard asyncio Python library, so you are likely to find good support for most tasks in the ecosystem.
20.
▲
by
miguelgrinberg
1y ago
You are more than welcome to evaluate Microdot on the specific device you are interested in. It is good to keep in mind that people don't run web apps on microcontrollers because they have good performance. Don't expect any miracl
21.
▲
by
miguelgrinberg
1y ago
I wanted to use MicroPython for this. I have nothing against C, it is a language that I actually know and use for other projects, but I wanted the challenge to try to build something similar to Flask or FastAPI that could run well on small
22.
▲
by
miguelgrinberg
1y ago
To clarify this, note that the extensions are entirely optional, and unlike what you are saying, most do not require any dependencies. The only two extensions that use dependencies are the one that adds template rendering, and the one that
23.
▲
by
miguelgrinberg
1y ago
Thanks. The smart heating device in question is one that is fairly popular in Ireland, but I believe it isn't sold elsewhere. The brand is Climote ( https://www.climote.ie/ ). As part of the service, this controller give
24.
▲
by
miguelgrinberg
1y ago
Always a nice surprise to find my stuff on the front page. If you have any questions about Microdot, I'm here to answer them!
25.
▲
by
miguelgrinberg
3y ago
Thanks, will keep it in mind!
26.
▲
by
miguelgrinberg
3y ago
I have written a few microservices/APIs with Microdot, actually. Works really well for that.
27.
▲
by
miguelgrinberg
3y ago
If you deploy it with a production grade web server (uvicorn, etc.) it should be able to scale just fine, while using less RAM than the larger frameworks.
28.
▲
by
miguelgrinberg
3y ago
It has some traction in the MicroPython community, used with IoT projects running on microcontrollers.
29.
▲
by
miguelgrinberg
3y ago
Yep!
30.
▲
by
miguelgrinberg
3y ago
The main thing that none of the frameworks you know offer is being small enough to also work under MicroPython on $5 microcontrollers. I created Microdot a few years ago when I wanted to have a web interface to configure a thermostat that I
More ›