Skip to content

Add missing trailing newlines to reported api/ files#603

Draft
Copilot wants to merge 3 commits intostagingfrom
copilot/cleanup-api-files-newlines
Draft

Add missing trailing newlines to reported api/ files#603
Copilot wants to merge 3 commits intostagingfrom
copilot/cleanup-api-files-newlines

Conversation

Copy link
Contributor

Copilot AI commented Mar 10, 2026

Several Python files under api/ were missing a POSIX trailing newline, which creates noisy diffs and can trip file-format-sensitive tooling. This updates the reported files and adds narrow regression coverage for the exact paths called out in the issue.

  • Trailing newline cleanup

    • Adds a final newline to:
      • api/analyzers/csharp/__init__.py
      • api/entities/entity.py
      • api/index.py
      • api/llm.py
      • api/prompts.py
  • Regression coverage

    • Adds a focused test that asserts each reported file ends with \n
    • Keeps the check scoped to the files identified in the issue
  • Example

    from pathlib import Path
    
    assert Path("api/index.py").read_bytes().endswith(b"\n")
Original prompt

This section details on the original issue you should resolve

<issue_title>Cleanup: Several api/ files missing trailing newlines</issue_title>
<issue_description>## Description

The following files under api/ are missing POSIX-required trailing newlines:

  • api/analyzers/csharp/__init__.py
  • api/entities/entity.py
  • api/index.py
  • api/llm.py
  • api/prompts.py

This can cause issues with some tools and produces noisy git diffs.

Suggested Fix

Add a trailing newline to each file. Most editors can be configured to do this automatically.

Context

Found during code review of PR #522.</issue_description>

Comments on the Issue (you are @copilot in this section)


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

@vercel
Copy link

vercel bot commented Mar 10, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
code-graph Error Error Mar 10, 2026 9:29pm

Request Review

Co-authored-by: gkorland <753206+gkorland@users.noreply.github.com>
Co-authored-by: gkorland <753206+gkorland@users.noreply.github.com>
Copilot AI changed the title [WIP] Add trailing newlines to missing api/ files Add missing trailing newlines to reported api/ files Mar 10, 2026
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.

Cleanup: Several api/ files missing trailing newlines

2 participants