Skip to content

Commit bc59dc5

Browse files
authored
bump solar to have try-catch spans (#10832)
1 parent 3bde150 commit bc59dc5

File tree

354 files changed

+15147
-7118
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

354 files changed

+15147
-7118
lines changed

.config/nextest.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
chisel-serial = { max-threads = 1 }
33

44
[profile.default]
5-
retries = { backoff = "exponential", count = 2, delay = "3s", jitter = true }
5+
retries = { backoff = "exponential", count = 2, delay = "5s", jitter = true }
66
slow-timeout = { period = "1m", terminate-after = 3 }
77

88
[[profile.default.overrides]]

.devcontainer/Dockerfile.dev

Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
FROM ubuntu:22.04
2+
3+
ARG USERNAME=foundry
4+
ARG USER_UID=1000
5+
ARG USER_GID=$USER_UID
6+
ARG PYTHON_VERSION=3.11
7+
ARG NODE_MAJOR=20
8+
ARG VYPER_VERSION=0.4.0
9+
10+
ENV DEBIAN_FRONTEND=noninteractive
11+
ENV CARGO_TERM_COLOR=always \
12+
RUST_BACKTRACE=full
13+
14+
WORKDIR /workspace
15+
16+
RUN apt-get update && apt-get install -y --no-install-recommends \
17+
# Build tools
18+
build-essential \
19+
clang \
20+
lld \
21+
pkg-config \
22+
# Network/SSL
23+
curl \
24+
ca-certificates \
25+
gnupg \
26+
libssl-dev \
27+
# Version control & utils
28+
git \
29+
sudo \
30+
unzip \
31+
# Python
32+
python${PYTHON_VERSION} \
33+
python3-pip \
34+
python${PYTHON_VERSION}-venv \
35+
# Add Node.js repo
36+
&& mkdir -p /etc/apt/keyrings \
37+
&& curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg \
38+
&& echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_${NODE_MAJOR}.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \
39+
# Update again after adding repo and install Node.js
40+
&& apt-get update && apt-get install -y --no-install-recommends \
41+
nodejs \
42+
# Clean up apt cache
43+
&& apt-get clean && rm -rf /var/lib/apt/lists/*
44+
45+
# Ensure python points to the installed python version
46+
RUN ln -sf /usr/bin/python${PYTHON_VERSION} /usr/bin/python && \
47+
ln -sf /usr/bin/python${PYTHON_VERSION} /usr/bin/python3
48+
49+
# Create non-root user with sudo privileges
50+
RUN groupadd --gid $USER_GID $USERNAME \
51+
&& useradd --uid $USER_UID --gid $USER_GID -m $USERNAME -s /bin/bash \
52+
# Setup sudo without password prompt
53+
&& echo "$USERNAME ALL=(ALL) NOPASSWD:ALL" > /etc/sudoers.d/$USERNAME \
54+
&& chmod 0440 /etc/sudoers.d/$USERNAME \
55+
# Add user to the sudo group (standard practice)
56+
&& usermod -aG sudo $USERNAME
57+
58+
# Switch to the non-root user
59+
USER $USERNAME
60+
WORKDIR /home/$USERNAME
61+
62+
# --- User-specific installations ---
63+
64+
# Install Bun
65+
ENV BUN_INSTALL="/home/$USERNAME/.bun"
66+
ENV PATH="$BUN_INSTALL/bin:$PATH"
67+
RUN curl -fsSL https://bun.sh/install | bash
68+
69+
# Install Rust & cargo-nextest
70+
ENV CARGO_HOME="/home/$USERNAME/.cargo"
71+
ENV RUSTUP_HOME="/home/$USERNAME/.rustup"
72+
ENV PATH="$CARGO_HOME/bin:$PATH"
73+
RUN curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y \
74+
&& cargo install cargo-nextest --locked
75+
76+
# Install Vyper using pip
77+
# Ensure pip user install directory is in PATH
78+
ENV PYTHONUSERBASE="/home/$USERNAME/.local"
79+
ENV PATH="$PYTHONUSERBASE/bin:$PATH"
80+
RUN pip3 install --user vyper==${VYPER_VERSION}
81+
82+
# Switch back to the main workspace directory
83+
WORKDIR /workspace
84+

.devcontainer/devcontainer.json

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
// For format details, see https://aka.ms/devcontainer.json.
2+
{
3+
"name": "Foundry Development",
4+
"build": {
5+
"context": "..",
6+
"dockerfile": "Dockerfile.dev"
7+
},
8+
9+
"features": {
10+
"ghcr.io/devcontainers/features/common-utils:2": {
11+
"installZsh": true,
12+
"configureZshAsDefaultShell": true,
13+
"installOhMyZsh": true,
14+
"upgradePackages": true
15+
}
16+
},
17+
18+
"forwardPorts": [],
19+
20+
"postCreateCommand": "rustup default stable && rustup update",
21+
22+
"customizations": {
23+
"vscode": {
24+
"extensions": [
25+
"rust-lang.rust-analyzer",
26+
"serayuzgur.crates",
27+
"tamasfe.even-better-toml",
28+
"ms-python.python",
29+
"dbaeumer.vscode-eslint",
30+
"oven.bun-vscode"
31+
],
32+
"settings": {
33+
"rust-analyzer.checkOnSave": true,
34+
"rust-analyzer.cargo.features": "all"
35+
}
36+
}
37+
},
38+
39+
"remoteUser": "foundry",
40+
41+
"workspaceMount": "source=${localWorkspaceFolder},target=/workspace,type=bind,consistency=cached",
42+
43+
"workspaceFolder": "/workspace",
44+
45+
"mounts": [
46+
"source=${localEnv:HOME}/.cargo/registry,target=/home/foundry/.cargo/registry,type=bind,consistency=cached",
47+
"source=${localEnv:HOME}/.cargo/git,target=/home/foundry/.cargo/git,type=bind,consistency=cached"
48+
]
49+
}

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,4 @@ testdata/cheats/Vm.sol linguist-generated
33

44
# See <https://git-scm.com/docs/gitattributes#_defining_a_custom_hunk_header>
55
*.rs diff=rust
6+
crates/lint/testdata/* text eol=lf

.github/workflows/nextest.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,9 @@ jobs:
5454
- uses: dtolnay/rust-toolchain@stable
5555
with:
5656
target: ${{ matrix.target }}
57-
- uses: taiki-e/install-action@nextest
57+
- uses: taiki-e/install-action@v2
58+
with:
59+
5860

5961
# External tests dependencies
6062
- name: Setup Node.js
@@ -72,6 +74,7 @@ jobs:
7274
with:
7375
python-version: 3.11
7476
- name: Install Vyper
77+
# Also update vyper version in .devcontainer/Dockerfile.dev
7578
run: pip --version && pip install vyper==0.4.0
7679

7780
- name: Forge RPC cache

.github/workflows/nix.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
name: nix
2+
3+
on:
4+
schedule:
5+
# Run weekly
6+
- cron: "0 0 * * SUN"
7+
workflow_dispatch:
8+
# Needed so we can run it manually
9+
10+
concurrency:
11+
group: ${{ github.workflow }}-${{ github.ref }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
# Opens a PR with an updated flake.lock file
16+
update:
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: DeterminateSystems/determinate-nix-action@v3
20+
- uses: actions/checkout@v4
21+
- uses: DeterminateSystems/update-flake-lock@main
22+
with:
23+
pr-title: "Update flake.lock"
24+
pr-labels: |
25+
L-ignore
26+
A-dependencies
27+
28+
build:
29+
strategy:
30+
matrix:
31+
runs-on: [ubuntu-latest, macos-latest]
32+
runs-on: ${{ matrix.runs-on }}
33+
steps:
34+
- uses: DeterminateSystems/determinate-nix-action@v3
35+
- uses: actions/checkout@v4
36+
37+
- name: Update flake.lock
38+
run: nix flake update
39+
40+
- name: Activate nix env
41+
run: nix develop -c echo Ok
42+
43+
- name: Check that we can compile all crates
44+
run: nix develop -c cargo check --all-targets

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ env:
1515
CARGO_TERM_COLOR: always
1616
IS_NIGHTLY: ${{ github.event_name == 'schedule' || github.event_name == 'workflow_dispatch' }}
1717
PROFILE: maxperf
18-
STABLE_VERSION: "v1.0.0"
18+
STABLE_VERSION: "v1.1.0"
1919

2020
jobs:
2121
prepare:
@@ -231,7 +231,7 @@ jobs:
231231
232232
# Creates the release for this specific version
233233
- name: Create release
234-
uses: softprops/action-gh-release@v2
234+
uses: softprops/action-gh-release@v2.2.2
235235
with:
236236
name: ${{ needs.prepare.outputs.release_name }}
237237
tag_name: ${{ needs.prepare.outputs.tag_name }}
@@ -254,7 +254,7 @@ jobs:
254254
# tagged `nightly` for compatibility with `foundryup`
255255
- name: Update nightly release
256256
if: ${{ env.IS_NIGHTLY == 'true' }}
257-
uses: softprops/action-gh-release@v2
257+
uses: softprops/action-gh-release@v2.2.2
258258
with:
259259
name: "Nightly"
260260
tag_name: "nightly"

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ jobs:
109109
- uses: Swatinem/rust-cache@v2
110110
with:
111111
cache-on-failure: true
112-
- run: cargo hack check --each-feature --exclude-features isolate-by-default
112+
- run: cargo hack check
113113

114114
deny:
115115
uses: ithacaxyz/ci/.github/workflows/deny.yml@main

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,5 @@ snapshots/
66
out.json
77
.idea
88
.vscode
9+
.claude
10+
CLAUDE.md

CHANGELOG.md

Lines changed: 0 additions & 37 deletions
This file was deleted.

0 commit comments

Comments
 (0)