Jonas Hahn

9.1K posts

Jonas Hahn banner
Jonas Hahn

Jonas Hahn

@SolPlay_jonas

DevRel at Solana Foundation I love tinkering and games https://t.co/qIFMrp258k

Hamburg, Germany Katılım Nisan 2016
1.6K Takip Edilen9.5K Takipçiler
Sabitlenmiş Tweet
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
Some cool new @solana explorer features! - Payment Receipts - Account data overview and download - More Idl features (+ 1 surprise feature) What other features do you want to have?
English
15
18
91
8.6K
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
@redacted_noah @ansel_sol @jacobvcreech Yeah you need to find the idl accounts for the programs and then get all the transactions of it. Not not a very common usecase. But i agree probably good to have.
English
0
0
1
34
Noah 🎈
Noah 🎈@redacted_noah·
It’s not a problem most people think about until they have to backfill something. For the most part, current IDL + stream of data is fine. As the IDL upgrades the indexer gets restarted and works on new data. Old data stays already indexed. But now you’re Dune and you want to index all helium programs through history. What do you do? You’re effed.
English
1
0
1
49
Noah 🎈
Noah 🎈@redacted_noah·
Hey @jacobvcreech foundation should run an indexer that watches the metadata program an indexes the history of each IDL, including all versions. It should then expose a service that (1) gives me the current IDL for a program given a major version (so two majors can be active at the same time) and (2) gives me a history of every IDL change for a program between two timestamps, so I can make changes as I index. With Streamingfast + Claude you could probably vibecode this in a day.
karsten@karstenalytics

@redacted_noah the IDL situation is indeed unsatisfying… I started to build an IDL history for the projects I cover myself to solve this. Can still work nicely if you run it automated and potentially even let Claude create issues/ PRs if an IDL change would break something (on my side)

English
3
1
30
3.3K
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
So basically what you do is you get all pdas of a program to put them in a database? And you want an api that you can call that gets you all historical idls and in which a slots they were active? And then use that to know how to parse the account data? Is that correct? Could you maybe send me how you would like the spec to look like?
English
1
0
1
37
Noah 🎈
Noah 🎈@redacted_noah·
No offense to Ansel, but this is pretty important for historical indexing. I’d prefer a solution that’s going to last more or less forever. Would be nice if Foundation could give a grant for the code and then run it in perpetuity. This is the kind of common good that people won’t pay much money for themselves because it’s infrequently needed. And will just fumble and curse around it (as I have done many times). If it’s not free probably no one is paying for it unfortunately.
English
1
0
1
39
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
@ansel_sol @jacobvcreech @redacted_noah Sounds like you already have the service that noah is looking for. :D Can ppl maybe just pay for it to use it? In explorer we could then also use it and show a history of idls for example. 👀
English
1
0
1
43
A N S E L
A N S E L@ansel_sol·
@SolPlay_jonas @jacobvcreech @redacted_noah The tricky part is downloading the IDL after a program upgrade finalization/program data account swap event (you need to have a retry strategy in case it takes a moment) I’m using NATS for this on which it’s trivial but yea it’s a big infra to deploy for just that feature
English
1
0
2
44
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
This sounds like a good idea! Did someone build this already maybe? Otherwise we could maybe build it into the explorer and expose as api. 🤔
Noah 🎈@redacted_noah

Hey @jacobvcreech foundation should run an indexer that watches the metadata program an indexes the history of each IDL, including all versions. It should then expose a service that (1) gives me the current IDL for a program given a major version (so two majors can be active at the same time) and (2) gives me a history of every IDL change for a program between two timestamps, so I can make changes as I index. With Streamingfast + Claude you could probably vibecode this in a day.

