mirror of
https://github.com/datahub-project/datahub.git
synced 2025-12-25 17:08:29 +00:00
fix(ingest/slack): tweak docs for slack source (#10007)
This commit is contained in:
parent
7540e642a5
commit
bcae7acc51
@ -16,11 +16,7 @@ from datahub.ingestion.api.decorators import (
|
||||
platform_name,
|
||||
support_status,
|
||||
)
|
||||
from datahub.ingestion.api.source import (
|
||||
SourceReport,
|
||||
TestableSource,
|
||||
TestConnectionReport,
|
||||
)
|
||||
from datahub.ingestion.api.source import Source, SourceReport
|
||||
from datahub.ingestion.api.workunit import MetadataWorkUnit
|
||||
from datahub.metadata.schema_classes import (
|
||||
CorpUserEditableInfoClass,
|
||||
@ -89,10 +85,10 @@ class SlackSourceReport(SourceReport):
|
||||
PLATFORM_NAME = "slack"
|
||||
|
||||
|
||||
@platform_name(PLATFORM_NAME)
|
||||
@platform_name("Slack")
|
||||
@config_class(SlackSourceConfig)
|
||||
@support_status(SupportStatus.TESTING)
|
||||
class SlackSource(TestableSource):
|
||||
class SlackSource(Source):
|
||||
def __init__(self, ctx: PipelineContext, config: SlackSourceConfig):
|
||||
self.ctx = ctx
|
||||
self.config = config
|
||||
@ -107,10 +103,6 @@ class SlackSource(TestableSource):
|
||||
config = SlackSourceConfig.parse_obj(config_dict)
|
||||
return cls(ctx, config)
|
||||
|
||||
@staticmethod
|
||||
def test_connection(config_dict: dict) -> TestConnectionReport:
|
||||
raise NotImplementedError("This class does not implement this method")
|
||||
|
||||
def get_slack_client(self) -> WebClient:
|
||||
return WebClient(token=self.config.bot_token.get_secret_value())
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user