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

chore: update BDJuno name to Callisto #704

Merged
merged 4 commits into from
Feb 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,18 @@ jobs:
- name: Checkout 🛎️
uses: actions/checkout@v4

- name: Set BDJuno chain name 🔧
- name: Set Callisto chain name 🔧
shell: bash
run: echo "CHAIN_NAME=$(echo ${GITHUB_REF#refs/heads/} | sed 's/\//_/g')" >> $GITHUB_ENV

- name: Set BDJuno version 🔧
- name: Set Callisto version 🔧
shell: bash
run: echo "GITHUB_VERSION=$(git describe --tags)" >> $GITHUB_ENV

- name: Prepare tags 🏷️
id: prep
run: |
DOCKER_IMAGE=${{ secrets.DOCKERHUB_BDJUNO_REPO }}
DOCKER_IMAGE=${{ secrets.DOCKERHUB_CALLISTO_REPO }}
CHAIN_NAME="${{env.CHAIN_NAME}}"
VERSION="${{env.GITHUB_VERSION}}"
TAGS="${DOCKER_IMAGE}:${CHAIN_NAME}-${VERSION}"
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
- ([\#610](https://github.com/forbole/bdjuno/pull/610)) Add support for gov `v1` proposals
- ([\#652](https://github.com/forbole/bdjuno/pull/652)) Update gov module parsing
- ([\#702](https://github.com/forbole/bdjuno/pull/702)) Add `message_type` module and store msg types inside `message_type` table, add `messages_by_type` function to allow to query messages by their types
- ([\#704](https://github.com/forbole/bdjuno/pull/704)) Update `BDJuno` name to `Callisto`

## Version v4.0.0
## Notes
Expand Down
8 changes: 4 additions & 4 deletions Dockerfile.cosmwasm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

FROM golang:1.20-alpine AS builder
RUN apk update && apk add --no-cache make git
WORKDIR /go/src/github.com/forbole/bdjuno
WORKDIR /go/src/github.com/forbole/callisto
COPY . ./

RUN apk update && apk add --no-cache ca-certificates build-base git
Expand All @@ -17,6 +17,6 @@ RUN LINK_STATICALLY=true BUILD_TAGS="muslc" make build

FROM alpine:latest
RUN apk update && apk add --no-cache ca-certificates build-base
WORKDIR /bdjuno
COPY --from=builder /go/src/github.com/forbole/bdjuno/build/bdjuno /usr/bin/bdjuno
CMD [ "bdjuno" ]
WORKDIR /callisto
COPY --from=builder /go/src/github.com/forbole/callisto/build/callisto /usr/bin/callisto
CMD [ "callisto" ]
8 changes: 4 additions & 4 deletions Dockerfile.default
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
FROM golang:1.20-alpine AS builder
RUN apk update && apk add --no-cache make git
WORKDIR /go/src/github.com/forbole/bdjuno
WORKDIR /go/src/github.com/forbole/callisto
COPY . ./
RUN go mod download
RUN make build

FROM alpine:latest
WORKDIR /bdjuno
COPY --from=builder /go/src/github.com/forbole/bdjuno/build/bdjuno /usr/bin/bdjuno
CMD [ "bdjuno" ]
WORKDIR /callisto
COPY --from=builder /go/src/github.com/forbole/callisto/build/callisto /usr/bin/callisto
CMD [ "callisto" ]
18 changes: 9 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,11 @@ BUILD_FLAGS := -ldflags '$(LD_FLAGS)' -tags "$(build_tags)"

build: go.sum
ifeq ($(OS),Windows_NT)
@echo "building bdjuno binary..."
@go build -mod=readonly $(BUILD_FLAGS) -o build/bdjuno.exe ./cmd/bdjuno
@echo "building callisto binary..."
@go build -mod=readonly $(BUILD_FLAGS) -o build/callisto.exe ./cmd/callisto
else
@echo "building bdjuno binary..."
@go build -mod=readonly $(BUILD_FLAGS) -o build/bdjuno ./cmd/bdjuno
@echo "building callisto binary..."
@go build -mod=readonly $(BUILD_FLAGS) -o build/callisto ./cmd/callisto
endif
.PHONY: build

Expand All @@ -45,8 +45,8 @@ endif
###############################################################################

install: go.sum
@echo "installing bdjuno binary..."
@go install -mod=readonly $(BUILD_FLAGS) ./cmd/bdjuno
@echo "installing callisto binary..."
@go install -mod=readonly $(BUILD_FLAGS) ./cmd/callisto
.PHONY: install

###############################################################################
Expand All @@ -55,12 +55,12 @@ install: go.sum

stop-docker-test:
@echo "Stopping Docker container..."
@docker stop bdjuno-test-db || true && docker rm bdjuno-test-db || true
@docker stop callisto-test-db || true && docker rm callisto-test-db || true
.PHONY: stop-docker-test

start-docker-test: stop-docker-test
@echo "Starting Docker container..."
@docker run --name bdjuno-test-db -e POSTGRES_USER=bdjuno -e POSTGRES_PASSWORD=password -e POSTGRES_DB=bdjuno -d -p 6433:5432 postgres
@docker run --name callisto-test-db -e POSTGRES_USER=callisto -e POSTGRES_PASSWORD=password -e POSTGRES_DB=callisto -d -p 6433:5432 postgres
.PHONY: start-docker-test

test-unit: start-docker-test
Expand All @@ -86,7 +86,7 @@ lint-fix:
format:
find . -name '*.go' -type f -not -path "*.git*" -not -name '*.pb.go' -not -name '*_mocks.go' | xargs gofmt -w -s
find . -name '*.go' -type f -not -path "*.git*" -not -name '*.pb.go' -not -name '*_mocks.go' | xargs misspell -w
find . -name '*.go' -type f -not -path "*.git*" -not -name '*.pb.go' -not -name '*_mocks.go' | xargs goimports -w -local github.com/forbole/bdjuno
find . -name '*.go' -type f -not -path "*.git*" -not -name '*.pb.go' -not -name '*_mocks.go' | xargs goimports -w -local github.com/forbole/callisto
.PHONY: format

clean:
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
# BDJuno
# Callisto
[![GitHub Workflow Status](https://img.shields.io/github/workflow/status/forbole/bdjuno/Tests)](https://github.com/forbole/bdjuno/actions?query=workflow%3ATests)
[![Go Report Card](https://goreportcard.com/badge/github.com/forbole/bdjuno)](https://goreportcard.com/report/github.com/forbole/bdjuno)
![Codecov branch](https://img.shields.io/codecov/c/github/forbole/bdjuno/cosmos/v0.40.x)

BDJuno (shorthand for BigDipper Juno) is the [Juno](https://github.com/forbole/juno) implementation
for [BigDipper](https://github.com/forbole/big-dipper).
Callisto (formerly BDJuno) is the [Juno](https://github.com/forbole/juno) implementation
for [Big Dipper](https://github.com/forbole/big-dipper).

It extends the custom Juno behavior by adding different handlers and custom operations to make it easier for BigDipper
It extends the custom Juno behavior by adding different handlers and custom operations to make it easier for Big Dipper
showing the data inside the UI.

All the chains' data that are queried from the RPC and gRPC endpoints are stored inside
a [PostgreSQL](https://www.postgresql.org/) database on top of which [GraphQL](https://graphql.org/) APIs can then be
created using [Hasura](https://hasura.io/).

## Usage
To know how to setup and run BDJuno, please refer to
To know how to setup and run Callisto, please refer to
the [docs website](https://docs.bigdipper.live/cosmos-based/parser/overview/).

## Testing
Expand Down
6 changes: 3 additions & 3 deletions Requirements.md
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Requirements of BDjuno
The BDjuno is working as a backend for Big Dipper. The followings are the features currently supported in Big Dipper in the backend which BDjuno should adapt.
# Requirements of Callisto
The Callisto is working as a backend for Big Dipper. The followings are the features currently supported in Big Dipper in the backend which Callisto should adapt.

## On every block
### Done by Juno by default
- [x] Parsing all blocks
- [x] Parsing all transactions
- [x] Store validator set of the block

### Custom BDJuno implementations
### Custom Callisto implementations
- [x] Update missed block records
- [x] Read the latest consensus state
- [x] [x/auth] Store vesting accounts and vesting periods details
Expand Down
12 changes: 6 additions & 6 deletions cmd/bdjuno/main.go → cmd/callisto/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@ import (
startcmd "github.com/forbole/juno/v5/cmd/start"
"github.com/forbole/juno/v5/modules/messages"

migratecmd "github.com/forbole/bdjuno/v4/cmd/migrate"
parsecmd "github.com/forbole/bdjuno/v4/cmd/parse"
migratecmd "github.com/forbole/callisto/v4/cmd/migrate"
parsecmd "github.com/forbole/callisto/v4/cmd/parse"

"github.com/forbole/bdjuno/v4/types/config"
"github.com/forbole/callisto/v4/types/config"

"cosmossdk.io/simapp"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules"
)

func main() {
Expand All @@ -28,7 +28,7 @@ func main() {
WithEncodingConfigBuilder(config.MakeEncodingConfig(getBasicManagers())).
WithRegistrar(modules.NewRegistrar(getAddressesParser()))

cfg := cmd.NewConfig("bdjuno").
cfg := cmd.NewConfig("callisto").
WithInitConfig(initCfg).
WithParseConfig(parseCfg)

Expand Down
4 changes: 2 additions & 2 deletions cmd/migrate/cmd.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
parsecmdtypes "github.com/forbole/juno/v5/cmd/parse/types"
"github.com/spf13/cobra"

v3 "github.com/forbole/bdjuno/v4/cmd/migrate/v3"
v5 "github.com/forbole/bdjuno/v4/cmd/migrate/v5"
v3 "github.com/forbole/callisto/v4/cmd/migrate/v3"
v5 "github.com/forbole/callisto/v4/cmd/migrate/v5"
)

type Migrator func(parseCfg *parsecmdtypes.Config) error
Expand Down
2 changes: 1 addition & 1 deletion cmd/migrate/v3/migrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"os"

"github.com/forbole/bdjuno/v4/modules/actions"
"github.com/forbole/callisto/v4/modules/actions"

parsecmdtypes "github.com/forbole/juno/v5/cmd/parse/types"

Expand Down
2 changes: 1 addition & 1 deletion cmd/migrate/v3/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package v3
import (
v3 "github.com/forbole/juno/v5/cmd/migrate/v3"

"github.com/forbole/bdjuno/v4/modules/actions"
"github.com/forbole/callisto/v4/modules/actions"
)

type Config struct {
Expand Down
2 changes: 1 addition & 1 deletion cmd/migrate/v5/migrate.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package v5
import (
"fmt"

v5db "github.com/forbole/bdjuno/v4/database/migrate/v5"
v5db "github.com/forbole/callisto/v4/database/migrate/v5"
parse "github.com/forbole/juno/v5/cmd/parse/types"
"github.com/forbole/juno/v5/database"
"github.com/forbole/juno/v5/database/postgresql"
Expand Down
6 changes: 3 additions & 3 deletions cmd/parse/auth/vesting.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@ import (
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
authutils "github.com/forbole/bdjuno/v4/modules/auth"
"github.com/forbole/bdjuno/v4/utils"
"github.com/forbole/callisto/v4/database"
authutils "github.com/forbole/callisto/v4/modules/auth"
"github.com/forbole/callisto/v4/utils"
)

// vestingCmd returns a Cobra command that allows to fix the vesting data for the accounts
Expand Down
6 changes: 3 additions & 3 deletions cmd/parse/bank/supply.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@ package bank
import (
"fmt"

modulestypes "github.com/forbole/bdjuno/v4/modules/types"
modulestypes "github.com/forbole/callisto/v4/modules/types"

parsecmdtypes "github.com/forbole/juno/v5/cmd/parse/types"
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/bank"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/bank"
)

// supplyCmd returns the Cobra command allowing to refresh x/bank total supply
Expand Down
6 changes: 3 additions & 3 deletions cmd/parse/distribution/communitypool.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/distribution"
modulestypes "github.com/forbole/bdjuno/v4/modules/types"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/distribution"
modulestypes "github.com/forbole/callisto/v4/modules/types"
)

// communityPoolCmd returns the Cobra command allowing to refresh community pool
Expand Down
6 changes: 3 additions & 3 deletions cmd/parse/feegrant/allowance.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ import (
parsecmdtypes "github.com/forbole/juno/v5/cmd/parse/types"
"github.com/forbole/juno/v5/types/config"

"github.com/forbole/bdjuno/v4/modules/feegrant"
"github.com/forbole/bdjuno/v4/utils"
"github.com/forbole/callisto/v4/modules/feegrant"
"github.com/forbole/callisto/v4/utils"

"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/callisto/v4/database"

tmctypes "github.com/cometbft/cometbft/rpc/core/types"

Expand Down
16 changes: 8 additions & 8 deletions cmd/parse/gov/proposal.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,21 @@ import (

"github.com/rs/zerolog/log"

modulestypes "github.com/forbole/bdjuno/v4/modules/types"
modulestypes "github.com/forbole/callisto/v4/modules/types"

govtypesv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"
parsecmdtypes "github.com/forbole/juno/v5/cmd/parse/types"
"github.com/forbole/juno/v5/parser"
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/distribution"
"github.com/forbole/bdjuno/v4/modules/gov"
"github.com/forbole/bdjuno/v4/modules/mint"
"github.com/forbole/bdjuno/v4/modules/slashing"
"github.com/forbole/bdjuno/v4/modules/staking"
"github.com/forbole/bdjuno/v4/utils"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/distribution"
"github.com/forbole/callisto/v4/modules/gov"
"github.com/forbole/callisto/v4/modules/mint"
"github.com/forbole/callisto/v4/modules/slashing"
"github.com/forbole/callisto/v4/modules/staking"
"github.com/forbole/callisto/v4/utils"
)

// proposalCmd returns the Cobra command allowing to fix all things related to a proposal
Expand Down
6 changes: 3 additions & 3 deletions cmd/parse/mint/inflation.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/mint"
modulestypes "github.com/forbole/bdjuno/v4/modules/types"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/mint"
modulestypes "github.com/forbole/callisto/v4/modules/types"
)

// inflationCmd returns the Cobra command allowing to refresh x/mint inflation
Expand Down
16 changes: 8 additions & 8 deletions cmd/parse/parse.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,14 +10,14 @@ import (

parsetransaction "github.com/forbole/juno/v5/cmd/parse/transactions"

parseauth "github.com/forbole/bdjuno/v4/cmd/parse/auth"
parsebank "github.com/forbole/bdjuno/v4/cmd/parse/bank"
parsedistribution "github.com/forbole/bdjuno/v4/cmd/parse/distribution"
parsefeegrant "github.com/forbole/bdjuno/v4/cmd/parse/feegrant"
parsegov "github.com/forbole/bdjuno/v4/cmd/parse/gov"
parsemint "github.com/forbole/bdjuno/v4/cmd/parse/mint"
parsepricefeed "github.com/forbole/bdjuno/v4/cmd/parse/pricefeed"
parsestaking "github.com/forbole/bdjuno/v4/cmd/parse/staking"
parseauth "github.com/forbole/callisto/v4/cmd/parse/auth"
parsebank "github.com/forbole/callisto/v4/cmd/parse/bank"
parsedistribution "github.com/forbole/callisto/v4/cmd/parse/distribution"
parsefeegrant "github.com/forbole/callisto/v4/cmd/parse/feegrant"
parsegov "github.com/forbole/callisto/v4/cmd/parse/gov"
parsemint "github.com/forbole/callisto/v4/cmd/parse/mint"
parsepricefeed "github.com/forbole/callisto/v4/cmd/parse/pricefeed"
parsestaking "github.com/forbole/callisto/v4/cmd/parse/staking"
)

// NewParseCmd returns the Cobra command allowing to parse some chain data without having to re-sync the whole database
Expand Down
4 changes: 2 additions & 2 deletions cmd/parse/pricefeed/price.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/pricefeed"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/pricefeed"
)

// priceCmd returns the Cobra command allowing to refresh token price
Expand Down
4 changes: 2 additions & 2 deletions cmd/parse/pricefeed/pricehistory.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ import (
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/pricefeed"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/pricefeed"
)

// priceHistoryCmd returns the Cobra command allowing to store token price history
Expand Down
6 changes: 3 additions & 3 deletions cmd/parse/staking/staking.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ import (
"github.com/forbole/juno/v5/types/config"
"github.com/spf13/cobra"

"github.com/forbole/bdjuno/v4/database"
"github.com/forbole/bdjuno/v4/modules/staking"
modulestypes "github.com/forbole/bdjuno/v4/modules/types"
"github.com/forbole/callisto/v4/database"
"github.com/forbole/callisto/v4/modules/staking"
modulestypes "github.com/forbole/callisto/v4/modules/types"
)

// poolCmd returns the Cobra command allowing to refresh x/staking pool
Expand Down
Loading
Loading