English
3
0
8
848
A N S E L
A N S E L@ansel_sol·
@jacobvcreech @SolPlay_jonas @redacted_noah It’s part of a bigger non open source system on Tokamai, I’ll see how I can restore it and extract it Not sure it makes sense on its own without the old faithful / rpc streaming pipeline
English
1
0
2
35
Noah 🎈
Noah 🎈@redacted_noah·
It's been about a year, so I think it'd be fun to look back and see which of these complaints has been solved. 1. IDL infrastructure is even more of a mess now. There's now two sources of truth, the original PDA and now a metadata program. Unfortunately, the metadata program was built without first class support for IDL versioning. So, next time IDLs change major versions, expect more pain. 2. Parsing historical programs given the lack of IDL versioning/history is still a problem now, and with the added metadata program it's now slightly worse. 3. The read layer has improved substantially. Most rpc providers heavily index gPA, so it's not as bad (still bad). Indexers have gotten unbelievably reliable now, such that I trust running an entire UI off of indexed data. It's heavier, you have devops costs, but at least it works and you can customize to your heart's content. 4. Running an API powered by indexers is still somewhat pricey 5. Transaction sending and landing is more or less solved. I haven't had to think about this in months. Smooth as butter. 6. Anchor has gotten faster and they've fixed a lot of the issues that blow out memory. There's still a lot of improvements to be made here, and new frameworks/anchor v2 are coming. 7. CPI depth limit is set to be increased. So this will not be an issue for much longer. 8. TX size limits are set to be increased. So this will not be an issue for much longer. 9. Rent costs have gone down because SOL price shit the bed. Yay? They are also going to actually cut rent costs soon™ 10. All of the cNFT issues described still exist. These have mostly been solved by just not using cNFTs. Use core or token metadata nfts instead. 11. Errors have, for the most part, gotten better. There are still quite a few useless errors, though. 12. All of the top wallets are still closed source. No progress made there, and seems like no one cares. 13. Rust anchor client still sucks. 14. Explorers still have issues, but thanks to claude I built my own that solves most of the issues (explorer.chewing.glass) 15. The base RPC spec still sucks, but if you're okay with vendor lock-in, Helius has a ton of useful APIs. Transaction history. Ability to only fetch accounts that have changed since a given slot. Etc. 16. I actually haven't had a dependency hell issue in a few months, I also haven't upgraded anything. Maybe it's getting better? 17. I haven't had issues with preflight disabled transactions in a while. Not sure if they fixed these issues, or I just started simulating more often. 18. Running programs on a cron is largely fixed. I wrote tuktuk for this, and it's been running reliably for almost a year. Largely things seem to be getting better. I've noticed that a lot of the pain goes away if you shove all of your solana-related stuff into an API, and use that API from your various clients web2 style. You can leverage indexers for complex queries. You can change your program and IDLs without breaking all clients. You can record your own transaction history. Etc. I always had a dream that blockchain dev was a way to avoid devops costs and burden by running everything on decentralized infrastructure. We seem to have moved far from this ideal, web3 is just web2 with another kind of database. Doesn't look great for protocols outliving their parent companies, but as we've seen that almost never happens anyway.
Noah 🎈@redacted_noah

