Skip to content

Commit

Permalink
Merge pull request #438 from coasys/release-0.8.1
Browse files Browse the repository at this point in the history
Release 0.8.1
  • Loading branch information
lucksus authored Dec 14, 2023
2 parents 2a5f048 + 2a21d1b commit 837575c
Show file tree
Hide file tree
Showing 38 changed files with 258 additions and 186 deletions.
88 changes: 44 additions & 44 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -365,47 +365,47 @@ jobs:
access: public


crates-publish:
runs-on: GH-hosted-ubuntu
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.73.0
override: true

- name: Install GO
uses: actions/setup-go@v4
with:
go-version: '1.20'

- uses: pnpm/action-setup@v2
with:
version: 8

- name: Install Linux Deps
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf protobuf-compiler cmake
- uses: actions/setup-node@v3
with:
node-version: '16.x'

- name: Cache cargo
id: cache-cargo
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
key: ${{ runner.os }}-cargo
restore-keys: ${{ runner.os }}-cargo

- run: rustup target add wasm32-unknown-unknown
- run: cd core && pnpm install && pnpm build && cd ..
- run: cargo install cargo-workspaces || echo "cargo-workspaces already installed"
- run: cargo login ${{ secrets.CARGO_REGISTRY_TOKEN }}
- run: cargo workspaces publish --from-git
#crates-publish:
# runs-on: GH-hosted-ubuntu
# steps:
# - uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1
# with:
# toolchain: 1.73.0
# override: true
#
# - name: Install GO
# uses: actions/setup-go@v4
# with:
# go-version: '1.20'
#
# - uses: pnpm/action-setup@v2
# with:
# version: 8
#
# - name: Install Linux Deps
# run: |
# sudo apt-get update
# sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf protobuf-compiler cmake
#
# - uses: actions/setup-node@v3
# with:
# node-version: '16.x'
#
# - name: Cache cargo
# id: cache-cargo
# uses: actions/cache@v3
# with:
# path: |
# ~/.cargo/bin/
# ~/.cargo/registry/index/
# ~/.cargo/registry/cache/
# ~/.cargo/git/db/
# key: ${{ runner.os }}-cargo
# restore-keys: ${{ runner.os }}-cargo
#
# - run: rustup target add wasm32-unknown-unknown
# - run: cd core && pnpm install && pnpm build && cd ..
# - run: cargo install cargo-workspaces || echo "cargo-workspaces already installed"
# - run: cargo login ${{ secrets.CARGO_REGISTRY_TOKEN }}
# - run: cargo workspaces publish --from-git
86 changes: 43 additions & 43 deletions .github/workflows/publish_staging.yml
Original file line number Diff line number Diff line change
Expand Up @@ -386,46 +386,46 @@ jobs:
access: public


crates-publish:
runs-on: GH-hosted-ubuntu
steps:
- uses: actions/checkout@v2
- uses: actions-rs/toolchain@v1
with:
toolchain: 1.73.0
override: true

- name: Install GO
uses: actions/setup-go@v4
with:
go-version: '1.20'

- uses: pnpm/action-setup@v2
with:
version: 8

- name: Install Linux Deps
run: |
sudo apt-get update
sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf protobuf-compiler cmake
- uses: actions/setup-node@v3
with:
node-version: '16.x'

- name: Cache cargo
id: cache-cargo
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
key: ${{ runner.os }}-cargo
restore-keys: ${{ runner.os }}-cargo
- run: rustup target add wasm32-unknown-unknown
- run: cd core && pnpm install && pnpm build && cd ..
- run: cargo install cargo-workspaces || echo "cargo-workspaces already installed"
- run: cargo login ${{ secrets.CARGO_REGISTRY_TOKEN }}
- run: cargo workspaces publish --from-git
#crates-publish:
# runs-on: GH-hosted-ubuntu
# steps:
# - uses: actions/checkout@v2
# - uses: actions-rs/toolchain@v1
# with:
# toolchain: 1.73.0
# override: true
#
# - name: Install GO
# uses: actions/setup-go@v4
# with:
# go-version: '1.20'
#
# - uses: pnpm/action-setup@v2
# with:
# version: 8
#
# - name: Install Linux Deps
# run: |
# sudo apt-get update
# sudo apt-get install -y libgtk-3-dev webkit2gtk-4.0 libappindicator3-dev librsvg2-dev patchelf protobuf-compiler cmake
#
# - uses: actions/setup-node@v3
# with:
# node-version: '16.x'
#
# - name: Cache cargo
# id: cache-cargo
# uses: actions/cache@v3
# with:
# path: |
# ~/.cargo/bin/
# ~/.cargo/registry/index/
# ~/.cargo/registry/cache/
# ~/.cargo/git/db/
# key: ${{ runner.os }}-cargo
# restore-keys: ${{ runner.os }}-cargo
# - run: rustup target add wasm32-unknown-unknown
# - run: cd core && pnpm install && pnpm build && cd ..
# - run: cargo install cargo-workspaces || echo "cargo-workspaces already installed"
# - run: cargo login ${{ secrets.CARGO_REGISTRY_TOKEN }}
# - run: cargo workspaces publish --from-git
9 changes: 5 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion bootstrap-languages/agent-language/hc-dna/workdir/dna.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
manifest_version: "1"
name: "agent-store"
description: "DNA for storing AD4M agent expressions"

