Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add a warning when a near-table is detected #30

Merged
merged 10 commits into from
Apr 13, 2024
Merged

Conversation

amtoine
Copy link
Owner

@amtoine amtoine commented Feb 17, 2024

this PR

  • makes it that nu::value::is_table returns a nu::value::Table variant which hold more information about why the value is not a table
  • adds a warning banner at the bottom to indicate the user why they are seeing a list of records
  • adds a bunch of new tests for is_table for the new table variants
  • make the colors of the warning banner configurable

Important
this will only work with #41, this can be achieved by running

git merge bump-set_foreground

on top of this commit

@amtoine amtoine added the enhancement New feature or request label Feb 17, 2024
@amtoine
Copy link
Owner Author

amtoine commented Feb 17, 2024

Important
it appears the keys of a record are not guaranteed to be in the same order each time.
this has to consequences

  • the tests might fail every now and then
  • the warning banner changes all the time because the ordering of the rows changes

amtoine added a commit that referenced this pull request Feb 17, 2024
this is to make sure the local version of Rust and the remote one in the
CI are in sync and avoid CIs such as the one of
#30 to fail where the
local one is working correctly.
@amtoine amtoine marked this pull request as draft February 17, 2024 12:48
@amtoine amtoine force-pushed the precise-table-detection branch 2 times, most recently from 8c7fde0 to be0fd68 Compare April 13, 2024 09:38
@amtoine amtoine force-pushed the precise-table-detection branch from be0fd68 to 82f7355 Compare April 13, 2024 10:03
@amtoine amtoine marked this pull request as ready for review April 13, 2024 10:04
this will bring the CI changes and make sure all is good.
@amtoine amtoine merged commit c50c9b1 into main Apr 13, 2024
4 checks passed
@amtoine amtoine deleted the precise-table-detection branch April 13, 2024 11:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant