-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Pedro Simões
committed
Mar 3, 2021
1 parent
1253c6c
commit 3150a8c
Showing
43 changed files
with
99 additions
and
157 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,7 +22,7 @@ Developer Notes | |
- [Threads](#threads) | ||
- [Ignoring IDE/editor files](#ignoring-ideeditor-files) | ||
- [Development guidelines](#development-guidelines) | ||
- [General Sapphire Core](#general-sapphire-core) | ||
- [General Decenomy Core](#general-dashdiamond-core) | ||
- [Wallet](#wallet) | ||
- [General C++](#general-c) | ||
- [C++ data structures](#c-data-structures) | ||
|
@@ -125,7 +125,7 @@ Refer to [/test/functional/README.md#style-guidelines](/test/functional/README.m | |
Coding Style (Doxygen-compatible comments) | ||
------------------------------------------ | ||
|
||
Sapphire Core uses [Doxygen](http://www.doxygen.nl/) to generate its official documentation. | ||
Dash Diamond Core uses [Doxygen](http://www.doxygen.nl/) to generate its official documentation. | ||
|
||
Use Doxygen-compatible comment blocks for functions, methods, and fields. | ||
|
||
|
@@ -224,7 +224,7 @@ that run in `-regtest` mode. | |
|
||
### DEBUG_LOCKORDER | ||
|
||
Sapphire Core is a multi-threaded application, and deadlocks or other | ||
Dash Diamond Core is a multi-threaded application, and deadlocks or other | ||
multi-threading bugs can be very difficult to track down. The `--enable-debug` | ||
configure option adds `-DDEBUG_LOCKORDER` to the compiler flags. This inserts | ||
run-time checks to keep track of which locks are held, and adds warnings to the | ||
|
@@ -234,15 +234,15 @@ debug.log file if inconsistencies are detected. | |
|
||
Valgrind is a programming tool for memory debugging, memory leak detection, and | ||
profiling. The repo contains a Valgrind suppressions file | ||
([`valgrind.supp`](https://github.com/sappcoin-com/SAPP/blob/master/contrib/valgrind.supp)) | ||
([`valgrind.supp`](https://github.com/Dash-Diamond/DASHD/blob/master/contrib/valgrind.supp)) | ||
which includes known Valgrind warnings in our dependencies that cannot be fixed | ||
in-tree. Example use: | ||
|
||
```shell | ||
$ valgrind --suppressions=contrib/valgrind.supp src/test/test_sapphire | ||
$ valgrind --suppressions=contrib/valgrind.supp src/test/test_dashdiamond | ||
$ valgrind --suppressions=contrib/valgrind.supp --leak-check=full \ | ||
--show-leak-kinds=all src/test/test_sapphire --log_level=test_suite | ||
$ valgrind -v --leak-check=full src/sapphired -printtoconsole | ||
--show-leak-kinds=all src/test/test_dashdiamond --log_level=test_suite | ||
$ valgrind -v --leak-check=full src/dashdiamondd -printtoconsole | ||
``` | ||
|
||
### Compiling for test coverage | ||
|
@@ -315,7 +315,7 @@ Ignoring IDE/editor files | |
In closed-source environments in which everyone uses the same IDE it is common | ||
to add temporary files it produces to the project-wide `.gitignore` file. | ||
|
||
However, in open source software such as Sapphire Core, where everyone uses | ||
However, in open source software such as Decenomy Core, where everyone uses | ||
their own editors/IDE/tools, it is less common. Only you know what files your | ||
editor produces and this may change from version to version. The canonical way | ||
to do this is thus to create your local gitignore. Add this to `~/.gitconfig`: | ||
|
@@ -345,9 +345,9 @@ Development guidelines | |
============================ | ||
|
||
A few non-style-related recommendations for developers, as well as points to | ||
pay attention to for reviewers of Sapphire Core code. | ||
pay attention to for reviewers of Decenomy Core code. | ||
|
||
General Sapphire Core | ||
General Dash Diamond Core | ||
---------------------- | ||
|
||
- New features should be exposed on RPC first, then can be made available in the GUI | ||
|
@@ -508,7 +508,7 @@ Strings and formatting | |
- For `strprintf`, `LogPrint`, `LogPrintf` formatting characters don't need size specifiers | ||
- *Rationale*: Sapphire Core uses tinyformat, which is type safe. Leave them out to avoid confusion | ||
- *Rationale*: Dash Diamond Core uses tinyformat, which is type safe. Leave them out to avoid confusion | ||
Variable names | ||
-------------- | ||
|
@@ -659,7 +659,7 @@ directly upstream without being PRed directly against the project. They will be | |
subtree merge. | ||
|
||
Others are external projects without a tight relationship with our project. Changes to these should also | ||
be sent upstream but bugfixes may also be prudent to PR against Sapphire Core so that they can be integrated | ||
be sent upstream but bugfixes may also be prudent to PR against Dash Diamond Core so that they can be integrated | ||
quickly. Cosmetic changes should be purely taken upstream. | ||
|
||
There is a tool in `test/lint/git-subtree-check.sh` to check a subtree directory for consistency with | ||
|
@@ -693,7 +693,7 @@ you must be aware of. | |
|
||
In most configurations we use the default LevelDB value for `max_open_files`, | ||
which is 1000 at the time of this writing. If LevelDB actually uses this many | ||
file descriptors it will cause problems with Sapphire's `select()` loop, because | ||
file descriptors it will cause problems with DashDiamond's `select()` loop, because | ||
it may cause new sockets to be created where the fd value is >= 1024. For this | ||
reason, on 64-bit Unix systems we rely on an internal LevelDB optimization that | ||
uses `mmap()` + `close()` to open table files without actually retaining | ||
|
@@ -704,7 +704,7 @@ In addition to reviewing the upstream changes in `env_posix.cc`, you can use `ls | |
check this. For example, on Linux this command will show open `.ldb` file counts: | ||
|
||
```bash | ||
$ lsof -p $(pidof Sapphired) |\ | ||
$ lsof -p $(pidof dashdiamondd) |\ | ||
awk 'BEGIN { fd=0; mem=0; } /ldb$/ { if ($4 == "mem") mem++; else fd++ } END { printf "mem = %s, fd = %s\n", mem, fd}' | ||
mem = 119, fd = 0 | ||
``` | ||
|
@@ -801,7 +801,7 @@ Git and GitHub tips | |
|
||
[remote "upstream-pull"] | ||
fetch = +refs/pull/*:refs/remotes/upstream-pull/* | ||
url = [email protected]:sappcoin-com/SAPP.git | ||
url = [email protected]:Dash-Diamond/DASHD.git | ||
|
||
This will add an `upstream-pull` remote to your git repository, which can be fetched using `git fetch --all` | ||
or `git fetch upstream-pull`. Afterwards, you can use `upstream-pull/NUMBER/head` in arguments to `git show`, | ||
|
@@ -862,7 +862,7 @@ A few guidelines for introducing and reviewing new RPC interfaces: | |
- Try not to overload methods on argument type. E.g. don't make `getblock(true)` and `getblock("hash")` | ||
do different things. | ||
|
||
- *Rationale*: This is impossible to use with `sapphire-cli`, and can be surprising to users. | ||
- *Rationale*: This is impossible to use with `dashdiamond-cli`, and can be surprising to users. | ||
|
||
- *Exception*: Some RPC calls can take both an `int` and `bool`, most notably when a bool was switched | ||
to a multi-value, or due to other historical reasons. **Always** have false map to 0 and | ||
|
@@ -881,7 +881,7 @@ A few guidelines for introducing and reviewing new RPC interfaces: | |
|
||
- Add every non-string RPC argument `(method, idx, name)` to the table `vRPCConvertParams` in `rpc/client.cpp`. | ||
|
||
- *Rationale*: `sapphire-cli` and the GUI debug console use this table to determine how to | ||
- *Rationale*: `dashdiamond-cli` and the GUI debug console use this table to determine how to | ||
convert a plaintext command line to JSON. If the types don't match, the method can be unusable | ||
from there. | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.