# -*- coding: utf-8 -*-
import os
import random
import string

from sqlalchemy.dialects import registry

registry.register("awsathena.jdbc", "pyathenajdbc.sqlalchemy_athena", "AthenaDialect")

BASE_PATH = os.path.dirname(os.path.abspath(__file__))
S3_PREFIX = "test_pyathena_jdbc"
WORK_GROUP = "test-pyathena-jdbc"
SCHEMA = "test_pyathena_jdbc_" + "".join(
    [random.choice(string.ascii_lowercase + string.digits) for i in range(10)]
)


class Env(object):
    def __init__(self):
        self.region_name = os.getenv("AWS_DEFAULT_REGION", None)
        assert (
            self.region_name
        ), "Required environment variable `AWS_DEFAULT_REGION` not found."
        self.s3_staging_dir = os.getenv("AWS_ATHENA_S3_STAGING_DIR", None)
        assert (
            self.s3_staging_dir
        ), "Required environment variable `AWS_ATHENA_S3_STAGING_DIR` not found."


ENV = Env()


class WithConnect(object):
    def connect(self, **opts):
        from pyathenajdbc import connect

        return connect(Schema=SCHEMA, **opts)

a0c19e99cb03a5edbd680895eba3a015775c3868
<mask token>


class Env(object):

    def __init__(self):
        self.region_name = os.getenv('AWS_DEFAULT_REGION', None)
        assert self.region_name, 'Required environment variable `AWS_DEFAULT_REGION` not found.'
        self.s3_staging_dir = os.getenv('AWS_ATHENA_S3_STAGING_DIR', None)
        assert self.s3_staging_dir, 'Required environment variable `AWS_ATHENA_S3_STAGING_DIR` not found.'


<mask token>


class WithConnect(object):

    def connect(self, **opts):
        from pyathenajdbc import connect
        return connect(Schema=SCHEMA, **opts)

<mask token>
registry.register('awsathena.jdbc', 'pyathenajdbc.sqlalchemy_athena',
    'AthenaDialect')
<mask token>


class Env(object):

    def __init__(self):
        self.region_name = os.getenv('AWS_DEFAULT_REGION', None)
        assert self.region_name, 'Required environment variable `AWS_DEFAULT_REGION` not found.'
        self.s3_staging_dir = os.getenv('AWS_ATHENA_S3_STAGING_DIR', None)
        assert self.s3_staging_dir, 'Required environment variable `AWS_ATHENA_S3_STAGING_DIR` not found.'


<mask token>


class WithConnect(object):

    def connect(self, **opts):
        from pyathenajdbc import connect
        return connect(Schema=SCHEMA, **opts)

<mask token>
registry.register('awsathena.jdbc', 'pyathenajdbc.sqlalchemy_athena',
    'AthenaDialect')
BASE_PATH = os.path.dirname(os.path.abspath(__file__))
S3_PREFIX = 'test_pyathena_jdbc'
WORK_GROUP = 'test-pyathena-jdbc'
SCHEMA = 'test_pyathena_jdbc_' + ''.join([random.choice(string.
    ascii_lowercase + string.digits) for i in range(10)])


class Env(object):

    def __init__(self):
        self.region_name = os.getenv('AWS_DEFAULT_REGION', None)
        assert self.region_name, 'Required environment variable `AWS_DEFAULT_REGION` not found.'
        self.s3_staging_dir = os.getenv('AWS_ATHENA_S3_STAGING_DIR', None)
        assert self.s3_staging_dir, 'Required environment variable `AWS_ATHENA_S3_STAGING_DIR` not found.'


ENV = Env()


class WithConnect(object):

    def connect(self, **opts):
        from pyathenajdbc import connect
        return connect(Schema=SCHEMA, **opts)

import os
import random
import string
from sqlalchemy.dialects import registry
registry.register('awsathena.jdbc', 'pyathenajdbc.sqlalchemy_athena',
    'AthenaDialect')
BASE_PATH = os.path.dirname(os.path.abspath(__file__))
S3_PREFIX = 'test_pyathena_jdbc'
WORK_GROUP = 'test-pyathena-jdbc'
SCHEMA = 'test_pyathena_jdbc_' + ''.join([random.choice(string.
    ascii_lowercase + string.digits) for i in range(10)])


class Env(object):

    def __init__(self):
        self.region_name = os.getenv('AWS_DEFAULT_REGION', None)
        assert self.region_name, 'Required environment variable `AWS_DEFAULT_REGION` not found.'
        self.s3_staging_dir = os.getenv('AWS_ATHENA_S3_STAGING_DIR', None)
        assert self.s3_staging_dir, 'Required environment variable `AWS_ATHENA_S3_STAGING_DIR` not found.'


ENV = Env()


class WithConnect(object):

    def connect(self, **opts):
        from pyathenajdbc import connect
        return connect(Schema=SCHEMA, **opts)

# -*- coding: utf-8 -*-
import os
import random
import string

from sqlalchemy.dialects import registry

registry.register("awsathena.jdbc", "pyathenajdbc.sqlalchemy_athena", "AthenaDialect")

BASE_PATH = os.path.dirname(os.path.abspath(__file__))
S3_PREFIX = "test_pyathena_jdbc"
WORK_GROUP = "test-pyathena-jdbc"
SCHEMA = "test_pyathena_jdbc_" + "".join(
    [random.choice(string.ascii_lowercase + string.digits) for i in range(10)]
)


class Env(object):
    def __init__(self):
        self.region_name = os.getenv("AWS_DEFAULT_REGION", None)
        assert (
            self.region_name
        ), "Required environment variable `AWS_DEFAULT_REGION` not found."
        self.s3_staging_dir = os.getenv("AWS_ATHENA_S3_STAGING_DIR", None)
        assert (
            self.s3_staging_dir
        ), "Required environment variable `AWS_ATHENA_S3_STAGING_DIR` not found."


ENV = Env()


class WithConnect(object):
    def connect(self, **opts):
        from pyathenajdbc import connect

        return connect(Schema=SCHEMA, **opts)
