Developer Experience #455
Replies: 2 comments 2 replies
-
|
Hey @justin0mcateer , thank you so much for your detailed report! I appreciate honest feedback like this and need it to improve this project. So by all means, all feedback is always welcome! What you are describing is real, and the developer experience is the most important aspect of such software. So I will dive into this deeply shortly. I'm just about to release a new version and right after I'll dig into DX and your suggestions in particular. Others have voiced similar things and so this will come as one of the next things. Anything else you would like to see, I'm always open to hearing it! :) Best, |
Beta Was this translation helpful? Give feedback.
-
|
Hey @justin0mcateer — coming back on this with concrete results. Your post drove a real chunk of work that's now shipping in v0.5.606. Walking through each of your suggestions with the exact commands so you can reproduce. The short version: all four issues we filed in response to your post (#462, #463, #464, #465) closed, plus a follow-up batch (#510, #511, #512, #513, #525, #526) that turned up while we were stress-testing the DX end-to-end. Net result is that your TL;DR scoreboard
Concern 1 + 3: Discoverability
The generated A CI drift gate (v0.5.560) re-runs the generator on every push and fails the build if the artifacts go stale, so the published reference stays in sync with the compiler's actual dispatch tables. For your specific case: the Concern 2: Catch unimplemented APIs at compile timeThis was the load-bearing one. Your exact The check ( For typecheck-time errors against arg shapes — your suggestion (2) — (That Concern 4: Runtime panic on undefined dereferencePre-fix behavior was the silent-undefined fall-through you described. Now: Node-shaped error message, exits 1 (so CI scripts and process supervisors detect the crash — fixed in v0.5.597 / #511 — previously exited 0), execution stops at the bad line. Same pattern works on the related case of typo'd method calls on primitives (#510, v0.5.593) — the "I meant Bonus: stub registry diagnostics (#464)Some symbols link cleanly on every platform but no-op at runtime on the wrong target — e.g. Plus a runtime first-call warning when execution actually hits a stubbed symbol. Bonus: unified message format (#525)When you write code that hits an unimplemented API, the error is the same regardless of which path the AST took to get there: Same shape, same hint, same escape hatch, same Honest gaps still on the listWant to be straight about what's not yet polished:
Try itIf you have a few minutes, the v0.5.606 binary makes the original repro a two-command verification: Thanks again for the detailed report — it forced us to think about the DX story end-to-end rather than as scattered ergonomics. If you have time to give v0.5.606 a real workout against your JWS/AES code, I'd love to know what the next round of friction looks like. Always more sanding to do. Best, |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
First, let me say how impressive the project is already. I realize this is a very new project and there is a very long way to go to maturity. However, what is been done so far is amazing.
I spent a few hours working on a proof of concept for a small application that would need to interact with some REST APIs and perform some encryption functions related to JSON Web Signatures (JWS) and AES decryption. Initial 'hello world' was no problem out of the box. However, once I started getting into creating the cryptography I started running into issues. The technical issues could be worked around, but the developer experience is what I want to discuss here.
My code would compile with type-checking and run to completion without indicating any issue. However, the code was not working as expected. As it turns out, the code I was trying to use (based on our existing code from another project)
crypto.subtle, which appears not to be implemented in PerryTS currently, fine whatever. The more challenging issues I faced (as I see them) are as follows:While there is an attempt to re-implement various NodeJS APIs, the implementations are not complete (understandable/expected). However, there is no way to tell what is available without reviewing the Rust source code. Some documentation, or perhaps PerryTS specific TypeScript type definitions would be very helpful here.
The compiled code seems to continue running despite functions and properties being dereferenced against
undefined. This is surprising, as any JavaScript run-time will throw/panic/etc when attempting property access on an undefined value. The real impact is that it makes it extremely hard to tell where the code is actually going wrong, and the developer is reduced to placingconsole.logstatements after every line of the program.Concretely, these are the specific suggestions I would make:
undefined.Beta Was this translation helpful? Give feedback.
All reactions