When in docker, running the sns-testing repo, I get this:
Do I need to add this?
@jamesbeadle I’m looking into this as well as other sns-testing related issues, I’ll let you know when there’s an update
@jamesbeadle I wasn’t able to reproduce this issue. However I just updated sns-testing to fix another of other issues, and it’s possible that this was downstream of one of those. Could you try pulling main and trying the instructions again? (including ./install.sh
as the version of DFX used has changed)
I believe what’s happening here is you’re running dfx deploy --network=local
, trying to deploy your OpenFPL canister, from inside the sns-testing
container. The result is that it’s trying to deploy the test canister and it’s failing because you haven’t run ./setup-locally.sh
.
The easiest way to get out of this is to just do the sns-testing stuff outside the docker container. This will allow you to use your existing development environment to deploy your dapp canister. I haven’t tested these steps, but they should be approximately correct.
Step 1 (get sns testing):
git clone https://github.com/dfinity/sns-testing.git # clone sns-testing
cd sns-testing
bash install.sh
Step 3 (in a new terminal in the sns-testing directory)
DX_NET_JSON="${HOME}/.config/dfx/networks.json"
mkdir -p "$(dirname "${DX_NET_JSON}")"
cp "$DX_NET_JSON" "${DX_NET_JSON}.tmp" 2>/dev/null # save original config if present
echo '{
"local": {
"bind": "0.0.0.0:8080",
"type": "ephemeral",
"replica": {
"subnet_type": "system",
"port": 8000
}
}
}' > "${DX_NET_JSON}"
./bin/dfx start --clean; \
mv "${DX_NET_JSON}.tmp" "$DX_NET_JSON" 2>/dev/null # restore original config if it was present
You may have to write this to a file in the sns-testing directory and then run the file
Step 5: In the other terminal, set the icp-xdr rate
./set-icp-xdr-rate.sh 10000
Step 4: Deploy your canisters and make a note of the canister IDs
Step 5: Edit the sns_init.yaml
file in sns-testing to your liking, and make sure your canister IDs are listed under dapp_canisters
Step 6: Deploy the SNS and participate
./let_nns_control_dapp.sh
./propose_sns.sh
NUM_PARTICIPANTS=100
ICP_PER_PARTICIPANT=10000
./participate_sns_swap.sh $NUM_PARTICIPANTS $ICP_PER_PARTICIPANT
Step 7: Check http://qsgjb-riaaa-aaaaa-aaaga-cai.localhost:8080/ and see your project
If you make SNS proposals, you can get the neurons that participated to vote on them with this command:
./vote_on_sns_proposal.sh \
61 `# Simulate this number of SNS users' votes. TODO: determine the smallest possible value that will work here` \
2 `# Proposal ID` \
y `# Vote to adopt this proposal`
You may also need to install yq
and bc
Hi Andre,
Many thanks for your time earlier this evening.
The command for installing yq and bc were:
The steps outlined above successful deployed OpenFPL in it’s post sns state.
Thanks,
James