You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by "spmallette (via GitHub)" <gi...@apache.org> on 2026/07/27 12:27:30 UTC

[PR] Add runnable count(local) examples to the Count Step docs [tinkerpop]

spmallette opened a new pull request, #3573:
URL: https://github.com/apache/tinkerpop/pull/3573

   The `count(local)` behavior in the Count Step section of the reference documentation was described only in an `IMPORTANT` prose callout, with no executable examples. The callout also omitted the `Path` case: it stated that a count of `1` is returned "for any other object," but `CountLocalStep` returns the path length for a `Path`.
   
   This change:
   
   - Removes the prose-only callout and repurposes its content as explanatory prose that correctly covers all object kinds the step handles: `Collection` (number of elements), `Map` (number of entries), `Path` (number of objects in the path), and any other object (`1`).
   - Adds a runnable example block against the modern graph so the per-object-kind counts render as live output at build time and are self-verifying:
     - `g.V().fold().count(local)` → `6` (Collection)
     - `g.V().group().by(label).count(local)` → `2` (Map)
     - `g.V(1).out().path().count(local)` → `2, 2, 2` (Path)
     - `g.V(1).count(local)` → `1` (any other object)
   - Cross-links the examples to `fold()`, `group()`, `path()`, and the path data structure so a reader can follow the behavior in context.
   
   The reference book builds and the count-step section reads coherently with the rendered live output matching the documented counts.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tinkerpop.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Add runnable count(local) examples to the Count Step docs [tinkerpop]

Posted by "spmallette (via GitHub)" <gi...@apache.org>.
spmallette closed pull request #3573: Add runnable count(local) examples to the Count Step docs
URL: https://github.com/apache/tinkerpop/pull/3573


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tinkerpop.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Add runnable count(local) examples to the Count Step docs [tinkerpop]

Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #3573:
URL: https://github.com/apache/tinkerpop/pull/3573#issuecomment-5091475033

   ## [Codecov](https://app.codecov.io/gh/apache/tinkerpop/pull/3573?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
   :white_check_mark: All modified and coverable lines are covered by tests.
   :white_check_mark: Project coverage is 77.08%. Comparing base ([`4722890`](https://app.codecov.io/gh/apache/tinkerpop/commit/4722890ed831ba4f71c3916b5e6eafcf85439345?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`cabf641`](https://app.codecov.io/gh/apache/tinkerpop/commit/cabf6419e3bb19b1ae780f4696c325224b52fe51?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
   :warning: Report is 44 commits behind head on 3.7-dev.
   
   <details><summary>Additional details and impacted files</summary>
   
   
   
   ```diff
   @@              Coverage Diff              @@
   ##             3.7-dev    #3573      +/-   ##
   =============================================
   + Coverage      75.49%   77.08%   +1.58%     
   =============================================
     Files           1092       28    -1064     
     Lines          67208     5337   -61871     
     Branches        7391        0    -7391     
   =============================================
   - Hits           50742     4114   -46628     
   + Misses         13837     1020   -12817     
   + Partials        2629      203    -2426     
   ```
   </details>
   
   [:umbrella: View full report in Codecov by Harness](https://app.codecov.io/gh/apache/tinkerpop/pull/3573?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).   
   :loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
   <details><summary> :rocket: New features to boost your workflow: </summary>
   
   - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
   - :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tinkerpop.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] Add runnable count(local) examples to the Count Step docs [tinkerpop]

Posted by "spmallette (via GitHub)" <gi...@apache.org>.
spmallette commented on PR #3573:
URL: https://github.com/apache/tinkerpop/pull/3573#issuecomment-5105363435

   Merged with 06e12a84587b28f9044aac60e0235bb928774f7e


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@tinkerpop.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org