integrity:
network_seed: 00000000-0000-0000-0000-000000000000
Expand Down
2 changes: 1 addition & 1 deletion bootstrap-languages/agent-language/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,5 @@
"md5": "^2.3.0",
"postcss": "^8.2.1"
},
"version": "0.8.0"
"version": "0.8.1"
}
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export class LinkAdapter implements LinkSyncAdapter {
// }

let serverRecordTimestamp = signal.serverRecordTimestamp;
if (!this.myCurrentTime|| this.myCurrentTime < serverRecordTimestamp) {
if (this.myCurrentTime && this.myCurrentTime < serverRecordTimestamp) {
//console.log("Returning that live signal to executor");
this.myCurrentTime = serverRecordTimestamp;
this.updateServerSyncState();
Expand Down
2 changes: 1 addition & 1 deletion bootstrap-languages/direct-message-language/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,5 +35,5 @@
"dependencies": {
"@types/node": "^18.0.0"
},
"version": "0.8.0"
"version": "0.8.1"
}
2 changes: 1 addition & 1 deletion bootstrap-languages/neighbourhood-language/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,5 @@
},
"author": "joshuadparkin@gmail.com",
"license": "ISC",
"version": "0.8.0"
"version": "0.8.1"
}
2 changes: 1 addition & 1 deletion bootstrap-languages/p-diff-sync/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,5 +38,5 @@
"devDependencies": {
"run-script-os": "^1.1.6"
},
"version": "0.8.0"
"version": "0.8.1"
}
2 changes: 1 addition & 1 deletion bootstrap-languages/perspective-language/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@
"typescript": "^4.5.5",
"uint8arrays": "^3.0.0"
},
"version": "0.8.0"
"version": "0.8.1"
}
2 changes: 1 addition & 1 deletion cli/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "ad4m"

version = "0.8.0"
version = "0.8.1"

edition = "2021"
authors = ["Nicolas Luck <nicolas@coasys.org>"]
Expand Down
9 changes: 5 additions & 4 deletions cli/mainnet_seed.json
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
{
"trustedAgents": [
"did:key:z6MkgtBC3UaxNLt5SFJmxHtzFUUeJLCxLiP8DTqJgwF9uCkv",
"did:key:z6MkvPpWxwXAnLtMcoc9sX7GEoJ96oNnQ3VcQJRLspNJfpE7"
],
"knownLinkLanguages": [
"QmzSYwdbqYjNe9NmhkRmSL5EJ1yaXFnUaMw7DEn5QUKGNunzHR1",
"QmzSYwdnfQH4XNUi6rcDAPnfFqes2YWEHP5oxET2vJ7YafXnaSk",
"QmzSYwdeC5L6ZyzwgEEVxKPm17UKwPttyXnmNHakjm3EweWq52W"
"QmzSYwdg8JYEkFbcaV1XizduGxGyPt4dPjeJ4DdzAKajSqdckBj",
"QmzSYwdox6uFm5D93VyDTqs7aGjQr5UHzhpRi7yPbAEhwCXFiju",
"QmzSYwdnHrRH8MmuPWKKrDvFoVyW5CophNpT1ipQUCcenPVTQnd"
],
"directMessageLanguage": "QmzSYwdf86wKbE4HCV4Hn2A24QEKb31rdYJWws5BActVtSuesSY",
"directMessageLanguage": "QmzSYwdhTvszHze6xSojgaDmm9iPGr78iSbvVnQ1SgXo7t62PA9",
"agentLanguage": "QmzSYwdZDdgxiyE8crozqbxoBP52h6ocMdDq2S2mg4ScjzVLWKQ",
"perspectiveLanguage": "QmzSYwddxFCzVD63LgR8MTBaUEcwf9jhB3XjLbYBp2q8V1MqVtS",
"neighbourhoodLanguage": "QmzSYwdo2a6E4XghRHrN5eCReyYRDeRE8VnRbvqgoWZsr9B4pxV",
Expand Down
2 changes: 1 addition & 1 deletion connect/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,5 +66,5 @@
"esbuild-plugin-replace": "^1.4.0",
"lit": "^2.3.1"
},
"version": "0.8.0"
"version": "0.8.1"
}
2 changes: 1 addition & 1 deletion core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,5 +57,5 @@
"typescript": "^4.6.2",
"ws": "8.13.0"
},
"version": "0.8.0"
"version": "0.8.1"
}
5 changes: 5 additions & 0 deletions core/src/Ad4mClient.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -787,6 +787,11 @@ describe('Ad4mClient', () => {
const r = await ad4mClient.perspective.removeLink('00001', {author: '', timestamp: '', proof: {signature: '', key: ''}, data:{source: 'root', target: 'none'}})
expect(r).toBeTruthy()
})

it('addSdna() smoke test', async () => {
const r = await ad4mClient.perspective.addSdna('00001', "Test", 'subject_class("Test", test)', 'subject_class');
expect(r).toBeTruthy()
})
})

describe('.runtime', () => {
Expand Down
9 changes: 9 additions & 0 deletions core/src/perspectives/PerspectiveClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -283,6 +283,15 @@ export class PerspectiveClient {
}))
}

async addSdna(uuid: string, name: string, sdnaCode: string, sdnaType: "subject_class" | "flow" | "custom"): Promise<boolean> {
return unwrapApolloResult(await this.#apolloClient.mutate({
mutation: gql`mutation perspectiveAddSdna($uuid: String!, $name: String!, $sdnaCode: String!, $sdnaType: String!) {
perspectiveAddSdna(uuid: $uuid, name: $name, sdnaCode: $sdnaCode, sdnaType: $sdnaType)
}`,
variables: { uuid, name, sdnaCode, sdnaType }
})).perspectiveAddSdna
}

// ExpressionClient functions, needed for Subjects:
async getExpression(expressionURI: string): Promise<ExpressionRendered> {
return await this.#expressionClient.get(expressionURI)
Expand Down
Loading

0 comments on commit 837575c

Please sign in to comment.