Skip to content

v1.3.0#6

Merged
Artemonim merged 7 commits intomasterfrom
1.2.2
Jun 30, 2025
Merged

v1.3.0#6
Artemonim merged 7 commits intomasterfrom
1.2.2

Conversation

@Artemonim
Copy link
Copy Markdown
Owner

@Artemonim Artemonim commented Jun 30, 2025

Type of Change

  • 🐛 Bug Fix: A change that fixes an issue.
  • New Feature: A change that adds new functionality.
  • ♻️ Refactor: A code change that neither fixes a bug nor adds a feature.
  • 📚 Documentation: Changes to the documentation only.
  • ⚙️ CI/CD: Changes to our CI/CD configuration and scripts.
  • 🔨 Build: Changes that affect the build system or external dependencies.
  • 🎨 Style: Changes that do not affect the meaning of the code (white-space, formatting, etc.).
  • Revert: Reverts a previous commit.

Related Issue

Description

Added

  • Process Individual Files: The CLI now accepts both directory and individual file paths, allowing for more granular control over which files are processed.
  • Expanded Keywords: Added a comprehensive list of keywords to pyproject.toml to significantly improve package discoverability on PyPI and search engines.
  • Beta Features Flag: Introduced a --beta command-line flag to enable experimental features that are under development.

Changed

  • Header Text Update: Changed the auto-generated header to "Table of content is automatically generated by Agent Docstrings {version}".
  • Streamlined Header Format: The format of the generated "Table of Contents" has been improved. Top-level functions and classes are now presented in a single, chronologically sorted list, removing the nested "Functions" section for a cleaner, more intuitive layout.
  • Deterministic Sorting: All discovered items (classes, methods, functions) are now strictly sorted by their line number in the source file, ensuring a consistent and predictable output every time.
  • CLI Argument Renaming: The DIRECTORY argument in the CLI has been renamed to PATH to accurately reflect its new capability to handle both files and directories.
  • Header Version Updates: The tool will now update the header if the generator version has changed, even if the code structure remains the same, ensuring docstrings always reflect the version of the tool that generated them.
  • Repository URLs: Updated project URLs in pyproject.toml to point to the correct AgentDocstrings repository name.

Fixed

  • Error Handling for Inaccessible Directories: Fixed a crash (PermissionError) that occurred when scanning directories with restricted read permissions. The application will now skip such directories and print a warning, preventing unintended modifications to files that might have been excluded by an unreadable .gitignore or other configuration files.
  • Deleting Empty Lines: Restored preservation of trailing empty lines at the end of processed files.
  • Language-Specific Indentation: Fixed the indentation in the generated 'Table of Contents' to respect common style conventions for each language (e.g., 4 spaces for Python, 2 for JavaScript).

Build

  • Python Version Support: Updated the minimum required Python version from 3.8 to 3.10 to align with modern dependencies and language features. Project metadata (pyproject.toml) and CI configurations have been updated accordingly.

CI/CD

  • Continuous Integration Workflow: Added a new GitHub Actions workflow (ci.yml) to automatically run tests on all pushes and pull requests to the master branch. The workflow tests against multiple Python versions (3.10–3.13) and includes matrix testing for beta features.

Documentation

  • Complete README Overhaul: The README.md has been completely rewritten to be more comprehensive, professional, and user-friendly. It now includes a clear project mission, a detailed table of contents, expanded sections on features and usage, new examples, and platform compatibility information.
  • Pull Request Template: Added a PULL_REQUEST_TEMPLATE.md to standardize contributions.
  • Demo Video: Included a new video in the README.md to demonstrate the tool's functionality.

Checklist

  • My code follows the style guidelines of this project.
  • I have performed a self-review of my own code.
  • New unit tests have been added to cover the changes.
  • Manual testing has been performed.

### Added
-   **Process Individual Files**
-   **Expanded Keywords**
-   **Beta Features Flag**

### Changed
-   **Header Text Update**
-   **Streamlined Header Format**
-   **Deterministic Sorting**
-   **CLI Argument Renaming**
-   **Header Version Updates**
-   **Repository URLs**

### Fixed
-   **Deleting empty lines**

### Documentation
-   **Complete README Overhaul**
### Changed
- Updated the `python-version` matrix in the CI workflow from a list of integers to a list of strings for better compatibility and consistency.
### Added
- Upload coverage artifact after tests.
- Download all coverage artifacts for reporting.

### Changed
- Updated Codecov action to version 4 and adjusted parameters for artifact directory.
### Changed
- Removed the `newline` parameter from `path.write_text` calls in the `process_file` function to ensure consistent handling of line endings.
### Changed
- Removed support for Python 3.8 and 3.9 from `pyproject.toml` and updated the `requires-python` field to require Python 3.10 or higher.
- Adjusted the `target-version` in the Black configuration to reflect the removal of older Python versions.
- Updated the CI workflow to only include Python versions 3.10 and above in the matrix.
### Changed
- Modified the CI workflow to use `pull_request_target` instead of `pull_request` for better security and context when handling pull requests.
- Added a reference to the pull request's head SHA in the checkout step to ensure the correct commit is checked out during the CI process.
@Artemonim Artemonim merged commit 58261e4 into master Jun 30, 2025
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.

[FEATURE] Single-file processing [FEATURE] Add "Table of content" label in docstring header

1 participant