Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kit 191 4 hours get the upstream solana explorer working manually #3

Conversation

monological
Copy link

No description provided.

kespinola and others added 30 commits July 23, 2024 19:45
…e features activated for solana mainnet. custom url has been removed for the time being
Handle division by zero in percentage function
…tion#341)

When possible, use the anchor description card instead of the default
instruction card on the tx simulation page. 

Before:
<img width="1238" alt="Screen Shot 2024-05-19 at 1 01 28 PM"
src="https://github.com/solana-labs/explorer/assets/1320260/f11c902e-3fd1-4b30-8ecc-f79f103c1935">

After:
<img width="1273" alt="Screen Shot 2024-05-19 at 1 01 47 PM"
src="https://github.com/solana-labs/explorer/assets/1320260/2733821e-e807-41be-91a0-50d58d9e7851">
Use `bg-danger-soft` everywhere for Writable badges
This pr adds label support to two devnet programs for finternet

Finternet Token manager - `A5JxZVHgXe7fn5TqJXm6Hj2zKh1ptDapae2YjtXbZJoy`
Finternet User manager - `CmFuqQTLs2nQof5uaktJn1a6k2VdbGmZPfrJufB2Vm3F`

---------

Co-authored-by: ngundotra <noah@gundotra.org>
Couldn't force push to upstream branch for solana-foundation#236 , so I rebased on master
& created this new PR.

cc @crypt0miester @alinalexa

---------

Co-authored-by: Cryptomiester <77497858+crypt0miester@users.noreply.github.com>
Co-authored-by: Alin Alexa <alexa.alin@gmail.com>
Adds ORE program mainnet id

---------

