From e16bfc4947bbffb0c238a2de49b34e9e3527575d Mon Sep 17 00:00:00 2001 From: ali Date: Wed, 18 Dec 2024 02:09:04 +0330 Subject: [PATCH 1/3] add matching funds field to the project table --- src/entities/project.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/entities/project.ts b/src/entities/project.ts index eb685dc7b..b146fa228 100644 --- a/src/entities/project.ts +++ b/src/entities/project.ts @@ -468,6 +468,10 @@ export class Project extends BaseEntity { @Column('integer', { array: true, default: [] }) batchNumbersWithSafeTransactions?: number[]; + @Field(_type => Int, { nullable: true }) + @Column({ type: 'int', nullable: true }) + matchingFunds?: number; + // only projects with status active can be listed automatically static pendingReviewSince(maximumDaysForListing: number) { const maxDaysForListing = moment() From 14872f4fff2d9c038a58d35ae7109de15a7b583f Mon Sep 17 00:00:00 2001 From: ali Date: Wed, 18 Dec 2024 02:09:18 +0330 Subject: [PATCH 2/3] add migration for adding matching funds field to the project table --- ...75040262-addMatchingFundsToProjectTable.ts | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 migration/1734475040262-addMatchingFundsToProjectTable.ts diff --git a/migration/1734475040262-addMatchingFundsToProjectTable.ts b/migration/1734475040262-addMatchingFundsToProjectTable.ts new file mode 100644 index 000000000..fc27e9b4f --- /dev/null +++ b/migration/1734475040262-addMatchingFundsToProjectTable.ts @@ -0,0 +1,19 @@ +import { MigrationInterface, QueryRunner } from 'typeorm'; + +export class AddMatchingFundsToProjectTable1734475040262 + implements MigrationInterface +{ + name = 'AddMatchingFundsToProjectTable1734475040262'; + + public async up(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `ALTER TABLE "project" ADD "matchingFunds" integer`, + ); + } + + public async down(queryRunner: QueryRunner): Promise { + await queryRunner.query( + `ALTER TABLE "project" DROP COLUMN "matchingFunds"`, + ); + } +} From 27f162e3f0d53af5b501fee5d58892ce91767f46 Mon Sep 17 00:00:00 2001 From: ali Date: Wed, 18 Dec 2024 02:09:59 +0330 Subject: [PATCH 3/3] complete funding pot configs based on the new changes --- src/scripts/runFundingPotService.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/scripts/runFundingPotService.ts b/src/scripts/runFundingPotService.ts index 64296c62c..80c2e098c 100644 --- a/src/scripts/runFundingPotService.ts +++ b/src/scripts/runFundingPotService.ts @@ -59,7 +59,11 @@ async function generateBatchFile(batchNumber: number, dryRun: boolean) { ? round.cumulativeUSDCapPerUserPerProject : round.roundUSDCapPerUserPerProject) || '5000' ).toString(), // Default to 5000 for individual cap - INDIVIDUAL_2: isEarlyAccess ? '0' : '250', // Only required for QACC rounds + INDIVIDUAL_2: isEarlyAccess + ? '0' + : ( + round.roundUSDCapPerUserPerProjectWithGitcoinScoreOnly || '1000' + ).toString(), // Only required for QACC rounds if for users with GP score only TOTAL: ( (isEarlyAccess ? round.cumulativeUSDCapPerProject @@ -122,6 +126,7 @@ async function fillProjectsData() { SAFE: project.abc.projectAddress || '', ORCHESTRATOR: project.abc.orchestratorAddress || '', NFT: project.abc.nftContractAddress || '', + MATCHING_FUNDS: project.matchingFunds || '', }; } else { console.warn( @@ -175,7 +180,7 @@ async function createEnvFile() { 'ANKR_NETWORK_ID=polygon_zkevm', ) .replace( - 'RPC_URL="https://rpc.ankr.com/base_sepolia"', + 'RPC_URL="https://sepolia.base.org"', 'RPC_URL="https://zkevm-rpc.com"', ) .replace('CHAIN_ID=84532', 'CHAIN_ID=1101')