Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: enable more pocketic features #3895

Merged
merged 24 commits into from
Sep 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
61aff5d
enable more pocketic features
adamspofford-dfinity Aug 28, 2024
0db5add
Merge branch 'master' into spofford/pocketic-features
adamspofford-dfinity Sep 12, 2024
5e247e8
windows clippy
adamspofford-dfinity Sep 12, 2024
8025902
Add log level from replica config
adamspofford-dfinity Sep 12, 2024
4d18e70
Update replica to 99ab7f03700ba6cf832eb18ffd55228f56ae927a
adamspofford-dfinity Sep 12, 2024
1e4e8f6
update replica to 179973553248415fc85679d853b48b0e0ec231c6
adamspofford-dfinity Sep 16, 2024
f138b3f
Merge branch 'master' into spofford/pocketic-features
adamspofford-dfinity Sep 16, 2024
3b76916
Remove --ready-file
adamspofford-dfinity Sep 16, 2024
0f178f5
Fix changelog
adamspofford-dfinity Sep 16, 2024
3ac9c92
sigh
adamspofford-dfinity Sep 16, 2024
ed2b9c9
broken changelog
adamspofford-dfinity Sep 16, 2024
d26aaf3
this was supposed to be removed
adamspofford-dfinity Sep 16, 2024
fb2d06e
blackhole the metrics
adamspofford-dfinity Sep 17, 2024
3e94e68
new default wasm memory limit
adamspofford-dfinity Sep 17, 2024
366bb7a
Update Candid UI
adamspofford-dfinity Sep 17, 2024
9089284
pocket-ic gives 500 on bad url
adamspofford-dfinity Sep 17, 2024
ed2c6fa
update NNS extension in cycles-ledger.bash
adamspofford-dfinity Sep 17, 2024
cd3a171
Update test-uis.py
adamspofford-dfinity Sep 17, 2024
7a0df9b
another one
adamspofford-dfinity Sep 17, 2024
0222f4c
.
adamspofford-dfinity Sep 17, 2024
cf56a3d
.
adamspofford-dfinity Sep 17, 2024
958b8ac
.
adamspofford-dfinity Sep 17, 2024
2ac5ca7
.
adamspofford-dfinity Sep 17, 2024
0b4b884
.
adamspofford-dfinity Sep 17, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,40 @@

# UNRELEASED

### feat: More PocketIC flags supported

`dfx start --pocketic` is now compatible with `--artificial-delay` and the `subnet_type` configuration option, and enables `--enable-canister-http` by default.

## Dependencies

### Replica

Updated replica to elected commit 179973553248415fc85679d853b48b0e0ec231c6.

This incorporates the following elected proposals:

