Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PFT-1796] Add changes for the snx subgraph code and order #75

Merged
merged 23 commits into from
Oct 15, 2024

Conversation

Akhilleshgoswami
Copy link
Member

No description provided.

Copy link

src/common/subgraphMapper.ts Outdated Show resolved Hide resolved
src/common/subgraphMapper.ts Show resolved Hide resolved
src/interfaces/sdkTypes.ts Show resolved Hide resolved
src/interfaces/sdkTypes.ts Show resolved Hide resolved
@@ -73,67 +24,18 @@ export const fetchAllMarketsDataQuery = gql`
export const fetchMarketByIdQuery = (marketId: string) => gql`
{
market(id: "${marketId.toLowerCase()}") {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have we tested this? The market id in the latest snx subgraph is a number (even though IDs are stored as strings). Please check the subgraph.yaml and the returned data.
Also update the test cases

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Akhilleshgoswami Not sure if anything was changed here. Could you please explain?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so I have only written test case for the order, positions, and account as we were using the market from the synthetix parifi SDK , I didn't change the code here

src/interfaces/subgraphTypes.ts Outdated Show resolved Hide resolved
test/common/constants.ts Outdated Show resolved Hide resolved
test/subgraph-tests/accounts.test.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@sudeepb02 sudeepb02 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@iamamitkumar0512 @Akhilleshgoswami Please work on the requested changes

package.json Outdated Show resolved Hide resolved
src/common/subgraphMapper.ts Show resolved Hide resolved
src/common/subgraphMapper.ts Outdated Show resolved Hide resolved
src/common/subgraphMapper.ts Show resolved Hide resolved
src/common/subgraphMapper.ts Outdated Show resolved Hide resolved
@@ -190,3 +193,21 @@ export const fetchPositionIdsForOrderIds = (orderIds: string[]) => gql`
}
}
`;

export const fectchCollateralForOrderUsingAccountId = (accountId: string | string[]) => gql`
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo

test/pyth-tests/pyth.test.ts Outdated Show resolved Hide resolved
test/relayers/pimlico.test.ts Show resolved Hide resolved
@@ -1,61 +1,12 @@
import { getParifiSdkInstanceForTesting } from '..';
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Account => Wallet
SnxAccount is a different term. Please do not mix them up

test/subgraph-tests/index.test.ts Outdated Show resolved Hide resolved
@iamamitkumar0512 iamamitkumar0512 self-assigned this Oct 15, 2024
@iamamitkumar0512 iamamitkumar0512 merged commit 0162fb4 into develop Oct 15, 2024
1 check failed
@iamamitkumar0512 iamamitkumar0512 deleted the snx-subgraph-code branch October 15, 2024 10:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants