Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into buckram/update-osmosi…
Browse files Browse the repository at this point in the history
…s-tests-code-id-squashed
  • Loading branch information
Buckram123 committed Nov 15, 2024
2 parents 7ab4259 + 48444b7 commit 087de20
Show file tree
Hide file tree
Showing 6 changed files with 1,276 additions and 3,795 deletions.
85 changes: 73 additions & 12 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,14 @@ workflows:
- build-modules:
requires:
- build-branch
- build-schemas:
requires:
- build-branch
- merge-build-branch:
requires:
- build-framework
- build-modules
- build-schemas

modules-coverage:
when:
Expand Down Expand Up @@ -149,14 +153,6 @@ jobs:
command: |
set -e
./scripts/wasm-framework-ci.sh
- run:
name: Generate schemas
command: |
# Install deps
cargo install cargo-workspaces
cargo install just
# Run script
just schema
- save_cache:
paths:
# Cargo registry
Expand All @@ -174,9 +170,7 @@ jobs:
git pull
# Check for wasm changes
git add framework/artifacts --force
# Check for schema changes
git add schema --force
git commit -m 'Update framework WASM & Schemas [skip ci]' || true
git commit -m 'Update framework WASM' || true
git push origin "$CIRCLE_BRANCH-build" || true
- run:
name: Remove temporary branch if it failed during build framework
Expand Down Expand Up @@ -245,13 +239,80 @@ jobs:
failure_message: "**${CIRCLE_USERNAME}**'s modules WASM build failed. Please check why! 😭"
webhook: "${DISCORD_STATUS_WEBHOOK}"

build-schemas:
docker:
- image: cimg/rust:1.80.0
resource_class: xlarge
steps:
- setup_remote_docker
- checkout
- run:
name: "Check for newer workflow"
background: true
command: |
while true; do
sleep 5
LATEST_COMMIT=$(git ls-remote $CIRCLE_REPOSITORY_URL | grep "$CIRCLE_BRANCH$" | cut -f 1)
if [ "$LATEST_COMMIT" != "$CIRCLE_SHA1" ]; then
echo "more recent commit to branch, exiting"
# Remove temporary branch
git push origin --delete "$CIRCLE_BRANCH-build" || true
curl -X POST "https://circleci.com/api/v2/workflow/$CIRCLE_WORKFLOW_ID/cancel?circle-token=$CIRCLE_API_TOKEN"
fi
done
- run:
name: Checkout temporary branch
command: |
git fetch origin "$CIRCLE_BRANCH-build"
git checkout "$CIRCLE_BRANCH-build"
- restore_cache:
keys:
- cargocache-v2-build-rust:1.80.0-{{ checksum "framework/Cargo.lock" }}
- run:
name: Generate schemas
command: |
# Install deps
cargo install cargo-workspaces
cargo install just
# Run script
just schema
- run:
name: Commit and push schemas
command: |
git config --global user.name 'CircleCI'
git config --global user.email '[email protected]'
# Pull latest changes
git pull
# Check for schema changes
git add schema --force
git commit -m 'Update Schemas [skip ci]' || true
git push origin "$CIRCLE_BRANCH-build" || true
- run:
name: Remove temporary branch if it failed during build schemas
when: on_fail
command: git push origin --delete "$CIRCLE_BRANCH-build" || true
- discord/status:
fail_only: true
failure_message: "**${CIRCLE_USERNAME}**'s schemas build failed. Please check why! 😭"
webhook: "${DISCORD_STATUS_WEBHOOK}"

