Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
7c4b282
chore: use common version across all packages
Nov 28, 2025
3ece6e9
Add SLSA generic generator workflow
SanadAlrowaili Feb 17, 2026
efba005
Add TestTrader contract for token swapping
SanadAlrowaili Feb 17, 2026
45cb2e0
Add initial CodeQL workflow configuration
SanadAlrowaili Feb 18, 2026
7733138
Merge pull request #1 from SanadAlrowaili/fix/deps
SanadAlrowaili Feb 19, 2026
e8452ae
Create FUNDING.json
SanadAlrowaili Feb 25, 2026
a9202a0
Revert "chore: use common version across all packages"
SanadAlrowaili Feb 26, 2026
d33862e
Update swap-vm.spec.ts
SanadAlrowaili Feb 26, 2026
d43eff2
Merge pull request #2 from SanadAlrowaili/revert-1-fix/deps
SanadAlrowaili Feb 26, 2026
b0a7619
Update address-half.test.ts
SanadAlrowaili Feb 26, 2026
5ae7438
Merge pull request #4 from SanadAlrowaili/SanadAlrowaili-patch-1
SanadAlrowaili Feb 28, 2026
c63085b
Set up Vercel Web Analytics integration (#5)
vercel[bot] Feb 28, 2026
929a92a
Set up Vercel Web Analytics integration (#6)
SanadAlrowaili Mar 1, 2026
457fb3e
Update release.yml (#7)
SanadAlrowaili Mar 1, 2026
468ad51
Potential fix for code scanning alert no. 2: Workflow does not contai…
SanadAlrowaili Mar 13, 2026
f4802e2
Merge branch '1inch:master' into master
SanadAlrowaili Apr 18, 2026
edc0262
Create SECURITY.md
SanadAlrowaili Apr 18, 2026
c3e305c
Create SECURITY.md for security policy (#11)
SanadAlrowaili Apr 21, 2026
e829102
chore(deps): bump the npm_and_yarn group across 1 directory with 3 up…
dependabot[bot] Apr 26, 2026
4ac840c
Update FUNDING.json
SanadAlrowaili Jul 31, 2026
24519e6
fix(security): patch dependency vulnerabilities via pnpm overrides
SanadAlrowaili Aug 2, 2026
9c5ef56
fix(sdk-core): repair broken AddressHalf test
SanadAlrowaili Aug 2, 2026
020e5bc
test: cover the largest untested modules
SanadAlrowaili Aug 3, 2026
b307448
test: enforce coverage thresholds and align the sdk-core config
SanadAlrowaili Aug 3, 2026
aab12bc
ci: report coverage to Codecov
SanadAlrowaili Aug 3, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 43 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
version: 2

updates:
# npm / pnpm workspace (root manifest covers the whole monorepo)
- package-ecosystem: npm
directory: /
schedule:
interval: weekly
open-pull-requests-limit: 10
groups:
# Security patches land on their own so they can be merged fast.
npm-security:
applies-to: security-updates
patterns:
- '*'
# Routine bumps are batched to keep PR noise down.
npm-dev-minor-patch:
applies-to: version-updates
dependency-type: development
update-types:
- minor
- patch
npm-prod-minor-patch:
applies-to: version-updates
dependency-type: production
update-types:
- minor
- patch

- package-ecosystem: github-actions
directory: /
schedule:
interval: weekly
groups:
actions:
patterns:
- '*'

# Foundry dependencies are vendored as git submodules (see .gitmodules).
- package-ecosystem: gitsubmodule
directory: /
schedule:
interval: weekly
101 changes: 101 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,101 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL Advanced"

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
schedule:
- cron: '15 21 * * 5'

jobs:
analyze:
name: Analyze (${{ matrix.language }})
# Runner size impacts CodeQL analysis time. To learn more, please see:
# - https://gh.io/recommended-hardware-resources-for-running-codeql
# - https://gh.io/supported-runners-and-hardware-resources
# - https://gh.io/using-larger-runners (GitHub.com only)
# Consider using larger runners or machines with greater resources for possible analysis time improvements.
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
permissions:
# required for all workflows
security-events: write

# required to fetch internal or private CodeQL packs
packages: read

# only required for workflows in private repositories
actions: read
contents: read

strategy:
fail-fast: false
matrix:
include:
- language: actions
build-mode: none
- language: javascript-typescript
build-mode: none
# CodeQL supports the following values keywords for 'language': 'actions', 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'rust', 'swift'
# Use `c-cpp` to analyze code written in C, C++ or both
# Use 'java-kotlin' to analyze code written in Java, Kotlin or both
# Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
# To learn more about changing the languages that are analyzed or customizing the build mode for your analysis,
# see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning.
# If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
steps:
- name: Checkout repository
uses: actions/checkout@v4

# Add any setup steps before running the `github/codeql-action/init` action.
# This includes steps like installing compilers or runtimes (`actions/setup-node`
# or others). This is typically only required for manual builds.
# - name: Setup runtime (example)
# uses: actions/setup-example@v1

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v4
with:
languages: ${{ matrix.language }}
build-mode: ${{ matrix.build-mode }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.

# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
# queries: security-extended,security-and-quality

# If the analyze step fails for one of the languages you are analyzing with
# "We were unable to automatically build your code", modify the matrix above
# to set the build mode to "manual" for that language. Then modify this step
# to build your code.
# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
- name: Run manual build steps
if: matrix.build-mode == 'manual'
shell: bash
run: |
echo 'If you are using a "manual" build mode for one or more of the' \
'languages you are analyzing, replace this with the commands to build' \
'your code, for example:'
echo ' make bootstrap'
echo ' make release'
exit 1

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v4
with:
category: "/language:${{matrix.language}}"
68 changes: 68 additions & 0 deletions .github/workflows/generator-generic-ossf-slsa3-publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,68 @@
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.

# This workflow lets you generate SLSA provenance file for your project.
# The generation satisfies level 3 for the provenance requirements - see https://slsa.dev/spec/v0.1/requirements
# The project is an initiative of the OpenSSF (openssf.org) and is developed at
# https://github.com/slsa-framework/slsa-github-generator.
# The provenance file can be verified using https://github.com/slsa-framework/slsa-verifier.
# For more information about SLSA and how it improves the supply-chain, visit slsa.dev.

name: SLSA generic generator
on:
workflow_dispatch:
release:
types: [created]

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
outputs:
digests: ${{ steps.hash.outputs.digests }}

steps:
- uses: actions/checkout@v4

# ========================================================
#
# Step 1: Build your artifacts.
#
# ========================================================
- name: Build artifacts
run: |
# These are some amazing artifacts.
echo "artifact1" > artifact1
echo "artifact2" > artifact2

# ========================================================
#
# Step 2: Add a step to generate the provenance subjects
# as shown below. Update the sha256 sum arguments
# to include all binaries that you generate
# provenance for.
#
# ========================================================
- name: Generate subject for provenance
id: hash
run: |
set -euo pipefail

# List the artifacts the provenance will refer to.
files=$(ls artifact*)
# Generate the subjects (base64 encoded).
echo "hashes=$(sha256sum $files | base64 -w0)" >> "${GITHUB_OUTPUT}"

provenance:
needs: [build]
permissions:
actions: read # To read the workflow path.
id-token: write # To sign the provenance.
contents: write # To add assets to a release.
uses: slsa-framework/slsa-github-generator/.github/workflows/generator_generic_slsa3.yml@v1.4.0

Check failure on line 65 in .github/workflows/generator-generic-ossf-slsa3-publish.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=1inch_sdks&issues=AZ_FXZxj-CkDYWnc7VX8&open=AZ_FXZxj-CkDYWnc7VX8&pullRequest=88
with:
base64-subjects: "${{ needs.build.outputs.digests }}"
upload-assets: true # Optional: Upload to a new release
38 changes: 38 additions & 0 deletions .github/workflows/pr-check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,41 @@

- name: Test affected packages
run: pnpm affected:test --base=origin/${{ github.base_ref }}

# Each package writes lcov with paths relative to its own root (SF:src/...),
# so all three reports look identical to Codecov. They are uploaded
# separately, with `root_dir` pointing at the owning package so the paths
# resolve, and a flag each so the very different baselines
# (aqua ~99%, swap-vm ~92%, sdk-core ~45%) are tracked apart.
#
# `affected:test` only runs the projects a PR touches, so a given report
# may legitimately be missing. Uploads are best-effort and never fail CI.
- name: Upload sdk-core coverage
uses: codecov/codecov-action@v5

Check failure on line 54 in .github/workflows/pr-check.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=1inch_sdks&issues=AZ_FeYwL-CkDYWnc8SXX&open=AZ_FeYwL-CkDYWnc8SXX&pullRequest=88
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage/typescript/shared/lcov.info
root_dir: ${{ github.workspace }}/typescript/sdk-core
flags: sdk-core
fail_ci_if_error: false
continue-on-error: true

- name: Upload aqua coverage
uses: codecov/codecov-action@v5

Check failure on line 64 in .github/workflows/pr-check.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=1inch_sdks&issues=AZ_FeYwL-CkDYWnc8SXY&open=AZ_FeYwL-CkDYWnc8SXY&pullRequest=88
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage/typescript/aqua/lcov.info
root_dir: ${{ github.workspace }}/typescript/aqua
flags: aqua
fail_ci_if_error: false
continue-on-error: true

- name: Upload swap-vm coverage
uses: codecov/codecov-action@v5

Check failure on line 74 in .github/workflows/pr-check.yml

View check run for this annotation

SonarQubeCloud / SonarCloud Code Analysis

Use full commit SHA hash for this dependency.

See more on https://sonarcloud.io/project/issues?id=1inch_sdks&issues=AZ_FeYwL-CkDYWnc8SXZ&open=AZ_FeYwL-CkDYWnc8SXZ&pullRequest=88
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ./coverage/typescript/swap-vm/lcov.info
root_dir: ${{ github.workspace }}/typescript/swap-vm
flags: swap-vm
fail_ci_if_error: false
continue-on-error: true
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release typescript
name: Release typescript/${{ inputs.project }} with ${{ inputs.bump }} version

on:
workflow_dispatch:
Expand Down
7 changes: 7 additions & 0 deletions FUNDING.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"drips": {
"ethereum": {
"ownedBy": "0xef0dd916f754087d1D4f520F6Da132169424320c"
}
}
}
21 changes: 21 additions & 0 deletions SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Security Policy

## Supported Versions

Use this section to tell people about which versions of your project are
currently being supported with security updates.

| Version | Supported |
| ------- | ------------------ |
| 5.1.x | :white_check_mark: |
| 5.0.x | :x: |
| 4.0.x | :white_check_mark: |
| < 4.0 | :x: |

## Reporting a Vulnerability

Use this section to tell people how to report a vulnerability.

Tell them where to go, how often they can expect to get an update on a
reported vulnerability, what to expect if the vulnerability is accepted or
declined, etc.
45 changes: 45 additions & 0 deletions codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# https://docs.codecov.com/docs/codecovyml-reference

coverage:
status:
project:
default:
# Match the per-package thresholds in the vitest configs: report a drop,
# but allow a little noise so unrelated PRs are not blocked.
target: auto
threshold: 1%
informational: true
patch:
default:
# New and changed lines should be tested, but this stays advisory until
# the team decides to enforce it.
target: 80%
informational: true

# One flag per workspace package, so the three very different baselines
# (aqua ~99%, swap-vm ~92%, sdk-core ~45%) are tracked separately rather than
# being averaged into a single misleading number.
flags:
aqua:
paths:
- typescript/aqua/
sdk-core:
paths:
- typescript/sdk-core/
swap-vm:
paths:
- typescript/swap-vm/

ignore:
- "**/*.test.ts"
- "**/*.spec.ts"
- "**/index.ts"
- "**/*.abi.ts"
- "**/dist/**"
- "contracts/**"
- "scripts/**"

comment:
layout: "reach, diff, flags, files"
behavior: default
require_changes: true
Loading