Co-authored-by: Noah Gundotra <ngundotra@users.noreply.github.com>
This PR adds a row to account headers for Program Accounts like so:
![Screenshot 2024-09-03 at 5 48
45 PM](https://github.com/user-attachments/assets/d135adef-c055-4e0b-9e9e-614de6a5b4b4)

---------

Co-authored-by: Noah Gundotra <noahgundotra@Noahs-MBP.localdomain>
- ports `anchor idl convert` to TS
- uses new anchor 0.30.1 idl type everywhere
- removes old anchor package

Still doesn't work for State Compression transactions:
-
http://localhost:3000/tx/TYgsD3iqLCK2KMeSPp7cyAboGhDZqgSCQUGwAdDWXKe1QeLWmBS7wpLBsp1Ma9z6rTYHRqvAwbnZA8qtAnwHCyD

Works for new Anchor IDLs:
-
http://localhost:3000/tx/52kfChUoUQLR5XkCm2Bx9c6oayeRZm9tno62ugHkPcBieojoGWZwEa1NpXaQFga83HtxTWu5ARqi544D65HTm4tB

Works for some old Anchor IDLs:
-
http://localhost:3000/tx/2iofwLXfEDjEqvGZNMuCzZF8TEGyvfogCVf4oDnAATLpGkUbSfPe7ZBuqNoNXzaV2Xb33AT7PRYd9HztdbTvF3GR?cluster=devnet

---------

Co-authored-by: Noah Gundotra <noahgundotra@Noahs-MBP.lan>
…DLs with bad types (solana-foundation#376)

Kamino YVaults program was not loading on the explorer with solana-foundation#374 due to
bad type "ScopeConversionChain" having undefined type "ScopePriceId"
which was not included in the IDL.

This PR fixes YVaults IDL loading by pruning unused anchor types. 

Example tx:
-
https://explorer.solana.com/tx/3KgAexzvZ8Kdmj1TCkdZ4RCrV5q9ihyZ1xUnXcSCwybybgCupQ8Mf21tZqQWx2eJh45ATZhMWg2FbbzxhYW6UoU6
Example account
-
https://explorer.solana.com/address/H8h7ZyS5qJR2cwLxvZQdPaNzLik17cRxB5pDvjdXeuBg/anchor-account
* fix long byte array display for anchor ix arguments
* add option to download idl
* add badge to show IDL version
* add toggle for viewing expanded IDL (no more clicking manually to
expand)
Co-authored-by: Noah Gundotra <ngundotra@users.noreply.github.com>
Co-authored-by: Noah Gundotra <noah@gundotra.org>
…olana-foundation#390)

This has been causing rate limiting issues when loading transactions
that have a lot of program interactions because each instruction
required fetching the entire program binary.

Also need a key flagship program to use this feature on mainnet to be
useful.
This PR adds new PNG and SVG favicons, similar to
[solana-com](https://github.com/solana-foundation/solana-com/tree/main/public)
for a better consistency. The [PNG](https://caniuse.com/link-icon-png)
fallback is used for legacy browsers while the [SVG
](https://caniuse.com/link-icon-svg) is added for supporting higher
resolutions.

---

The explorer app was previously using an obsolete Solana icon (right),
visible in the address bar below when compared to existing solana.com
favicon (left).

<img width="114" alt="image"
src="https://github.com/user-attachments/assets/98bd0bd7-92f6-4bd4-ae2c-a85dc8d2a248">
- Deriving the PDA from the upgrade authority and the program id, then
getting the parameter from the PDA and composing it into a solana-verify
comand

Like this people can easily copy the command from the explorer and
verify for themselfs.

Related Issue: 
solana-foundation#393 

Looks like this: 
<img width="1168" alt="image"
src="https://github.com/user-attachments/assets/708a886a-dc9b-4ab1-ac69-1465210c7611">

And like this when there is no Verify PDA:
<img width="1154" alt="image"
src="https://github.com/user-attachments/assets/d4952dd4-f996-4764-a7d8-3492bd24f396">

---------

Co-authored-by: Noah Gundotra <noah@gundotra.org>
pkxro and others added 18 commits November 9, 2024 22:25
- The network is humming and seeing 0 to 1 slot latency for tx inclusion
but there is an issue with statistic reporting. Adding disclaimer until
the issue is resolved

---------

Co-authored-by: Noah Gundotra <noah@gundotra.org>
Showing the repository URL in that case the on chain PDA was uploaded. 

Fix: 
The -- commit hash was always shown even when there was no commit hash
used in the verify args
…ons fixed (solana-foundation#415)

The API we are using to provide verified build information allows 3rd
parties to overwrite any verified build to a trivially passing verified
build.

This can be mitigated by having the API restrict verification requests
to only come from the program authority.

This information will be hidden from the explorer until this issue has
been mitigated..
# Changes to Note

- Mainnet ping chart is now provided as the median confirmation time for
transactions as reported by
[validators.app](https://www.validators.app/ping-thing?locale=en&network=mainnet)

Not a change, but worth calling out- TPS chart timing has never been 1-1
with ping information because TPS and Ping signals have different
sampling rates
Cache ping data with NextJS data cache
Verified Build information was susceptible to a "griefing" attack
disclosed by security firm Accretion. The vulnerability stemmed from the
fact that anyone could overwrite verified build information in the OSec
API by providing a more recent verified build information. This allowed
malicious actors to overwrite protocol's GitHub repo url in the OSec
API.

This has now been patched by OtterSec. The fix requires that program
developers write their verified build arguments on-chain using their
program authority.

For previously verified programs, their verification information was
uploaded by the OSec team. However, to update previously verified
information, teams must deploy their verified build information onchain.

For teams using multisig program authorities, we've described a process
to prepare this transaction using `solana-verify` `v0.4.0` here:
https://solana.com/developers/guides/advanced/verified-builds#how-to-verify-your-program-when-its-controlled-by-a-multisig-like-squads
…ana-foundation#427)

# Add explicit pnpm install step to README

## Problem
Running `pnpm dev` without first installing dependencies results in a
broken build, specifically due to missing `sass` and other required
packages. This can confuse new developers trying to set up the project.

## Solution
Added an explicit `pnpm i` step in the README development instructions
before the `pnpm dev` command to ensure all dependencies are properly
installed.

## Changes
- Added new bullet point explaining the `pnpm i` command and its purpose

## Testing
- Verified instructions work by following them on a fresh clone of the
repository

---------

Co-authored-by: Noah Gundotra <ngundotra@users.noreply.github.com>
… kit-191-4-hours-get-the-upstream-solana-explorer-working-manually
…et-the-upstream-solana-explorer-working-manually
Copy link

linear bot commented Dec 21, 2024

@monological monological force-pushed the kit-191-4-hours-get-the-upstream-solana-explorer-working-manually branch from 7ecd68e to 115a5a7 Compare December 21, 2024 04:24
@monological monological marked this pull request as ready for review December 21, 2024 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.