Skip to content

Commit

Permalink
Fix default ped path for generate_data
Browse files Browse the repository at this point in the history
  • Loading branch information
illusional committed Aug 23, 2023
1 parent 55f7326 commit 52a69e2
Showing 1 changed file with 7 additions and 14 deletions.
21 changes: 7 additions & 14 deletions test/data/generate_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,20 @@
import asyncio
import datetime
import random
from pathlib import Path
from pprint import pprint

from metamist.apis import (
ProjectApi,
ParticipantApi,
FamilyApi,
SampleApi,
AnalysisApi,
)
from metamist.apis import AnalysisApi, FamilyApi, ParticipantApi, ProjectApi, SampleApi
from metamist.graphql import gql, query_async
from metamist.model.analysis import Analysis
from metamist.model.analysis_status import AnalysisStatus
from metamist.models import (
SampleUpsert,
AssayUpsert,
SequencingGroupUpsert,
)
from metamist.models import AssayUpsert, SampleUpsert, SequencingGroupUpsert
from metamist.parser.generic_parser import chunk

EMOJIS = [':)', ':(', ':/', ':\'(']

default_ped_location = str(Path(__file__).parent / 'greek-myth-forgeneration.ped')

QUERY_SG_ID = gql(
"""
query MyQuery($project: String!) {
Expand All @@ -51,7 +44,7 @@
)


async def main(ped_path='greek-myth-forgeneration.ped', project='greek-myth'):
async def main(ped_path=default_ped_location, project='greek-myth'):
"""Doing the generation for you"""

papi = ProjectApi()
Expand Down Expand Up @@ -234,7 +227,7 @@ def generate_random_number_within_distribution():
parser.add_argument(
'--ped-path',
type=str,
default='greek-myth-forgeneration.ped',
default=default_ped_location,
help='Path to the pedigree file',
)
parser.add_argument('--project', type=str, default='greek-myth')
Expand Down

0 comments on commit 52a69e2

Please sign in to comment.