108 Commits

Author SHA1 Message Date
sripwoud
7c7be99154 ci: include lint and typecheck checks (#510) 2024-08-28 12:13:24 +02:00
sripwoud
afcd4cc74a chore: remove contracts (#503)
* chore: delete `contracts`

* ci: remove forge/contracts related steps
2024-08-27 15:47:39 +02:00
sripwoud
66d8f9d0fe ci: fix installed rust toolchain 2024-08-27 14:57:47 +02:00
sripwoud
f41eb10854 ci(release): install correct rust toolchain (#496) 2024-08-23 10:26:10 +02:00
sripwoud
de306d5bbc ci: exclude halo2{wrong-ecdsa,-{ecdsa,eth-membership}} from tests 2024-08-21 09:06:30 +02:00
sripwoud
4ea6f3d0d7 chore: delete deploy GH workflows (#488) 2024-08-19 13:54:30 +02:00
sripwoud
0c9d990588 ci: bump actions versions 2024-08-09 13:23:21 +02:00
sripwoud
82d7c5ef28 ci: remove debug step in coverage job 2024-08-02 15:52:04 +02:00
sripwoud
38cb56d1f5 ci: swallow error if no coverage file found 2024-08-02 15:50:15 +02:00
sripwoud
65bd2cf031 ci: fix discord bot deployment (#461)
* ci: fix discord-bot deploy (#460)

* chore: add target to dockerignore

* refactor discord bot dockerfile

* chore: add url for discord bot environments
2024-07-29 18:08:39 +02:00
sripwoud
2c01b3ec80 chore: use lefthook to manage git hooks (#458)
* chore: hide biome config file

* chore: update dprint and biome config

* chore: replace lintstaged and husky by lefthook

* chore: update knip config

* chore: cleanup config files in `ui`

* fix: use dprint action in format workflow step
2024-07-26 17:59:07 +02:00
sripwoud
4c1d809a90 ci: run test coverage in test-rs job (#455)
* ci: run coverage in test-rs job

* ci: upload to coveralls in separate job

* chore: format

* ci: alway run coverage job

* ci: always run `fmt` job

* ci: always run `deps` job

* test: update err message

* ci: exclude halo2-secp256k1-wasm from tests

taking too long

* ci: allow empty report file for coveralls

* ci: get dynamically list of coverage files

* ci: checkout in coveralls job

* ci: exclude halo2wrong-ecdsa from ci tests check

* chore: debug ci

* ci: update coveralls base path input
2024-07-16 17:44:50 +02:00
sripwoud
0245d64b3d chore: merge staging (#454)
* refactor: use `dprint` for formatting (#446)

* ci: bump actions versions

* chore: bump node version

* chore: format with `dprint`

* chore: exclude contracts/lib from fmt, update lintstaged cmd

* ci: update node/pnpm versions

* ci: update actions versions in test workflow

* refactor GH worfklows (#447)

* ci: update actions versions in test workflow

* refactor gh workflows

* fix: bump Cargo.lock

* ci: optimize test workflow (#448)

* ci: optimize test workflow

* ci: merge test with static-analsysi workflow

* chore: rename workflow file

* ci: fix typo

* ci: fix

* ci: fix

* ci: exclude ui from jts modified files

* fix(ci): add changed-files step id

* ci: fix node & pnpm versions

* ci: fix node action input name

* fix: use checkout action in fmt job

* fix: use checkout action in test-node job

* ci: fix cache-hit check

* ci: use actions/cache/restore

* ci: update node/pnpm cache path

* ci: install rustfmt component

* ci: hoist shamefully deps

easier to manage cache of node_modules that way

* ci: do not use cache of `deps`job for test-node job

* chore: delete forge lib

* forge install: openzeppelin-contracts

v5.0.2

* forge install: forge-std

v1.9.1

* fix(contracts): define remappings

* ci: fix output name
2024-07-15 14:35:51 +02:00
iskander
3813ee2073 feat(halo2): implement ecdsa signature verification (#419) 2024-04-23 18:43:31 +00:00
i
8f519577af Rust Test Coverage (#414)
* feat: adding halo2 axiom scaffold

* feat: starting on ecdsa

* feat: starting on ecdsa

* feat: starting on ecdsa cont.

* feat: adding halo2wrong ecdsa verison circuit wip

* fix: remove testing json set

* test: wriing a failed test for testing ECDSA chip verification

* fix: clippy warnings fixings

* feat: adding CI github actions for test coverage

* feat: adding inatalltion readme

* fix: lint issues

* fix: lint issues

* fix: undo rust change

* fix: resolve requested changes and rebase

* fix: remove repeated halo2-ecdsa crate

* chore: rename some workflow titles
2024-03-18 15:29:58 +01:00
sripwoud
bbc6877919 chore: update deploy environments urls 2024-03-12 23:33:24 +01:00
sripwoud
7ffc1b819f test(cli): add more tests and mock query api requests (#402)
* test(cli): add more tests and mock query api requests

* fix query_ens test

use strum derive to customize how EnsVoteChoice is serialized

* chore:fix: trigger test workflow on changes in rs files

* chore: include cargo tests in repo wide `test` script

* chore: update test workflow trigger paths
2024-03-11 23:34:13 +01:00
sripwoud
81c037b091 changeset 2024-03-06 21:39:11 +01:00
sripwoud
5ed6adf712 fix: add package.json files to path trigger of release workflow 2024-02-13 17:56:59 +01:00
sripwoud
d04e2954c7 chore:fix: trigger release worklfow only on .md files changes in .changeset 2024-02-13 17:37:14 +01:00
sripwoud
346b4c532d fix semantic versioning (#329) (#330) 2024-02-01 12:45:52 +01:00
sripwoud
9c9ad0c47b trigger release workflow on changes in yml definition file 2024-02-01 10:30:54 +01:00
sripwoud
2fcc458254 can trigger release workflow manually 2024-02-01 10:30:20 +01:00
sripwoud
f4eb754529 fix release workflow (#326)
Only install deps of pkgs
2024-02-01 10:29:03 +01:00
sripwoud
cb5432c323 refactor: update build scripts (#323)
* rename compile script to `build`
remove unecessary scripts

* changeset

* fix: make sure wasm pkgs are compiled sequentially
2024-02-01 09:56:06 +01:00
sripwoud
2de1427d70 refactor: rename packages and change monorepo structure (#322)
* rename and move packages to `pkgs` folder

* pin typescript version to 5.1.6

see typescript eslint warning

WARNING: You are currently running a version of TypeScript which is not officially supported by @typescript-eslint/typescript-estree.

You may find that it works just fine, or you may not.
SUPPORTED TYPESCRIPT VERSIONS: >=3.3.1 <5.2.0
YOUR TYPESCRIPT VERSION: 5.2.2

* fix tsconfig extends relative paths

* update readme

* fix jest preset
2024-01-31 22:42:01 +01:00
sripwoud
e347971a0e refactor: delete proving server related code (#316) (#317)
* bump lock file

* delete `/apis/prove`

* move `/apis/query/` into `query-api/`

* remove `/infra`

* update config files

* format

* remove @anonklub/proof ts reference from circom pkg

* tsignore

* pin `@anonklub/proof` package in ui

* remove unused config in hook

* tsignore (discord bot)

* delete apis/prove

* remove tsignore directive

* update env vars

* skip build of `@anonklub/proof` in vlaidate workflow

version was pinned in UI and CLI

* avoid pre rendering for beacon query page

 see https://nextjs.org/docs/app/api-reference/file-conventions/route-segment-config#dynamic

By default, next will try to pre-render and fetch the data at build time
However, this is a dune query that is subject to query credits... sometimes the query fails. It should not prevent building the app though.

* Remove prove api url from ui config
2024-01-30 16:15:28 +01:00
sripwoud
a67a5d1d9d feat: indicate prove command @anonklub/cli as todo (#314)
* fix: install with `--no-frozen-lockfile` in release workflow

* chore: bump pnpm-lock.yaml

* feat: indicate prove command of cli as todo

We are now using client side proving with spartan. There is no proving server

* refactor: fix ts error in `@anonklub/query`

* changeset
2024-01-30 14:37:16 +01:00
sripwoud
1c5855ae70 feat: remove logic related to proving server from ProofRequest (#312) 2024-01-30 13:47:53 +01:00
sripwoud
94513d99d8 Revert "chore: Delete proving server and infra code (#308) (#310)"
This reverts commit 805fb49bb4.
2024-01-30 10:29:24 +01:00
sripwoud
805fb49bb4 chore: Delete proving server and infra code (#308) (#310)
* delete `apis/prove`

* move `apis/query` into `query-api`

* delete `/infra`

* update README

* bump lock file

* clean unused

* lint

* format

* fix typescript errors

* fix: remove `composite: true` from `@anonklub/proof` tsconfig

* fix: remove reference to `@anonklub/proof` in circom pkg tsconfig

* fix: update static-analysis.yml env var for ui build step

* remove references to `NEXT_PUBLIC_PROVE_API`

* lint
2024-01-29 18:06:43 +01:00
sripwoud
46f0ab943e chore: update paths trigger on {release,test}.yml 2024-01-29 12:12:56 +01:00
sripwoud
108feed8ea chore: remove BlakeMsCurr from CODEOWNERS 2024-01-29 08:33:59 +01:00
i
66223099e1 feat: Add Spartan ECDSA Rust circuits (#287)
* feat: implementing a wasm-pack liberary for merkle tree

* fix: package.json main and types relative paths

* fix: remove deprecated rust crate

* faet: implmenting a spartan circuits version that has wasm-pack integrations, and removing halo2 empty project

* fix: spartan circuits cargo dependencies

* fix: remove the built wasm pkg

* fix: pnpm lock file

* fix: package.json workspace and script

* fix: pnpm lock file

* fix: cargo clippy fixes

* chore: better comments

* fix: build wasm package before install with `devPreinstall` hook (#296)

* fix: build wasm package before install with `devPreinstall` hook

* chore: format

* fix: adding a build wasm step in the test workflow

* fix: try to not use compile via turbo in the test workflow

* fix: adding install wasm-pack step

* fix: update build rust creates in static analysis

* chore: lint test workflow

* fix: make sure to ignore @anonklub/spartan-ecdsa

* refactor (#298)

* parallelize wasm compile in preInstall hook

* refactor

* to revert

* refactor: do not use jetli action

Install wasm-pack with script instead

Getting some errors otherwise
https://github.com/anonklub/anonklub/actions/runs/7666559819/job/20894718947#step:10:24

* Revert "to revert"

This reverts commit 9b71b5f228.

* fix: do not parallelize compilation of wasm package

running into temp file lock issues otherwise

---------

Co-authored-by: sripwoud <me@sripwoud.xyz>
2024-01-26 11:36:22 +01:00
sripwoud
eea262042c fix: ignore `@anonklub/merkle-tree when publishing packages (#293)
* fix: ignore ``@anonklub/merkle-tree` when publishing packages

* Change step name
2024-01-24 13:46:12 +01:00
sripwoud
7a4a831cfc fix: build merkle-tree pkg before running static analysis checks in CI (#288)
* fix: build @anonklub/merkle-tree local dep before install step in static analysis workflow

* typo
2024-01-22 17:00:33 +01:00
sripwoud
88b972ca67 :recycle:: use nestjs framework for query api (#251) (#252)
* wip

* scaffold anonset controller and service

* add repositories

* update service

* refactor, add open api specs

* add dockerfile and fly config

* fix tsconfig.json

* update index

* move files

* use prod Dockerfile for deployment

* fix turbo.json

* add ajv as dev dep

* remove nest test

TODO

* format

* lint
2023-11-10 19:42:47 +01:00
sripwoud
c361e95d86 fix(query-api): fix dune queries endpoints
* fix(query-api): fix dune queries endpoints (#241)

* remove cowprotocol dune client

Replace with direct request to dune API with native fetch

* update openapi.yaml

* 🎨 format

* fix build: need to export interface

* fix unit test

* decrease global.branches coverage threshold

* make duneCLient a service

* fix test

* validate

* lint

* 💩 Use dev script in dockerfile for query-api deployment
2023-11-08 23:00:49 +01:00
sweep-ai[bot]
d2d67ee191 Configure Sweep (#236)
* Create sweep.yaml

* Create sweep template

* format

* decrease global.branches coverage threshold

---------

Co-authored-by: sweep-ai[bot] <128439645+sweep-ai[bot]@users.noreply.github.com>
Co-authored-by: sripwoud <me@sripwoud.xyz>
2023-11-08 15:44:57 +01:00
sripwoud
e41565b3e9 do not install infra package dep in Gh actions 2023-10-17 14:13:17 +02:00
sripwoud
451b519a9f [Snyk] Upgrade @pulumi/pulumi from 3.76.0 to 3.76.1 (#231)
* fix: upgrade @pulumi/pulumi from 3.76.0 to 3.76.1

Snyk has created this PR to upgrade @pulumi/pulumi from 3.76.0 to 3.76.1.

See this package in npm:
https://www.npmjs.com/package/@pulumi/pulumi

See this project in Snyk:
https://app.snyk.io/org/sripwoud/project/ae541ec1-35c0-4520-b2a6-d2508587ca91?utm_source=github&utm_medium=referral&page=upgrade-pr

* update lock file

* show error message when installing deps in test GH action

remove reporter silent flag

---------

Co-authored-by: snyk-bot <snyk-bot@snyk.io>
2023-10-17 14:03:24 +02:00
sripwoud
b8d38a9c8e 🔖 Add release workflow (#225)
* Add changeset dep

* downgrade version

* add release worklfow

* add changeset

* Publish

* Remove prepack script

* .prettierignore package json files
2023-08-11 11:31:29 +02:00
sripwoud
00971baca0 👷 Trigger test action on changes in @anonklub/*json 2023-08-11 11:11:06 +02:00
sripwoud
d5f4cd8080 :twisted_rightward_arrows: Merge staging (#224)
* Update test workflow

* 📦 Build `@anonklub/*` to commonjs (#223)

* Build @anonklub/query to commonJS

* Build @anonklub/proof to ES2022

* format

* refactor: do not use `baseUrl` to build @anonklub/query

It is tricky to use a lib that defines module aliases

* refactor: do not use `baseUrl` to build @anonklub/proof

It is tricky to use a lib that defines module aliases

* Build @anonklub/cli to ES2022

* format, lint

* fix: do not build as ESM

* add comment

* Update package.json files

* fix folder name and import path

* Fix path to coverageDirectory in jest preset

* name test workflow

* trigger ?

* rename workflow

* use jest projects

Necessary to have 1 root coverage folder that coveralls needs
2023-08-11 10:14:01 +02:00
sripwoud
b8e6269bba Add workflow dispatch trigger for test GH action 2023-08-11 07:53:40 +02:00
sripwoud
166ed6d84c 👷 Update test GH action workflow 2023-08-11 07:52:46 +02:00
sripwoud
fe5b7888e7 👷 Add reopened trigger for add-to-project.yml 2023-08-09 13:18:58 +02:00
sripwoud
114ba41c28 🔀 Merge staging
* ♻️ Define `@anonklub/{cli,proof,query,test}` (#30)

* rename 3pwd to sripwoud

* move `membership` and `demo` to `@anonklub`. Rename `@anonset` to `@anonklub`

* Create `@anonklub/query`

* Define functions to fetch anon sets from query API

* test fetchCryptoPunksAnonset

* refactor: use generic for query functions

* define test-utils pkg

* refactor, format

* test: fetch{Erc20,Eth}AnonSet

* move @anonklub/test-utils into root/test

* extends from root tsconfig.json

* fix glob in turbo.json

* move fetch type def into root global.d.ts

* fix tsc errors

* edit eslint and barrelsby config

* bump test deps

* use jest preset defined in shared local test package

* relax tsconfig

Allow for uncheckedIndexedAccess

* refactor query methods into OOP

* test

* format

* fix lint config

Need to exclude root tsconfig.json to avoid cricular deps as we extend from it

* chore: lint

* chore: lint, format

* fix: increase memory allocation when running eslint

* add tsconfig references

* refactor jest config files into using custom anonklub preset (#31)

* fix Dockerfile

Need to copy root global.d.ts and tsconfig.json and test package
2023-08-09 12:44:24 +02:00
sripwoud
5c6aa52b04 Rename workflow 2023-08-09 12:44:22 +02:00
sripwoud
691fb64ad8 🚀 Deploy discord bot
* 🚀 Deploy Discord Bot

* Define Dockerfile for discord-bot

* Add fly.toml config files

* Define GH workflow to deploy discord bot to staging

* fix: copy package.json to discord-bot Dockerfile

*  fix: add reflect-metadata dep

*  fix: add tslib dep

* fix NODE_PATH

* define internal port in fly config

* feat(discord-bot): Add health probe endpoint (#24)

* feat(discord-bot): Add healthprobe endpoint

* format

* 🚀 Deploy discord bot to prod

* shorten import, format
2023-08-09 12:44:18 +02:00