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 near sdk pointer to 5 alpha (via git only for now) #120

Merged
merged 12 commits into from
Jan 27, 2024

Conversation

dj8yfo
Copy link
Collaborator

@dj8yfo dj8yfo commented Dec 19, 2023

draft version contains pointer to branch from near/near-sdk-rs#1122

@dj8yfo dj8yfo changed the title chore: Update near sdk to 5 alpha (via fork and git only for now) chore: Update near sdk pointer to 5 alpha (via fork and git only for now) Dec 19, 2023
Comment on lines +72 to +73
assert_eq!(abi_root.body.functions.len(), 2);
let function = &abi_root.body.functions[1];
Copy link
Collaborator Author

@dj8yfo dj8yfo Dec 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all of changes, similar to these 2 lines, are caused by abi.json generated change from

{
  "schema_version": "0.4.0",
  "metadata": {
    "name": "test_dependency_default_features",
    "version": "0.1.0"
  },
  "body": {
    "functions": [
      {
        "name": "foo",
        "kind": "view",
        "params": {
          "serialization_type": "json",
          "args": [
            {
              "name": "a",
              "type_schema": {
                "type": "boolean"
              }
            },
            {
              "name": "b",
              "type_schema": {
                "type": "integer",
                "format": "uint32",
                "minimum": 0.0
              }
            }
          ]
        }
      }
    ],
    "root_schema": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "String",
      "type": "string"
    }
  }
}

to

{
  "schema_version": "0.4.0",
  "metadata": {
    "name": "test_dependency_default_features",
    "version": "0.1.0"
  },
  "body": {
    "functions": [
      {
        "name": "contract_source_metadata",
        "kind": "view"
      },
      {
        "name": "foo",
        "kind": "view",
        "params": {
          "serialization_type": "json",
          "args": [
            {
              "name": "a",
              "type_schema": {
                "type": "boolean"
              }
            },
            {
              "name": "b",
              "type_schema": {
                "type": "integer",
                "format": "uint32",
                "minimum": 0.0
              }
            }
          ]
        }
      }
    ],
    "root_schema": {
      "$schema": "http://json-schema.org/draft-07/schema#",
      "title": "String",
      "type": "string"
    }
  }
}

index in the second line depends on the alphabetic order of "add" or "foo" with respect to "contract_source_metadata"

@dj8yfo
Copy link
Collaborator Author

dj8yfo commented Dec 19, 2023

encountered near/near-sandbox#78 when creating this pr

@dj8yfo dj8yfo changed the title chore: Update near sdk pointer to 5 alpha (via fork and git only for now) chore: update near sdk pointer to 5 alpha (via fork and git only for now) Dec 19, 2023
@dj8yfo dj8yfo changed the title chore: update near sdk pointer to 5 alpha (via fork and git only for now) chore: update near sdk pointer to 5 alpha Dec 19, 2023
@dj8yfo dj8yfo changed the title chore: update near sdk pointer to 5 alpha chore: update near sdk pointer to 5 alpha (via git only for now) Dec 19, 2023
@dj8yfo dj8yfo marked this pull request as ready for review January 16, 2024 09:10
frol
frol previously approved these changes Jan 16, 2024
Copy link
Contributor

@frol frol left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. I hope we can merge it soon once near-sdk 5.0 is released

frol
frol previously approved these changes Jan 27, 2024
@frol frol enabled auto-merge (squash) January 27, 2024 11:10
@frol frol merged commit 313f722 into near:main Jan 27, 2024
14 checks passed
@dj8yfo dj8yfo deleted the update_near_sdk_to_5_alpha branch May 13, 2024 13:37
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.

2 participants