Skip to content

Conversation

@ahey
Copy link
Contributor

@ahey ahey commented Dec 3, 2025

Contributor checklist

Leave anything that you believe does not apply unchecked.

  • I accept the AI Policy, or AI was not used in the creation of this PR.
  • Bug fixes include regression tests
  • Chores
  • Documentation changes
  • Features include unit/acceptance tests
  • Refactoring
  • Update dependencies

…relationship field

A test covering this fix has been created in ash_postgres
@zachdaniel
Copy link
Contributor

@ahey is this a consequence from your other change? Extracting parent refs is not something that are on the table nor should we have to do it. Is there a specific bug you're looking to fix?

@ahey
Copy link
Contributor Author

ahey commented Dec 3, 2025

@zachdaniel this is unrelated to the other change. Here is the test that reproduces the issue: ash-project/ash_postgres#658

@zachdaniel
Copy link
Contributor

Got it. I'll have to look into this further this week or this weekend because I don't think we can extract refs like this in general, there are too many edge cases. We would instead likely need to do something when adding the aggregates themselves where the filter ends up being fully hydrated to track what parent attributes are referenced to ensure they are selected for example.

@ahey
Copy link
Contributor Author

ahey commented Dec 3, 2025

Thanks @zachdaniel for your help and the update.

@zachdaniel
Copy link
Contributor

Actually, I think this covers enough and does actually solve the issue, there might just be some additional work downstream to expand certain kinds of references. This also helped me fix another issue also. Thanks!

@zachdaniel zachdaniel merged commit 917e583 into ash-project:main Dec 7, 2025
22 of 23 checks passed
@ahey
Copy link
Contributor Author

ahey commented Dec 7, 2025

You're most welcome, and thank you for your help on this! All tests are passing on my ash projects 😄

@ahey ahey deleted the aggregate-parent-select branch December 7, 2025 22:16
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.

2 participants