Skip to content

Commit f7595c0

Browse files
committed
chore(apps/hermes): switch to stable rust
1 parent ad04400 commit f7595c0

File tree

11 files changed

+21
-26
lines changed

11 files changed

+21
-26
lines changed

.github/workflows/ci-hermes-server.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ jobs:
1414
- uses: actions-rs/toolchain@v1
1515
with:
1616
profile: minimal
17-
toolchain: nightly-2024-03-26
17+
toolchain: 1.82.0
1818
components: rustfmt, clippy
1919
override: true
2020
- name: Install protoc

.github/workflows/ci-pre-commit.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,11 @@ jobs:
3737
profile: minimal
3838
toolchain: nightly-2024-08-04
3939
components: rustfmt, clippy
40+
- uses: actions-rs/toolchain@v1
41+
with:
42+
profile: minimal
43+
toolchain: 1.82.0
44+
components: rustfmt, clippy
4045
- name: Install protoc
4146
uses: arduino/setup-protoc@v3
4247
- uses: actions/checkout@v4

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ repos:
5656
- id: cargo-clippy-hermes
5757
name: Cargo clippy for Hermes
5858
language: "rust"
59-
entry: cargo +nightly-2024-03-26 clippy --manifest-path ./apps/hermes/server/Cargo.toml --tests --fix --allow-dirty --allow-staged -- -D warnings
59+
entry: cargo +1.82.0 clippy --manifest-path ./apps/hermes/server/Cargo.toml --tests --fix --allow-dirty --allow-staged -- -D warnings
6060
pass_filenames: false
6161
files: apps/hermes
6262
# Hooks for Fortuna

apps/hermes/server/Cargo.lock

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apps/hermes/server/Dockerfile

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,9 @@
1-
# The rust version itself is not so important as we install a fixed
2-
# nightly version. We use the latest stable version to get the latest
3-
# updates and dependencies.
4-
FROM rust:1.77.0 AS build
1+
FROM rust:1.82.0 AS build
52

63
# Install OS packages
74
RUN apt-get update && apt-get install --yes \
85
build-essential curl clang libssl-dev protobuf-compiler
96

10-
# Set default toolchain
11-
RUN rustup default nightly-2024-03-26
12-
137
# Build
148
WORKDIR /src
159
COPY apps/hermes/server apps/hermes/server
@@ -20,7 +14,7 @@ WORKDIR /src/apps/hermes/server
2014

2115
RUN --mount=type=cache,target=/root/.cargo/registry cargo build --release
2216

23-
FROM rust:1.77.0
17+
FROM rust:1.82.0
2418

2519
# Copy artifacts from other images
2620
COPY --from=build /src/apps/hermes/server/target/release/hermes /usr/local/bin/

apps/hermes/server/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,11 @@ To set up and run a Hermes node, follow the steps below:
1919
[here](https://docs.pyth.network/documentation/pythnet-price-feeds/hermes#hermes-node-providers) and instructions
2020
for running a Wormhole spy RPC instance [here](https://docs.wormhole.com/wormhole/explore-wormhole/spy). We recommend
2121
using [Beacon](https://github.com/pyth-network/beacon), a highly available rewrite for spy, for production purposes.
22-
1. **Install Rust nightly-2023-07-23**: If you haven't already, you'll need to install Rust. You can
22+
1. **Install Rust 1.82.0**: If you haven't already, you'll need to install Rust. You can
2323
do so by following the official instructions. Then, run the following command to install the required
24-
nightly version of Rust:
24+
version of Rust:
2525
```bash
26-
rustup toolchain install nightly-2023-07-23
26+
rustup toolchain install 1.82.0
2727
```
2828
2. **Install Go**: If you haven't already, you'll also need to install Go. You can
2929
do so by following the official instructions. If you are on a Mac with M series

apps/hermes/server/rust-toolchain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
[toolchain]
2-
channel = "nightly-2024-03-26"
2+
channel = "1.82.0"

apps/hermes/server/src/main.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
#![feature(never_type)]
2-
#![feature(btree_cursors)]
3-
41
use {
52
anyhow::Result,
63
clap::{

apps/hermes/server/src/network/pythnet.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ async fn fetch_bridge_data(
141141
}
142142
}
143143

144-
pub async fn run<S>(store: Arc<S>, pythnet_ws_endpoint: String) -> Result<!>
144+
pub async fn run<S>(store: Arc<S>, pythnet_ws_endpoint: String) -> Result<()>
145145
where
146146
S: Aggregates,
147147
S: Wormhole,

apps/hermes/server/src/network/wormhole.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ where
140140
}
141141

142142
#[tracing::instrument(skip(opts, state))]
143-
async fn run<S>(opts: RunOptions, state: Arc<S>) -> Result<!>
143+
async fn run<S>(opts: RunOptions, state: Arc<S>) -> Result<()>
144144
where
145145
S: Wormhole,
146146
S: Send + Sync + 'static,

0 commit comments

Comments
 (0)