Skip to content

chore: adds new sources#12

Merged
semmet95 merged 2 commits into
mainfrom
chore/new-sources
May 2, 2026
Merged

chore: adds new sources#12
semmet95 merged 2 commits into
mainfrom
chore/new-sources

Conversation

@semmet95
Copy link
Copy Markdown
Contributor

@semmet95 semmet95 commented May 2, 2026

No description provided.

@qodo-code-review
Copy link
Copy Markdown

Review Summary by Qodo

Add four new international news sources

✨ Enhancement

Grey Divider

Walkthroughs

Description
• Adds four new news source configurations
• Includes Al Jazeera, BBC, Hindustan Times, SCMP
• Each source includes name, summary, tags, URI
Diagram
flowchart LR
  sources["sources directory"]
  sources -- "adds" --> aljazeera["Al Jazeera<br/>Qatari news org"]
  sources -- "adds" --> bbc["BBC<br/>British broadcaster"]
  sources -- "adds" --> ht["Hindustan Times<br/>Indian newspaper"]
  sources -- "adds" --> scmp["South China Morning Post<br/>Hong Kong newspaper"]
Loading

Grey Divider

File Changes

1. sources/al-jazeera.yaml ⚙️ Configuration changes +4/-0

Add Al Jazeera news source configuration

• Creates new source configuration file
• Defines Al Jazeera as international news organization
• Sets Qatari tag and official website URI

sources/al-jazeera.yaml


2. sources/bbc.yaml ⚙️ Configuration changes +4/-0

Add BBC news source configuration

• Creates new source configuration file
• Defines BBC as British public service broadcaster
• Sets British tag and official website URI

sources/bbc.yaml


3. sources/ht.yaml ⚙️ Configuration changes +4/-0

Add Hindustan Times news source configuration

• Creates new source configuration file
• Defines Hindustan Times as Indian newspaper
• Sets Indian tag and official website URI

sources/ht.yaml


View more (1)
4. sources/scmp.yaml ⚙️ Configuration changes +4/-0

Add South China Morning Post news source configuration

• Creates new source configuration file
• Defines South China Morning Post as Hong Kong newspaper
• Sets Hong Kong tag and official website URI

sources/scmp.yaml


Grey Divider

Qodo Logo

@qodo-code-review
Copy link
Copy Markdown

qodo-code-review Bot commented May 2, 2026

Code Review by Qodo

🐞 Bugs (1) 📘 Rule violations (0)

Grey Divider


Action required

1. Tags contain spaces 🐞 Bug ≡ Correctness
Description
sources/scmp.yaml sets tags to "hong kong" (contains a space), but the SourceInput contract
requires comma-separated tags with no spaces. This will likely be rejected by POST /api/v1/source
(400) and cause the post-on-merge job to fail to register this source.
Code

sources/scmp.yaml[3]

+tags: "hong kong"
Evidence
The new SCMP source file includes a tag value with a space. The OpenAPI spec explicitly states
SourceInput.tags allows no spaces, and the POST endpoint documents that tags containing spaces are
invalid (400). The merge workflow’s POST script treats any non-2xx response as a failure, so a 400
will fail the job for this file.

sources/scmp.yaml[1-4]
oapi.yaml[45-68]
oapi.yaml[475-481]
scripts/post_requests.py[151-165]
AGENTS.md[141-147]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

### Issue description
`sources/scmp.yaml` uses `tags: "hong kong"`, but the repository/API contract requires tags to have **no spaces** (comma-separated tokens).

### Issue Context
If this document is posted as-is after merge, the API may return **400** and the post-on-merge workflow will mark the run as failed.

### Fix Focus Areas
- sources/scmp.yaml[1-4]

### Suggested change
Update the tag to a no-space token, e.g.:
- `tags: "hongkong"` (single tag)
- or `tags: "hong-kong"` / `tags: "hong_kong"`

(If you intended two separate tags, use comma-separated tokens without spaces, e.g. `tags: "hong,kong"`.)

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

Qodo Logo

Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

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

1 issue found across 4 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="sources/scmp.yaml">

<violation number="1" location="sources/scmp.yaml:3">
P2: `tags` must be formatted as comma-separated values without spaces; this value contains a space and can fail schema validation.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Comment thread sources/scmp.yaml Outdated
Comment thread sources/scmp.yaml Outdated
Signed-off-by: Amit Singh <singhamitch@outlook.com>
@semmet95 semmet95 force-pushed the chore/new-sources branch from 36e39b3 to 71add81 Compare May 2, 2026 14:12
Signed-off-by: Amit Singh <singhamitch@outlook.com>
Copy link
Copy Markdown

@cubic-dev-ai cubic-dev-ai Bot left a comment

Choose a reason for hiding this comment

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

1 issue found across 1 file (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="scripts/validate.py">

<violation number="1" location="scripts/validate.py:103">
P2: The `httpsurl` validator is too weak: it only checks `startswith('https://')`, so malformed URLs can pass validation.</violation>
</file>

Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.

Comment thread scripts/validate.py
@semmet95 semmet95 merged commit 87ba8c3 into main May 2, 2026
2 checks passed
@semmet95 semmet95 deleted the chore/new-sources branch May 2, 2026 14:32
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.

1 participant