crossbell-box / crossbell-contracts Goto Github PK
View Code? Open in Web Editor NEWCrossbell Contracts: The protocol for an ownership platform.
Home Page: https://crossbell-box.github.io/Crossbell-Contracts
Crossbell Contracts: The protocol for an ownership platform.
Home Page: https://crossbell-box.github.io/Crossbell-Contracts
This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.
These updates are currently rate-limited. Click on a checkbox below to force their creation now.
These updates have all been created already. Click a checkbox below to force a retry/rebase of any.
These are blocked by an existing closed PR and will not be recreated unless you click a checkbox below.
.github/workflows/checks.yml
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
codespell-project/actions-codespell v2.0
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
foundry-rs/foundry-toolchain v1
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
crytic/slither-action v0.3.0
github/codeql-action v2
.github/workflows/docs.yml
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
foundry-rs/foundry-toolchain v1
actions/configure-pages v3
peaceiris/actions-gh-pages v3
.github/workflows/lint.yml
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
.github/workflows/mythx.yml
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
actions/setup-python v4
.github/workflows/tests.yml
actions/checkout v4@b4ffde65f46336ab88eb53be808477a3936bae11
actions/setup-node v3
foundry-rs/foundry-toolchain v1
codecov/codecov-action v3
package.json
@nomiclabs/hardhat-ethers ^2.0.6
@nomiclabs/hardhat-etherscan ^3.1.0
@nomiclabs/hardhat-waffle ^2.0.3
@openzeppelin/contracts 4.9.0
@typechain/ethers-v5 ^7.0.1
@typechain/hardhat ^7.0.0
@types/mocha ^10.0.0
chai ^4.3.6
dotenv ^16.0.0
ethereum-waffle ^3.4.4
ethers ^5.6.9
hardhat ^2.12.7
hardhat-contract-sizer ^2.8.0
hardhat-gas-reporter ^1.0.9
husky ^8.0.3
lint-staged ^14.0.0
prettier ^3.0.0-alpha.5
prettier-plugin-solidity ^1.1.3
solhint ^3.4.0
ts-node ^10.9.1
typechain ^5.1.2
typescript ^5.0.0
solidity 0.8.18 introduced named parameters in mapping types. I would make sense to implement this new feature to increase the code readability.
here is an example:
mapping(uint256 characterId => mapping(address operator => uint256 permissionsBitMap)) internal _operatorsPermissionBitMap; // slot 25
Right now, linkNote
can be served to link notes for different purposes by assigning different linkTypes
, but it's quite limited, cuz the linkType
is bytes32 and can only be used to store a small amount of information. Imagine a scenario when you liked a bunch of posts on Xlog but you want to tag them with different bookmarks and organize them into different lists, the linkTypes
alone won't be enough.
We got 2 options to improve this:
linkNoteWithUri
method in Web3Entry.sol. /**
* @notice linkNoteWithUri creates a link between a character and a note, and at the same
time attaches a uri to the link.
* @param vars The linkNoteData struct containing the following parameters:
* * fromCharacterId: The character id of the linker.
* * toCharacterId: The character id of the note owner.
* * toNoteId: The note id of the note to link.
* * linkType: The link type to use, for example, `LikeLinkType`.
* * data: The data input for link module, if any.
* @param uri The uri attached to the link, which can contain anything depending on how
you want to use it.
*/
function linkNoteWithUri(struct DataTypes.linkNoteData vars, string uri) external {}
This uri can be anything, we can put the tags we want in it.
link
and `linkTag'.{
"fromCharacterId": ,
"toCharacterId": ,
"toNoteId": ,
"linkType": "tag: bc's reading list",
"data":
}
In order to make some differences with the emitted events so that indexer can easily tell if this is a normal link
or a linkTag
, Web3Entry would process the input data and when the linkType
starts with "tag: "
the linklistId
in the emitted LinkNote
event would be 0(normally the linklistId
should be linker's linklist ID).
What do you think, Which one is better? ๐ค
It seems that the burn function of linklist contract doesn't work properly.
request:
curl 'https://rpc.crossbell.io' \
-X POST \
-H "Content-Type: application/json" \
--data '{"method":"eth_call","params":[{"from":"0x9308Add42293f9d3AbbC6A83045707C5dD128428","to":"0xFc8C75bD5c26F50798758f387B698f207a016b6A","data":"0x42966c680000000000000000000000000000000000000000000000000000000000001ceb"}, "latest"],"id":1,"jsonrpc":"2.0"}'
response:
{"jsonrpc":"2.0","id":1,"error":{"code":3,"message":"execution reverted: ERC721: operator query for nonexistent token","data":"0x08c379a00000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000002c4552433732313a206f70657261746f7220717565727920666f72206e6f6e6578697374656e7420746f6b656e0000000000000000000000000000000000000000"}}
Given that a linklist nft is a character bound token, it stores both the linking and linkType of specific character. Hence, it's advisable to support burning the linklist via the web3Entry contract( burnLinklist
) and then remove the associated linking and linkType
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.