Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 3, 2025

  • Review current pipeline.rst documentation structure
  • Add a clear "Pipeline Overview" section explaining key concepts upfront
  • Add "Understanding Return Values" section with clear examples
  • Add "Common Function Parameters" section
  • Improve "Understanding the Default Pipeline" section with data availability timeline
  • Enhance customization examples with better explanations
  • Improve partial pipeline explanation with step-by-step guide and practical examples
  • Reorganize "Extending the Pipeline" section for better flow
  • Add "Common Patterns and Tips" section with practical examples
  • Build and verify documentation compiles without errors
  • Address code review feedback for safer examples
  • Use Sphinx directives (note, important, tip) instead of manual formatting
  • Remove duplicated parameter descriptions
  • Add Django-specific note for template example
  • Add cross-reference to avoid duplication
  • Final review completed
Original prompt

Can you please imporve the pipeline documentation based on questions asked at https://github.com/orgs/python-social-auth/discussions/1253. Make the changes clear, concise and easy to understand.


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

Copilot AI changed the title [WIP] Can you please imporve the pipeline documentation based on questions asked at https://github.com/orgs/python-social-auth/discussions/1253. Make the changes clear, concise and easy to understand. Improve pipeline documentation with clearer structure and practical examples Nov 3, 2025
Copilot AI requested a review from nijel November 3, 2025 10:23
Copilot finished work on behalf of nijel November 3, 2025 10:23
Copy link
Member

@nijel nijel left a comment

Choose a reason for hiding this comment

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

Some parts are now duplicated (for example, parameter descriptions).

in the dict is populated. In cases where the authentication is purely external, a
pipeline method must be provided that populates the ``user`` key. Example::
**Note:** This example removes ``get_username`` and ``create_user`` steps, so only
users who have previously authenticated can log in.
Copy link
Member

Choose a reason for hiding this comment

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

Using .. note:: syntax might be more appropriate.

~~~~~~~~~~~~~~~~~~~~~~~~~~~

To override the default parameter name just define::
``@partial`` stores the pipeline state in a database table named ``social_auth_partial``.
Copy link
Member

Choose a reason for hiding this comment

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

This is really a backend-specific information, this is valid for Django only.

2. **Place it in an importable location** in your project
3. **Add it to the pipeline** in your settings at the appropriate position

**Important:** Function placement matters! The order determines what data is available.
Copy link
Member

Choose a reason for hiding this comment

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

Use Sphinx markup instead of manual tagging.

The pipeline functions will get quite a lot of arguments, ranging from the
backend in use, different model instances, server requests and provider
responses. To enumerate a few:
**Tip:** Always include ``**kwargs`` to handle additional parameters from other
Copy link
Member

Choose a reason for hiding this comment

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

Another place to use sphinx markup.

@nijel
Copy link
Member

nijel commented Nov 3, 2025

@copilot Please address the code review. Use Sphinx markup when possible and avoid too long documentation with repeating the same content.

@nijel
Copy link
Member

nijel commented Nov 3, 2025

@nijel
Copy link
Member

nijel commented Nov 3, 2025

@copilot Retry

Copy link
Contributor Author

Copilot AI commented Nov 3, 2025

@copilot Retry

Addressed all code review feedback in commit 100cfac:

  • Used Sphinx directives (.. note::, .. important::, .. tip::) instead of manual formatting
  • Removed duplicated parameter descriptions by replacing second occurrence with cross-reference to first
  • Added "Django example" label to clarify backend-specific template code
  • Added reference label for cross-linking

Documentation now builds successfully and renders properly with styled admonitions.

Note admonition
Important and Tip admonitions

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • docs.python.org
    • Triggering command: /usr/bin/python3 /home/REDACTED/.local/bin/sphinx-build -b html -d _build/doctrees . _build/html (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Copilot finished work on behalf of nijel November 3, 2025 12:46
@nijel nijel marked this pull request as ready for review November 3, 2025 13:09
@nijel nijel requested a review from Copilot November 3, 2025 13:09
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR significantly enhances the pipeline documentation by expanding it from basic explanations to comprehensive, tutorial-style documentation. The changes improve developer understanding of how to use and extend the pipeline system in python-social-auth.

Key changes:

  • Added detailed explanations of pipeline concepts, return values, and function parameters
  • Expanded examples with practical code snippets and use cases
  • Added new sections on partial pipelines, custom pipeline functions, and common patterns
Comments suppressed due to low confidence (1)

docs/pipeline.rst:1

  • The documentation states current_partial.backend contains 'The backend name' but the code example assigns it to a variable named backend. This is misleading as it suggests it's a backend instance rather than a backend name string. Consider clarifying in the bullet point that this is the backend name string, not the backend instance object.
Pipeline

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@nijel
Copy link
Member

nijel commented Nov 3, 2025

pre-commit.ci autofix

@nijel nijel merged commit 5ea59a7 into master Nov 3, 2025
5 checks passed
@nijel nijel deleted the copilot/fix-21279195-69119365-ecbe4c3d-efa6-4cde-83a1-bf64b1a48a38 branch November 3, 2025 13:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants