Skip to content

Commit

Permalink
Merge pull request #74 from DIG-Network/release/v0.0.1-alpha.80
Browse files Browse the repository at this point in the history
Release/v0.0.1 alpha.80
  • Loading branch information
MichaelTaylor3D authored Sep 24, 2024
2 parents 5d7a1a2 + c3caefc commit 79d074e
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 7 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@

All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.

### [0.0.1-alpha.80](https://github.com/DIG-Network/dig-chia-sdk/compare/v0.0.1-alpha.79...v0.0.1-alpha.80) (2024-09-24)


### Bug Fixes

* download store ([cfa2383](https://github.com/DIG-Network/dig-chia-sdk/commit/cfa238321af0f00911298fbd1bebba71af98222a))

### [0.0.1-alpha.79](https://github.com/DIG-Network/dig-chia-sdk/compare/v0.0.1-alpha.78...v0.0.1-alpha.79) (2024-09-24)


Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

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

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@dignetwork/dig-sdk",
"version": "0.0.1-alpha.79",
"version": "0.0.1-alpha.80",
"description": "",
"type": "commonjs",
"main": "./dist/index.js",
Expand Down
1 change: 0 additions & 1 deletion src/DataIntegrityTree/DataIntegrityTree.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,6 @@ class DataIntegrityTree {

if (options.rootHash) {
if (fs.existsSync(path.join(this.storeDir, `${options.rootHash}.dat`))) {
console.log(options);
this.tree = this.deserializeTree(options.rootHash);
} else {
throw new DataLayerError(
Expand Down
8 changes: 6 additions & 2 deletions src/DigNetwork/DigNetwork.ts
Original file line number Diff line number Diff line change
Expand Up @@ -169,8 +169,12 @@ export class DigNetwork {
continue;
}

// Download the store root and associated data
await selectedPeer.downloadStoreRoot(rootInfo.root_hash);
try {
// Download the store root and associated data
await selectedPeer.downloadStoreRoot(rootInfo.root_hash);
} catch (error) {
break;
}

// Clear the blacklist upon successful download
peerBlackList = [];
Expand Down
2 changes: 1 addition & 1 deletion src/DigNetwork/PropagationServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -695,7 +695,7 @@ export class PropagationServer {

const downloadPath = path.join(tempDir, storeId, dataPath);
if (!fs.existsSync(path.join(downloadPath, dataPath))) {
throw new Error(`Missing file: ${fileKey}, aborting session.`);
throw new Error(`Missing file!: ${Buffer.from(fileKey, "utf-8")}, aborting session.`);
}
}

Expand Down

0 comments on commit 79d074e

Please sign in to comment.