Skip to content

Commit c241c9f

Browse files
committed
Merge branch '20250109-final-todo' into 20250127-tla-plus-model
2 parents 83dcdae + 532b45a commit c241c9f

Some content is hidden

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

83 files changed

+27307
-11
lines changed

.github/workflows/build-test.yml

+17-7
Original file line numberDiff line numberDiff line change
@@ -31,14 +31,13 @@ jobs:
3131
with:
3232
fetch-depth: 0
3333

34-
- uses: actions/setup-python@v4
35-
name: Install Python ${{ matrix.python }}
34+
- uses: actions/setup-python@v5
35+
name: Install Python 3.9
3636
with:
37-
python-version: ${{ matrix.python }}
37+
python-version: 3.9
3838

39-
- name: Update pip
40-
run: |
41-
python -m pip install --upgrade pip
39+
- uses: chia-network/actions/create-venv@main
40+
id: create-venv
4241

4342
- name: Set up rust
4443
uses: actions-rs/toolchain@v1
@@ -86,13 +85,24 @@ jobs:
8685
- uses: actions/checkout@v3
8786
with:
8887
fetch-depth: 1
88+
8989
- name: Install rust
9090
uses: actions-rs/toolchain@v1
9191
with:
9292
toolchain: stable
9393
components: rustfmt, clippy
94+
95+
- uses: actions/setup-python@v5
96+
name: Install Python 3.9
97+
with:
98+
python-version: 3.9
99+
100+
- uses: chia-network/actions/create-venv@main
101+
id: create-venv
102+
94103
- name: cargo test
95104
run: |
105+
python -m pip install setuptools==75.0.0
96106
python -m pip install chia-blockchain==2.3.0
97107
# Try tests without sim-tests to ensure we're tracking build failures in that
98108
# configuration. Also it's a lot shorter.
@@ -117,7 +127,7 @@ jobs:
117127
export CARGO_TARGET_DIR=$(pwd)/target
118128
python -m venv venv
119129
source venv/bin/activate
120-
pip install chia-blockchain
130+
pip install chia-blockchain==2.3.0
121131
cargo test --release --workspace --features=sim-tests
122132
grcov . --binary-path target -s . --branch --ignore-not-existing --ignore='*/.cargo/*' --ignore='*/tests/*' -o rust_cov.info
123133
python -c 'with open("rust_cov.info") as f: lines = [l for l in f if not (l.startswith("DA:") and int(l.split(",")[1].strip()) >= 2**63)]; open("lcov.info", "w").writelines(lines)'

.github/workflows/wasm-test.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@ jobs:
3636
toolchain: stable
3737
components: rustfmt, clippy
3838

39-
- name: Setup Node 16.x
39+
- name: Setup Node 18.x
4040
uses: actions/setup-node@v3
4141
with:
42-
node-version: '16.x'
42+
node-version: '18.x'
4343

4444
- name: install wasm-pack
4545
run: cargo install --version 0.11.1 wasm-pack

resources/gaming-fe/.gitignore

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
2+
3+
# dependencies
4+
/node_modules
5+
/.pnp
6+
.pnp.js
7+
8+
# testing
9+
/coverage
10+
11+
# production
12+
/build
13+
14+
# misc
15+
.DS_Store
16+
.env.local
17+
.env.development.local
18+
.env.test.local
19+
.env.production.local
20+
21+
npm-debug.log*
22+
yarn-debug.log*
23+
yarn-error.log*

resources/gaming-fe/README.md

+40
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Cal Poker Game
2+
3+
## **Introduction**
4+
5+
Cal Poker is a simple real-time poker game where two players can connect, place wagers, and play turns against each other. The game uses Socket.IO for real-time communication between clients and the server.
6+
7+
## **Features**
8+
9+
- Real-time multiplayer gameplay
10+
- Simple betting system
11+
- Turn-based actions
12+
- Interactive UI with Material-UI components
13+
- Modular and maintainable codebase
14+
15+
## **Prerequisites**
16+
17+
- **Node.js**
18+
- **npm**
19+
- **TypeScript**
20+
21+
## **Setup**
22+
23+
1. **Install dependencies for the client:**
24+
```npm install```
25+
26+
2. **Starting the Server:**
27+
```node server.js```
28+
29+
3. **Start the React application:**
30+
```npm start```
31+
32+
The client will start on port 3000 by default and should open automatically in your default browser.
33+
34+
## **Usage**
35+
Open two browser windows or tabs:
36+
37+
Go to http://localhost:3000 in both.
38+
Enter a wager amount and find an opponent:
39+
40+
In both windows, enter a wager amount (e.g., 50) and click "Find an opponent".

resources/gaming-fe/jest.config.js

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
module.exports = {
2+
preset: "ts-jest",
3+
testEnvironment: "jsdom",
4+
moduleNameMapper: {
5+
"^socket.io-client$": "<rootDir>/__mocks__/socket.io-client.ts",
6+
},
7+
};

0 commit comments

Comments
 (0)