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

[SDCP-627] fix : Planning: As a SD admin I like to ingest events from the Onclusive API #1699

Merged
merged 3 commits into from
Jul 20, 2022

Conversation

devketanpro
Copy link
Member

No description provided.

@devketanpro devketanpro marked this pull request as ready for review July 19, 2022 07:33
@@ -101,18 +101,13 @@ def _update(self, provider, update):
logger.info("Ingesting content: {} ...".format(str(between_event_response.content)[:4000]))

if hasattr(parser, "parse_http"):
Copy link
Member

Choose a reason for hiding this comment

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

are actually both options possible? imo we should limit onclusive to single parser as we do for rss

Copy link
Member Author

Choose a reason for hiding this comment

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

as much as i understand, that we have to registered a feedparser in the feeding service just like rss or we should do something like:

 if hasattr(parser, "parse_onclusive"):
      yield (parser.parse_onclusive(content, provider))

Copy link
Member

Choose a reason for hiding this comment

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

we can set the parser explicitly like here:
https://github.com/superdesk/superdesk-core/blob/1b3ff89a92d3cce8e1cbfe635f4c23c6e39f9a5c/superdesk/io/feeding_services/rss.py#L403
so then we know it will be using onclusive parser and the parser will have that parse_http method so that if is not needed anymore

@petrjasek petrjasek added this to the 2.6 milestone Jul 19, 2022
@petrjasek petrjasek merged commit 11f7580 into superdesk:develop Jul 20, 2022
@devketanpro devketanpro deleted the SDCP-627 branch July 21, 2022 15:19
@MarkLark86 MarkLark86 changed the title Fix : Planning: As a SD admin I like to ingest events from the Onclusive API [SDCP-627] [SDCP-627] fix : Planning: As a SD admin I like to ingest events from the Onclusive API Dec 12, 2022
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.

2 participants