As requested, all my current complaints in no particular order: 1. Uploaded IDL on-chain management is a mess. It has no versioning history, and when IDLs have breaking changes (like anchor 0.30+) all old clients currently looking at the on-chain IDL break. Why can't I lock a client to an IDL major version? Why is every IDL producer slightly different? Anchor, shank, etc should all produce the same thing. Published IDLs are wonderful in that I can add an account that's referenced by a has_one or PDA without breaking existing TS clients. But they need proper versioning. 2. Related to 1, since there's no IDL history, parsing historic transactions on Solana is impossible. Contract endpoints change, IDLs change, there's no history of it. 3. Read layer. The read layer sucks. You can do a lot to structure your program code to optimize for point-queries using PDAs as a kind of index. Like a crappy redis. But the second you need to do list queries ("get me all governance proposals with this tag") you're hosed. gPA is a terrible thing to use. That means you need an indexer! 4. Indexers. I have spent literal years wrestling with indexing on Solana, trying to get it so you catch every anchor record and insert it into postgres. *Finally* I have a solution that works, thanks to @streamingfastio. But even one stream is ~$500/month. Not really accessible to a dev trying things out in their spare time. Fine for Helium. 5. Transaction sending and landing. This is arguably the ONE thing a blockchain should be good at. Why am I talking to like 5-10 different people to find the optimum way to restructure my tx builder+sender every 3 weeks? Prio fees, stake weight QoS, compute limits, jito, lookup tables, transaction vs VersionedTransaction (the most ugly interface ever in both ts and rust). There's just so much to unpack here. Wrap it all up and throw it in a black box I don't ever have to look at again. Please. 6. Anchor performance. Anchor hogs a bunch of memory, newest versions init_if_needed almost always causes it to blow the heap. It also uses a bunch of CUs. It's the most used framework for smart contracts, let's pour all the resources we have into making it better. Native solana code is seriously so ugly to read it's a security hazard. There's no reason anchor, which is all pretty macros, can't be made to be just as fast. 7. CPI call depth limit. It's arbitrary, and low. Sometimes for composability you need more. CPIs are also super expensive. @blockiosaurus has some nice posts on why composability is a lie. 8. Tx size limits. This is actually the least of my problems, I can almost always find a way to work around this. 9. Rent is TOO DAMN HIGH. Sol is mooning, so rent is getting crazy high. I work for a company with funding, so it's not an issue for me. But if I were trying to do Solana in my spare time, $3000 to deploy a smart contract is ridiculous. 10. cNFTs continue to cause issues. If you need to mint a cNFT, then do something with that cNFT, you need to wait for the cNFT to be indexed so you can get its proof so you can construct the subsequent transaction _doing_ something with that cNFT. Huge headache. I wish Core NFTs had existed when we migrated helium, I would have used those instead. 11. Errors. Solana errors are notoriously unhelpful. #L277" target="_blank" rel="nofollow noopener">github.com/anza-xyz/agave…. This entire list should tell you which account the error came from. This is actively being worked on by Solana devrel. 12. Wallets. Of the top 3 wallets (Phantom, Solflare, Backpack) none of them are open source. One is source available, but usually pretty out of date. Wtf. 13. Rust clients suck. Using things like anchor from typescript are a breeze, because there's dynamic account resolution of has_one's and PDAs. Every time I have to use rust, it's like going back to the stone age. 14. Explorers suck. Why am I still using explorer.solana.com? Because it's the only one that consistently doesn't have broken IDL parsing, and has all the information that I need, and works with localnet devnet and mainnet. But it's notably missing things like seeing all txs on a program and filtering by instruction type. 15. The base RPC spec is missing tons of functionality. For one, it sucks at priority fees. Second, it's missing read level functionality enterprise web apps usually make use of, like incremental updates. I shouldn't need to waste data refetching accounts if they haven't changed. But there's no way to say "getMultipleAccounts that have changed past block x" 16. Dependency hell. ALWAYS with the dependency hell. Semver is never followed, especially on rust clients. So upgrading dependencies is always a nightmare. 17. Error handling when you turn off preflight checks is horrendous. Often times, if you've messed up the tx (too large, don't have enough sol, etc) it'll just hang forever. Hanging forever has to be the least desirable outcome for anything. 18. No ability to easily run txs at a specified time/on a schedule without deploying your own workers/crons. RIP clockwork (dw, I'm building a solution to this) I'm sure there's more, but my build finished to it's back to work. This is just top of mind.

English
8
7
69
16.5K
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
There is some things that we could maybe take from the chewing glas explorer. Already looking into it. Its really cool. The pda relations are great. Yeah these errors being part of consensus makes it really hard. But longterm maybe we can still get it fixed. For idl indexing and historic parsed accounts i will see what we can do. Probably an api. The new codama kit clients are as good as anchor by now. Trying to get has_one in there with negotiations. You can now also cmd-click to see source and the error messages are great! The new codama rust clients i still have to try.
English
0
0
1
21
Jacob Creech
Jacob Creech@jacobvcreech·
1-2, yeah it's my fault but my expectation is it will get better long term with metadata program. Anchor IDL PDA was not a long term solution. 3 is at odds with 15 11 is so hard to change. @SolPlay_jonas has been going after it again 12, definitely do care. It's hard for us to do better than these massive companies 13 - please tell me more 14 - I feel like your explorer takes care of a different type of audience, but @SolPlay_jonas again to see what we need 16 - we now have a skill for this github.com/solana-foundat… and will have one with every upcoming release Please keep the feedback coming.
English
3
0
7
464
Jonas Hahn retweetledi
jo
jo@dev_jodee·
solana-keychain now supports @crossmint Smart + MPC wallet signing, same unified interface as all 9 backends. No app logic changes.
jo tweet media
English
2
6
20
1.2K
blade
blade@bl8_runner·
@SolPlay_jonas fwiw, our trading data stack can support this easily
English
1
0
4
121
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
You can now pay @solana gas fees in any SPL token using Kora! Full video below 👇
English
4
15
105
6.3K
Jonas Hahn
Jonas Hahn@SolPlay_jonas·
@dev_jodee Thanks for building it :D Its easy to make good content on great stuff :D
English
0
0
1
33