Skip to content

Commit 1500302

Browse files
authored
chore: create windows setup guide hiero-ledger#1570 (hiero-ledger#1579)
Signed-off-by: Akshat Kumar <akshat230405@gmail.com>
1 parent f606f6b commit 1500302

File tree

8 files changed

+102
-4
lines changed

8 files changed

+102
-4
lines changed

.github/ISSUE_TEMPLATE/01_good_first_issue_candidate.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -269,7 +269,7 @@ body:
269269
270270
- [ ] **Connect** origin with upstream: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/03_staying_in_sync.md)
271271
272-
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md)
272+
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md) (or [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/setup_windows.md) for Windows users)
273273
274274
- [ ] **Sync Main** pull any recent upstream changes: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/rebasing.md)
275275

.github/ISSUE_TEMPLATE/02_good_first_issue.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,7 +253,7 @@ body:
253253
254254
- [ ] **Connect** origin with upstream: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/03_staying_in_sync.md)
255255
256-
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md)
256+
- [ ] **Install Packages** and protobufs: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/02_installing_hiero_python_sdk.md) (or [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/setup_windows.md) for Windows users)
257257
258258
- [ ] **Sync Main** pull any recent upstream changes: [Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/rebasing.md)
259259

.github/ISSUE_TEMPLATE/03_beginner_issue.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ body:
176176
description: Provide a contribution workflow suitable for new contributors
177177
value: |
178178
- [ ] **Assignment:** You must be assigned to the issue, comment: `/assign` in the issue to get assigned [see guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/04_assigning_issues.md)
179-
- [ ] **Fork, Branch and Work on the issue:** Create a copy of the repository, create a branch for the issue and solve the problem. For instructions, please read our [Contributing guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/CONTRIBUTING.md) file. Further help can be found at [Set-up Training](https://github.com/hiero-ledger/hiero-sdk-python/tree/main/docs/sdk_developers/training/setup) and [Workflow Training](https://github.com/hiero-ledger/hiero-sdk-python/tree/main/docs/sdk_developers/training/workflow).
179+
- [ ] **Fork, Branch and Work on the issue:** Create a copy of the repository, create a branch for the issue and solve the problem. For instructions, please read our [Contributing guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/CONTRIBUTING.md) file. Further help can be found at [Set-up Training](https://github.com/hiero-ledger/hiero-sdk-python/tree/main/docs/sdk_developers/training/setup) (including the [Windows Setup Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/setup/setup_windows.md) for Windows users) and [Workflow Training](https://github.com/hiero-ledger/hiero-sdk-python/tree/main/docs/sdk_developers/training/workflow).
180180
- [ ] **DCO and GPG key sign each commit :** each commit must be -s and -S signed. An explanation on how to do this is at [Signing Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/signing.md)
181181
- [ ] **Add a Changelog Entry :** your pull request will require a changelog. Read [Changelog Entry Guide](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/changelog_entry.md) to learn how.
182182
- [ ] **Push and Create a Pull Request :** Once your issue is resolved, and your commits are signed, and you have a changelog entry, push your changes and create a pull request. Detailed instructions can be found at [Submit PR Training](https://github.com/hiero-ledger/hiero-sdk-python/blob/main/docs/sdk_developers/training/workflow/11_submit_pull_request.md), part of [Workflow Training](https://github.com/hiero-ledger/hiero-sdk-python/tree/main/docs/sdk_developers/training/workflow).

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ This changelog is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.
1717
- Format `tests/unit/network_tls_test.py` with black for code style consistency (#1543)
1818

1919
### Added
20+
- Added Windows setup guide for SDK developers (`docs/sdk_developers/training/setup/setup_windows.md`) with PowerShell installation instructions. (#1570)
2021
- Added a beginner assignment guard that requires completion of a Good First Issue. (#1484)
2122
- Added `/unassign` command allowing contributors to remove themselves from assigned issues.(#1472)
2223
- Added advanced CodeRabbit reviewer guidance for `tokens` module changes, with specialized validation rules for token transactions, token classes, and enums. (#1496)

CONTRIBUTING.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ Thank you for your interest in contributing to the Hiero Python SDK!
2424

2525
- [Project Structure](docs/sdk_developers/project_structure.md)
2626
- [Setup](docs/sdk_developers/training/setup)
27+
- [Setup (Windows)](docs/sdk_developers/training/setup/setup_windows.md)
2728
- [Workflow](docs/sdk_developers/training/workflow)
2829

2930
**Quick Start:**

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ print(f"Balance: {balance.hbars} HBAR")
6363

6464
- **[Contributing Guide](CONTRIBUTING.md)** - Start here!
6565
- **[Setup Guide](docs/sdk_developers/setup.md)** - First-time environment setup
66+
- **[Windows Setup Guide](docs/sdk_developers/training/setup/setup_windows.md)** - Step-by-step guide for Windows users
6667
- **[Workflow Guide](docs/sdk_developers/workflow.md)** - Day-to-day development workflow
6768
- **[Signing Guide](docs/sdk_developers/signing.md)** - GPG and DCO commit signing (required)
6869
- **[Changelog Guide](docs/sdk_developers/changelog_entry.md)** - How to write changelog entries

docs/sdk_developers/setup.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ brew install uv
108108

109109
**On Windows:**
110110
```powershell
111-
powershell -c "irm https://astral.sh/uv/install.ps1 | iex"
111+
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
112112
```
113113

114114
**Other installation methods:** [uv Installation Guide](https://docs.astral.sh/uv/getting-started/installation/)
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
# Windows Setup Guide
2+
3+
This guide provides a step-by-step walkthrough for setting up the Hiero Python SDK development environment specifically for Windows users. We will use PowerShell and `uv` for dependency management.
4+
5+
---
6+
7+
## Table of Contents
8+
- [Prerequisites](#prerequisites)
9+
- [Fork and Clone](#fork-and-clone)
10+
- [Install uv](#install-uv)
11+
- [Install Dependencies](#install-dependencies)
12+
- [Generate Protobufs](#generate-protobufs)
13+
- [Troubleshooting](#troubleshooting)
14+
15+
---
16+
17+
## Prerequisites
18+
19+
Before you begin, ensure you have the following installed on your system:
20+
21+
1. **Git for Windows**: [Download and install Git](https://gitforwindows.org/).
22+
2. **Python 3.10+**: [Download and install Python](https://www.python.org/downloads/windows/). Ensure "Add Python to PATH" is checked during installation.
23+
3. **GitHub Account**: You will need a GitHub account to fork the repository.
24+
25+
---
26+
27+
## Fork and Clone
28+
29+
1. Navigate to the [hiero-sdk-python repository](https://github.com/hiero-ledger/hiero-sdk-python) and click the **Fork** button.
30+
2. Open **PowerShell** and run the following commands to clone your fork:
31+
32+
```powershell
33+
# Clone the repository
34+
git clone https://github.com/<your-username>/hiero-sdk-python.git
35+
36+
# Navigate into the project directory
37+
cd hiero-sdk-python
38+
```
39+
---
40+
41+
## Install uv
42+
43+
The Hiero Python SDK uses `uv` for extremely fast Python package and environment management.
44+
45+
1. In your PowerShell window, run the following command to install `uv`:
46+
47+
```powershell
48+
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
49+
```
50+
51+
> ⚠️ **Important**: After the installation finishes, you **must** close your current PowerShell window and open a new one for the changes to take effect. Alternatively, you can reload your environment variables.
52+
53+
2. Verify the installation by running:
54+
```powershell
55+
uv --version
56+
```
57+
58+
---
59+
60+
## Install Dependencies
61+
62+
Once `uv` is installed and you are inside the project directory, run:
63+
64+
```powershell
65+
uv sync
66+
```
67+
68+
This command will create a virtual environment and install all necessary development dependencies automatically.
69+
70+
---
71+
72+
## Generate Protobufs
73+
74+
The SDK requires generated protobuf files to communicate with the network. Run the following command to generate them:
75+
76+
```powershell
77+
uv run python generate_proto.py
78+
```
79+
80+
---
81+
82+
## Troubleshooting
83+
84+
### `uv` is not recognized
85+
If you receive an error stating that `uv` is not recognized as a cmdlet or function, ensure that the installation path (typically `%USERPROFILE%\.local\bin`) is added to your Windows Environment Variables (PATH).
86+
87+
### Execution Policy Restrictions
88+
If you encounter errors running scripts in PowerShell, you may need to adjust your execution policy. Run PowerShell as an Administrator and execute:
89+
```powershell
90+
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
91+
```
92+
93+
### Git Bash Alternative
94+
While this guide focuses on PowerShell, you can also use **Git Bash**. If using Git Bash, follow the [Standard Setup Guide](02_installing_hiero_python_sdk.md) as it behaves similarly to a Unix shell.
95+

0 commit comments

Comments
 (0)