- [132507](https://dashboard.internetcomputer.org/proposal/132507)
- [132482](https://dashboard.internetcomputer.org/proposal/132482)
- [132481](https://dashboard.internetcomputer.org/proposal/132481)
- [132500](https://dashboard.internetcomputer.org/proposal/132500)
- [132416](https://dashboard.internetcomputer.org/proposal/132416)
- [132413](https://dashboard.internetcomputer.org/proposal/132413)
- [132414](https://dashboard.internetcomputer.org/proposal/132414)
- [132412](https://dashboard.internetcomputer.org/proposal/132412)
- [132376](https://dashboard.internetcomputer.org/proposal/132376)
- [132375](https://dashboard.internetcomputer.org/proposal/132375)
- [132223](https://dashboard.internetcomputer.org/proposal/132223)
- [132222](https://dashboard.internetcomputer.org/proposal/132222)
- [132149](https://dashboard.internetcomputer.org/proposal/132149)
- [132148](https://dashboard.internetcomputer.org/proposal/132148)
- [131787](https://dashboard.internetcomputer.org/proposal/131787)
- [131757](https://dashboard.internetcomputer.org/proposal/131757)
- [131697](https://dashboard.internetcomputer.org/proposal/131697)

### Candid UI

Module hash 15da2adc4426b8037c9e716b81cb6a8cf1a835ac37589be2cef8cb3f4a04adaa

# 0.24.0

### fix: bumps sveltekit starter dependency versions to prevent typescript config error
Expand Down
7 changes: 4 additions & 3 deletions Cargo.lock

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

4 changes: 2 additions & 2 deletions e2e/tests-dfx/assetscanister.bash
Original file line number Diff line number Diff line change
Expand Up @@ -718,7 +718,7 @@ check_permission_failure() {

# fails with because %e6 is not valid utf-8 percent encoding
assert_command_fail curl --fail -vv http://localhost:"$PORT"/%e6?canisterId="$ID"
assert_contains "400 Bad Request"
assert_contains "500 Internal Server Error"
}

@test "http_request percent-decodes urls" {
Expand Down Expand Up @@ -788,7 +788,7 @@ check_permission_failure() {

assert_command_fail curl --fail -vv http://localhost:"$PORT"/%e6?canisterId="$ID"
# fails because %e6 is not valid utf-8 percent encoding
assert_contains "400 Bad Request"
assert_contains "500 Internal Server Error"

assert_command curl --fail -vv http://localhost:"$PORT"/%25?canisterId="$ID"
assert_match "200 OK" "$stderr"
Expand Down
13 changes: 13 additions & 0 deletions e2e/tests-dfx/canister_extra.bash
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,17 @@ teardown() {

assert_command_fail dfx canister snapshot create hello_backend
assert_contains 'Canister hello_backend is running and snapshots should not be taken of running canisters'
}

@test "can query a website" {
dfx_start

dfx_new
install_asset canister_http

dfx deploy

assert_command dfx canister call e2e_project_backend get_url '("www.githubstatus.com:443","https://www.githubstatus.com:443")'
assert_contains "Git Operations"
assert_contains "API Requests"
}
Original file line number Diff line number Diff line change
Expand Up @@ -202,16 +202,3 @@ set_shared_local_network_canister_http_empty() {
assert_command dfx start --background --verbose
assert_match "log level: Critical"
}

@test "can query a website" {
dfx_start

dfx_new
install_asset canister_http

dfx deploy

assert_command dfx canister call e2e_project_backend get_url '("www.githubstatus.com:443","https://www.githubstatus.com:443")'
assert_contains "Git Operations"
assert_contains "API Requests"
}
2 changes: 1 addition & 1 deletion e2e/tests-dfx/create.bash
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ teardown() {
assert_contains 'Memory allocation: 0'
assert_contains 'Compute allocation: 0'
assert_contains 'Reserved cycles limit: 5_000_000_000_000'
assert_contains 'Wasm memory limit: 0'
assert_contains 'Wasm memory limit: 3_221_225_472'
assert_contains 'Freezing threshold: 2_592_000'
assert_contains 'Log visibility: controllers'
}
2 changes: 1 addition & 1 deletion e2e/tests-dfx/cycles-ledger.bash
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ teardown() {
start_and_install_nns() {
dfx_start_for_nns_install

dfx extension install nns --version 0.3.1
dfx extension install nns --version 0.4.3
dfx nns install --ledger-accounts "$(dfx ledger account-id --identity cycle-giver)"
}

Expand Down
2 changes: 0 additions & 2 deletions e2e/tests-dfx/shared_local_network.bash
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ teardown() {
}

@test "project data is cleared after dfx start --clean from outside the project" {
[[ "$USE_POCKETIC" ]] && skip "dfx_start does not support parameters with pocketic"
mkdir somewhere
(
cd somewhere
Expand Down Expand Up @@ -94,7 +93,6 @@ teardown() {


@test "wallet config file is reset after start --clean" {
[[ "$USE_POCKETIC" ]] && skip "dfx_start does not support parameters with pocketic"
dfx_start

(
Expand Down
6 changes: 2 additions & 4 deletions e2e/tests-dfx/start.bash
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ teardown() {
}

@test "start and stop with different options" {
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: artificial delay, and clean required"
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: clean required"
dfx_start --artificial-delay 101
dfx_stop

Expand All @@ -32,7 +32,6 @@ teardown() {
}

@test "project networks still need --clean" {
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: artificial delay"
dfx_new hello
define_project_network

Expand All @@ -43,7 +42,7 @@ teardown() {
}

@test "stop and start with other options does not disrupt projects" {
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: artificial delay"
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: clean required"
adamspofford-dfinity marked this conversation as resolved.
Show resolved Hide resolved
dfx_start --artificial-delay 101

dfx_new p1
Expand Down Expand Up @@ -487,7 +486,6 @@ teardown() {
}

@test "flags count as configuration modification and require --clean for a project network" {
[[ "$USE_POCKETIC" ]] && skip "skipped for pocketic: --artificial-delay"
dfx_new
define_project_network

Expand Down
3 changes: 1 addition & 2 deletions e2e/utils/_.bash
Original file line number Diff line number Diff line change
Expand Up @@ -143,9 +143,8 @@ dfx_start() {
add_default_parameter "--host" "127.0.0.1:0"
if [[ "$USE_POCKETIC" ]]; then
add_default_parameter "--pocketic"
else
add_default_parameter "--artificial-delay" "100"
fi
add_default_parameter "--artificial-delay" "100"

determine_network_directory

Expand Down
Loading
Loading