merge-build-branch:
docker:
- image: cimg/base:2024.01
resource_class: small
steps:
- setup_remote_docker
- checkout
- run:
name: Import GPG Key
command: |
echo -e "$GPG_PRIVATE_KEY" | gpg --import
echo -e "trust\n5\ny\n" | gpg --command-fd 0 --edit-key 4C19E4CC17E67B7B
- run:
name: Configure Git for Signing
command: |
git config --global user.signingkey 4C19E4CC17E67B7B
git config --global commit.gpgSign true
- run:
name: "Merge build branch"
command: |
Expand All @@ -262,7 +323,7 @@ jobs:
git fetch origin "$CIRCLE_BRANCH-build"
# Merge artifacts to a branch
git merge "origin/$CIRCLE_BRANCH-build" --squash
git commit -m "Update WASM & Schemas [skip ci]" || echo "No changes to commit"
git commit -S -m "Update WASM & Schemas [skip ci]" || echo "No changes to commit"
git push origin $CIRCLE_BRANCH || true
# Delete temporary branch
git push origin --delete "$CIRCLE_BRANCH-build"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"contract_name": "abstract-account",
"contract_version": "0.24.1",
"contract_version": "0.24.2",
"idl_version": "1.0.0",
"instantiate": {
"$schema": "http://json-schema.org/draft-07/schema#",
Expand Down Expand Up @@ -132,15 +132,14 @@
]
},
"AddAuthenticator": {
"description": "Note: Instead of transaction bytes address of the Abstract Account used",
"oneOf": [
{
"type": "object",
"required": [
"secp256_k1"
"Secp256K1"
],
"properties": {
"secp256_k1": {
"Secp256K1": {
"type": "object",
"required": [
"id",
Expand Down Expand Up @@ -168,10 +167,10 @@
{
"type": "object",
"required": [
"ed25519"
"Ed25519"
],
"properties": {
"ed25519": {
"Ed25519": {
"type": "object",
"required": [
"id",
Expand Down Expand Up @@ -199,10 +198,10 @@
{
"type": "object",
"required": [
"eth_wallet"
"EthWallet"
],
"properties": {
"eth_wallet": {
"EthWallet": {
"type": "object",
"required": [
"address",
Expand Down Expand Up @@ -230,10 +229,10 @@
{
"type": "object",
"required": [
"jwt"
"Jwt"
],
"properties": {
"jwt": {
"Jwt": {
"type": "object",
"required": [
"aud",
Expand Down Expand Up @@ -265,10 +264,10 @@
{
"type": "object",
"required": [
"secp256_r1"
"Secp256R1"
],
"properties": {
"secp256_r1": {
"Secp256R1": {
"type": "object",
"required": [
"id",
Expand Down Expand Up @@ -296,10 +295,10 @@
{
"type": "object",
"required": [
"passkey"
"Passkey"
],
"properties": {
"passkey": {
"Passkey": {
"type": "object",
"required": [
"credential",
Expand Down Expand Up @@ -790,7 +789,7 @@
"additionalProperties": false
},
{
"description": "Upgrade the module to a new version If module is `abstract::account` then the contract will do a self-migration. Self-migration is protected and only possible to the [`crate::objects::module_reference::ModuleReference::Account`] registered in Version Control",
"description": "Upgrade the module to a new version If module is `abstract::account` then the contract will do a self-migration. Self-migration is protected and only possible to the [`crate::objects::module_reference::ModuleReference::Account`] registered in Registry",
"type": "object",
"required": [
"upgrade"
Expand Down Expand Up @@ -1018,15 +1017,14 @@
],
"definitions": {
"AddAuthenticator": {
"description": "Note: Instead of transaction bytes address of the Abstract Account used",
"oneOf": [
{
"type": "object",
"required": [
"secp256_k1"
"Secp256K1"
],
"properties": {
"secp256_k1": {
"Secp256K1": {
"type": "object",
"required": [
"id",
Expand Down Expand Up @@ -1054,10 +1052,10 @@
{
"type": "object",
"required": [
"ed25519"
"Ed25519"
],
"properties": {
"ed25519": {
"Ed25519": {
"type": "object",
"required": [
"id",
Expand Down Expand Up @@ -1085,10 +1083,10 @@
{
"type": "object",
"required": [
"eth_wallet"
"EthWallet"
],
"properties": {
"eth_wallet": {
"EthWallet": {
"type": "object",
"required": [
"address",
Expand Down Expand Up @@ -1116,10 +1114,10 @@
{
"type": "object",
"required": [
"jwt"
"Jwt"
],
"properties": {
"jwt": {
"Jwt": {
"type": "object",
"required": [
"aud",
Expand Down Expand Up @@ -1151,10 +1149,10 @@
{
"type": "object",
"required": [
"secp256_r1"
"Secp256R1"
],
"properties": {
"secp256_r1": {
"Secp256R1": {
"type": "object",
"required": [
"id",
Expand Down Expand Up @@ -1182,10 +1180,10 @@
{
"type": "object",
"required": [
"passkey"
"Passkey"
],
"properties": {
"passkey": {
"Passkey": {
"type": "object",
"required": [
"credential",
Expand Down
40 changes: 3 additions & 37 deletions schema/ibc-client/0.24.1/abstract-ibc-client.json
Original file line number Diff line number Diff line change
Expand Up @@ -1331,7 +1331,7 @@
"additionalProperties": false
},
{
"description": "Upgrade the module to a new version If module is `abstract::account` then the contract will do a self-migration. Self-migration is protected and only possible to the [`crate::objects::module_reference::ModuleReference::Account`] registered in Version Control",
"description": "Upgrade the module to a new version If module is `abstract::account` then the contract will do a self-migration. Self-migration is protected and only possible to the [`crate::objects::module_reference::ModuleReference::Account`] registered in Registry",
"type": "object",
"required": [
"upgrade"
Expand Down Expand Up @@ -3615,42 +3615,8 @@
"migrate": {
"$schema": "http://json-schema.org/draft-07/schema#",
"title": "MigrateMsg",
"oneOf": [
{
"description": "Migrating from blob contract",
"type": "object",
"required": [
"instantiate"
],
"properties": {
"instantiate": {
"$ref": "#/definitions/InstantiateMsg"
}
},
"additionalProperties": false
},
{
"description": "Migrating from previous version",
"type": "object",
"required": [
"migrate"
],
"properties": {
"migrate": {
"type": "object",
"additionalProperties": false
}
},
"additionalProperties": false
}
],
"definitions": {
"InstantiateMsg": {
"description": "This needs no info. Owner of the contract is whoever signed the InstantiateMsg.",
"type": "object",
"additionalProperties": false
}
}
"type": "object",
"additionalProperties": false
},
"sudo": null,
"responses": {
Expand Down
Loading

0 comments on commit 087de20

Please sign in to comment.