Watch
1
0
Fork
You've already forked ton
0
mirror of https://github.com/ton-blockchain/ton synced 2026-09-20 00:01:07 +00:00
No description
  • C++ 90.6%
  • Python 5.8%
  • CMake 1.7%
  • Teal 0.6%
  • Shell 0.4%
  • Other 0.7%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Tolya 3d478cbde8
TON 2026.08
TON 2026.08
2026-08-17 14:45:47 +03:00
.claude/rules Local benchmark (#2489) 2026-08-03 13:40:28 +03:00
.github remove android tonlib, windows mingw64 and ucrt64 builds 2026-08-15 13:02:09 +03:00
adnl Improve adnl packet size calculation 2026-08-17 13:56:59 +03:00
assembly handle missing pkgconfiglite 2026-08-13 11:58:23 +03:00
benchmark Formatting 2026-08-06 17:13:24 +03:00
blockchain-explorer Various changes and bugfixes 2026-05-29 15:43:20 +03:00
CMake win build with clang-cl, clang-22 (#2346) 2026-05-07 16:51:21 +03:00
common Various changes in node 2026-08-03 13:40:28 +03:00
create-hardfork Simplex-related refactorings (#2450) 2026-06-23 23:03:30 +03:00
crypto Formatting 2026-08-06 17:13:24 +03:00
dht Various changes in node 2026-08-03 13:40:28 +03:00
dht-server Simplify collator configuration in validator-engine 2026-08-05 14:15:44 +03:00
doc Various changes in node 2026-08-03 13:40:28 +03:00
docker follow up Docker image improvements (#2405) 2026-05-30 17:47:48 +03:00
emulator Add #pragma once to header files and enforce via CI (#2289) 2026-04-13 16:56:38 +03:00
example OpenSSL 3.5 (#2098) 2026-01-30 09:46:08 +03:00
fec Better broadcast deduplication and filtering 2026-03-27 12:34:00 -04:00
http http: guard payload callbacks and shared flags against the writer thread 2026-08-03 13:40:28 +03:00
keyring Various improvements in node 2026-07-15 13:29:42 +03:00
keys Various improvements in node 2026-07-15 13:29:42 +03:00
lite-client Various changes and bugfixes 2026-05-29 15:43:20 +03:00
lite-client-docs Update links to global configs (#398) 2022-08-15 18:29:02 +03:00
memprof Reformat entire codebase (except Tolk) with clang-format 21 2025-11-06 09:28:08 -05:00
metrics metrics: tighten observability accounting 2026-08-11 18:43:59 +01:00
overlay Allow configuring intermediate nodes for twostep broadcasts 2026-08-12 15:35:00 +03:00
quic quic: maximize udp socket buffers 2026-08-11 15:45:53 +01:00
rldp-http-proxy Various improvements in node 2026-07-15 13:29:42 +03:00
rldp2 simplify metrics code per style review 2026-08-03 13:40:28 +03:00
storage Various improvements in node 2026-07-15 13:29:42 +03:00
tdactor Fix CE 2026-08-14 21:09:57 +03:00
tddb metrics: instrument durable storage operations 2026-08-11 15:45:56 +01:00
tdfec Fix warning 2026-05-14 10:26:11 +03:00
tdnet metrics: count actual UDP syscalls 2026-08-03 13:40:28 +03:00
tdtl Send fullnode queries in fast-sync and custom overlays (#2442) 2026-07-08 22:35:48 +03:00
tdutils handle missing pkgconfiglite 2026-08-13 11:58:23 +03:00
terminal Do not make stdin non-blocking when running lite-client -c "cmd" (#2443) 2026-06-23 18:36:19 +03:00
test test: fully initialize chain metrics snapshot 2026-08-11 20:17:14 +01:00
third-party Bump ngtcp2 to patched version (#2292) 2026-04-06 21:07:57 +03:00
tl Separate "collators" and "register collators" in config 2026-08-12 15:35:00 +03:00
tl-utils Various changes and bugfixes 2026-05-29 15:43:20 +03:00
tolk [Tolk] Bump version to v1.4.2 2026-06-18 13:37:33 +03:00
tolk-tester [Tolk] Rename ton to grams where it means "currency" 2026-06-18 13:37:33 +03:00
ton Remove unneeded GeneratedCandidate 2026-08-05 14:15:44 +03:00
tonlib Remove unused collation manager stats query 2026-08-05 14:15:44 +03:00
utils Fix inconsistent treating # as (un)singned in TL-B and other fixes (#2191) 2026-03-09 16:12:23 +03:00
validator Fix timeouts and cancelling in BlockProducerImpl::prepare_delegation 2026-08-14 20:10:21 +03:00
validator-engine Check collator adnl id in validator-engine.cpp 2026-08-05 14:15:44 +03:00
validator-engine-console drop early return in ShowCollatorsListQuery::receive 2026-08-13 23:29:41 +02:00
.clang-format Ask clang-format to insert new line at EOF and use west const (#1955) 2025-12-15 18:42:21 +03:00
.clang_complete Various changes in TVM, github builds and tests (#793) 2023-11-03 14:43:34 +03:00
.editorconfig Add Editorconfig (#800) 2024-01-16 09:59:47 +03:00
.gdbinit Add reverse-continue-to-actor-caller GDB command (#1924) 2025-12-01 18:36:43 +03:00
.git-blame-ignore-revs chore: add .git-blame-ignore-revs file (#2182) 2026-03-03 09:20:02 +03:00
.gitattributes Add custom Git merge driver to merge over formatting changes 2025-11-06 13:05:41 -05:00
.gitignore move zlib and microhttpd into submodules (#2114) 2026-02-11 11:51:44 +03:00
.gitmodules move zlib and microhttpd into submodules (#2114) 2026-02-11 11:51:44 +03:00
.lldbinit [Tolk] LLDB pretty printers 2025-11-10 14:08:29 +03:00
.python-version Merge pull request #2277 from DanShaders/python3.14 2026-04-13 16:54:55 +03:00
Changelog.md Update changelog 2026-08-17 13:57:43 +03:00
CMakeLists.txt handle missing pkgconfiglite 2026-08-13 11:58:23 +03:00
Dockerfile follow up Docker image improvements (#2405) 2026-05-30 17:47:48 +03:00
git.cc.in Automatically integrates git build information into executables. 2021-02-27 14:34:43 +03:00
git.h Reformat entire codebase (except Tolk) with clang-format 21 2025-11-06 09:28:08 -05:00
git_watcher.cmake Add a CMake option to disable git watcher (#1579) 2025-03-27 15:22:33 +03:00
GPLv2 updated tonlib 2020-02-06 21:56:46 +04:00
LGPLv2 updated liteserver 2020-02-02 16:53:37 +04:00
LICENSE.LGPL Remove spaces at EOL (#1989) 2025-12-31 12:04:36 +03:00
lldb_addons.py [Tolk] Refactor IR Ops from a linked list to linear no-recurse iteration 2026-03-26 11:32:49 +03:00
pyproject.toml Merge pull request #2277 from DanShaders/python3.14 2026-04-13 16:54:55 +03:00
README.md Fix: Broken TON logo in README (#2309) 2026-04-25 12:37:39 +03:00
recent_changelog.md Update changelog 2026-08-17 13:57:43 +03:00
run-clang-format.sh initial commit 2019-09-07 14:33:36 +04:00
test-quic-interop.sh Improve QUIC SNI identity handling 2026-05-28 20:27:40 +01:00
uv.lock Local benchmark (#2489) 2026-08-03 13:40:28 +03:00

TON logo

Reference implementation of TON Node and tools


Ton Research Telegram Community Group Telegram Foundation Group Telegram Community Chat

Twitter Group TON Overflow Group Stack Overflow Group

Main TON monorepo, which includes the code of the node/validator, lite-client, tonlib, FunC compiler, etc.

The Open Network

The Open Network (TON) is a fast, secure, scalable blockchain focused on handling millions of transactions per second (TPS) with the goal of reaching hundreds of millions of blockchain users.

Updates flow

  • master branch - mainnet is running on this stable branch.

    Only emergency updates, urgent updates, or updates that do not affect the main codebase (GitHub workflows / docker images / documentation) are committed directly to this branch.

  • testnet branch - testnet is running on this branch. The branch contains a set of new updates. After testing, the testnet branch is merged into the master branch and then a new set of updates is added to testnet branch.

  • backlog - other branches that are candidates to getting into the testnet branch in the next iteration.

Usually, the response to your pull request will indicate which section it falls into.

"Soft" Pull Request rules

  • Thou shall not merge your own PRs, at least one person should review the PR and merge it (4-eyes rule)
  • Thou shall make sure that workflows are cleanly completed for your PR before considering merge

Build TON blockchain

Ubuntu 22.04, 24.04 (x86-64, aarch64)

Install additional system libraries

  sudo apt-get update
  sudo apt-get install -y build-essential git cmake ninja-build

  wget https://apt.llvm.org/llvm.sh
  chmod +x llvm.sh
  sudo ./llvm.sh 21 clang

Compile TON binaries

  cp assembly/native/build-ubuntu-shared.sh .
  chmod +x build-ubuntu-shared.sh
  ./build-ubuntu-shared.sh

MacOS 11, 12 (x86-64, aarch64)

  cp assembly/native/build-macos-shared.sh .
  chmod +x build-macos-shared.sh
  ./build-macos-shared.sh

Windows 10, 11, Server (x86-64)

You need to install MS Visual Studio 2022 first. Go to https://www.visualstudio.com/downloads/ and download MS Visual Studio 2022 Community.

Launch installer and select Desktop development with C++. After installation, also make sure that cmake is globally available by adding C:\Program Files\Microsoft Visual Studio\2022\Community\Common7\IDE\CommonExtensions\Microsoft\CMake\CMake\bin to the system PATH (adjust the path per your needs).

Open an elevated (Run as Administrator) x86-64 Native Tools Command Prompt for VS 2022, go to the root folder, and execute:

  copy assembly\native\build-windows-2022.bat .
  build-windows-2022.bat

MSYS2 MinGW64 (x86-64)

Execute from MinGW64 shell

  cp assembly/msys2/build-mingw64.sh .
  chmod +x build-mingw64.sh
  ./build-mingw64.sh -a

As a result, you will get fully statically compiled TON windows binaries.

MSYS2 UCRT64 (x86-64)

Execute from ucrt64 shell

  cp assembly/msys2/build-ucrt64.sh .
  chmod +x build-ucrt64.sh
  ./build-ucrt64.sh -a

As a result, you will get fully statically compiled TON windows binaries.

Building TON to WebAssembly

Install additional system libraries on Ubuntu

  sudo apt-get update
  sudo apt-get install -y build-essential git cmake ninja-build

  wget https://apt.llvm.org/llvm.sh
  chmod +x llvm.sh
  sudo ./llvm.sh 21 clang

Compile TON binaries with emscripten

  cd assembly/wasm
  chmod +x fift-func-wasm-build-ubuntu.sh
  ./fift-func-wasm-build-ubuntu.sh

Building TON tonlib library for Android (arm64-v8a, armeabi-v7a, x86, x86-64)

Install additional system libraries on Ubuntu

  sudo apt-get update
  sudo apt-get install -y build-essential git cmake ninja-build automake libtool texinfo autoconf libgflags-dev \
  libreadline-dev pkg-config libgsl-dev python3 python3-dev libtool autoconf

Compile TON tonlib library

  cp assembly/android/build-android-tonlib.sh .
  chmod +x build-android-tonlib.sh
  ./build-android-tonlib.sh

TON portable binaries

Linux portable binaries are wrapped into AppImages, at the same time MacOS portable binaries are statically linked executables. Linux and MacOS binaries are available for both x86-64 and arm64 architectures.

Running tests

Tests are executed by running ctest in the build directory. See doc/Tests.md for more information.