-
Notifications
You must be signed in to change notification settings - Fork 8
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
use 10 positions #24
Merged
Merged
use 10 positions #24
Changes from all commits
Commits
Show all changes
52 commits
Select commit
Hold shift + click to select a range
0dd85ac
add empowering text
faddat 0a8432a
update readme
faddat c3830d6
abstract out the joint pieces that are used to broadcast
faddat e5f11cf
add the position feature
faddat 5a5bf70
continue cleaning
faddat 0963dd5
add cursorignore
faddat 7972f1a
eliminate dirtiness
faddat 87bcc32
cleanup rust contract code
faddat 149ab9d
additional cleanup & linting
faddat cc71bc1
Merge branch 'main' into faddat/grpc2
faddat a8f5a12
additional positions related code
faddat 0416856
fix typo
faddat 62426e6
Merge branch 'faddat/grpc2' of https://github.com/somatic-labs/meteor…
faddat 33706bb
run latest clippy
faddat 187391e
additional updates while debugging
faddat a9b16ba
Update main.go
faddat 588b2e2
Update types/types.go
faddat 8fa323b
Merge branch 'faddat/grpc2' of https://github.com/somatic-labs/meteor…
faddat c282598
Merge branch 'faddat/grpc2' of https://github.com/somatic-labs/meteor…
faddat 9a7e418
add tests
faddat 99e7b0b
add main_test
faddat f923132
Update main.go
faddat bc7ffba
Update lib/lib.go
faddat 1472db3
Update lib/lib.go
faddat 356d029
further test related updates
faddat 928e1a9
Merge branch 'faddat/grpc2' of https://github.com/somatic-labs/meteor…
faddat 0f8bdd7
save place
faddat 4ffab1d
get back to working state
faddat f148821
update tests
faddat 6582f45
reduce errors to 1
faddat e0c2963
Update lib/lib.go
faddat 82268b6
Update main.go
faddat cab072b
Update main_test.go
faddat ffa2175
Update main.go
faddat a12f662
balancing transactions now working
faddat 0dbeb4f
Merge branch 'faddat/grpc2' of https://github.com/somatic-labs/meteor…
faddat f792535
bring in the army: positions are here
faddat 066fedb
add cursor rules
faddat a4a90dd
early version of gatling gun mode
faddat 6d238d0
Update main.go
faddat 9fb70bc
Create test.yml
faddat b38a583
Revert "Update main.go"
faddat 669f150
add further timing debugging tools
faddat 33abf49
bank send....
faddat 9c0ce57
further accelerate, supporting 50 simultaneous positions
faddat 7a1d973
Update main.go
faddat 82c12d3
Update lib/lib.go
faddat 51812e6
hardhat
faddat 5ff4bc1
fix tests
faddat 7e0b920
Merge branch 'faddat/grpc2' of https://github.com/somatic-labs/meteor…
faddat 26dcf75
Update lib/lib.go
faddat f662930
Update main.go
faddat File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Add directories or file patterns to ignore during indexing (e.g. foo/ or *.csv) | ||
emails/ | ||
configurations/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
// Hardhat .cursorrules | ||
|
||
// HTMX and Go best practices | ||
const htmxGoBestPractices = [ | ||
"follow practices suited for cosmos-sdk v0.50.x", | ||
"follow practices suited for ibc-go v8.x.x" | ||
]; | ||
|
||
// Folder structure | ||
const folderStructure = ` | ||
main.go | ||
lib/ | ||
|
||
modules/ | ||
go.mod | ||
go.sum | ||
`; | ||
|
||
// Additional instructions | ||
const additionalInstructions = ` | ||
1. We are building a high speed test framework for mainnets | ||
2. We should aim for this application to be precise and performant | ||
`; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# .github/workflows/clippy.yml | ||
name: Clippy | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
workflow_dispatch: | ||
|
||
jobs: | ||
clippy: | ||
name: Run Clippy | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
components: clippy | ||
- name: Run Clippy | ||
uses: actions-rs/clippy-check@v1 | ||
with: | ||
token: ${{ secrets.GITHUB_TOKEN }} | ||
args: --all-features --manifest-path contracts/statefilestore/Cargo.toml -- -D warnings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
name: Test | ||
jobs: | ||
test: | ||
strategy: | ||
matrix: | ||
go-version: [1.23.x] | ||
os: [ubuntu-latest, macos-latest] | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: actions/setup-go@v5 | ||
with: | ||
go-version: ${{ matrix.go-version }} | ||
- run: go test ./... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
target/ | ||
**seedphrase | ||
**meteorite | ||
**meteorite |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
package broadcast | ||
|
||
import ( | ||
"context" | ||
"fmt" | ||
"sync" | ||
"time" | ||
|
||
cometrpc "github.com/cometbft/cometbft/rpc/client/http" | ||
coretypes "github.com/cometbft/cometbft/rpc/core/types" | ||
tmtypes "github.com/cometbft/cometbft/types" | ||
) | ||
|
||
type Client struct { | ||
client *cometrpc.HTTP | ||
} | ||
|
||
var ( | ||
clients = make(map[string]*Client) | ||
clientsMux sync.RWMutex | ||
) | ||
|
||
func GetClient(rpcEndpoint string) (*Client, error) { | ||
clientsMux.RLock() | ||
if client, exists := clients[rpcEndpoint]; exists { | ||
clientsMux.RUnlock() | ||
return client, nil | ||
} | ||
clientsMux.RUnlock() | ||
|
||
// If client doesn't exist, acquire write lock and create it | ||
clientsMux.Lock() | ||
defer clientsMux.Unlock() | ||
|
||
// Double-check after acquiring write lock | ||
if client, exists := clients[rpcEndpoint]; exists { | ||
return client, nil | ||
} | ||
|
||
// Create new client | ||
cmtCli, err := cometrpc.New(rpcEndpoint, "/websocket") | ||
if err != nil { | ||
return nil, err | ||
} | ||
|
||
client := &Client{ | ||
client: cmtCli, | ||
} | ||
clients[rpcEndpoint] = client | ||
return client, nil | ||
} | ||
|
||
func (b *Client) Transaction(txBytes []byte) (*coretypes.ResultBroadcastTx, error) { | ||
ctx, cancel := context.WithTimeout(context.Background(), 100*time.Millisecond) | ||
defer cancel() | ||
|
||
t := tmtypes.Tx(txBytes) | ||
res, err := b.client.BroadcastTxSync(ctx, t) | ||
if err != nil { | ||
return nil, err | ||
} | ||
|
||
if res.Code != 0 { | ||
return res, fmt.Errorf("broadcast error code %d: %s", res.Code, res.Log) | ||
} | ||
|
||
return res, nil | ||
} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codebase verification
Citation needed for financial loss claim and promotional terms need revision
While P2P storms are documented as a significant issue (mentioned in multiple places in the README and configuration files, with specific incidents in Luna Classic 2022 and Stride 2023), the exact financial loss figure ($70,001,400,000) lacks any verifiable source or citation.
The promotional offer needs to be more specific:
🔗 Analysis chain
Add citation and clarify promotional offer.
Let's verify if this figure is mentioned elsewhere in the codebase:
🏁 Scripts executed
The following scripts were executed for the analysis:
Script:
Length of output: 34
Script:
Length of output: 7531