### Description
This PR adds two new github actions: one in the OSS repo, one in the monorepo. The OSS action runs `stylish-haskell` on all files touched by the PR, and displays a warning for each file that was in need of a formatting. The monorepo action does the same thing, with a twist: if the branch is not a shadow copy of an OSS branch, we assume that it is a local branch, and simply push a new commit with the changes.
Furthermore, this PR upgrades our stylish-haskell config to add record formatting, as close as possible to our styleguide.
Both actions use the standard stylish-haskell, not our modified fork.
### Known limitation
The monorepo action does not handle forks: pushing to the branch will fail, and checking the branch out might fail too. This is probably acceptable since we don't use forks with the monorepo, but it wouldn't be hard to handle that gracefully.
GitOrigin-RevId: 814138c5b9826098e2e4ea192778fc0d93fbe390
fixes https://github.com/hasura/graphql-engine/issues/6449
A while back we added [support for customizing JWT claims](https://github.com/hasura/graphql-engine/pull/3575) and this enabled to map a session variable to any value within the unregistered claims, but as reported in #6449 , users aren't able to map the `x-hasura-user-id` session variable to the `sub` standard JWT claim.
This PR fixes the above issue by allowing mapping session variables to standard JWT claims as well.
GitOrigin-RevId: d3e63d7580adac55eb212e0a1ecf7c33f5b3ac4b
Instead of using hlint's return value to determine whether the check was successful, we parse the output to see if there was any error. In practice, that means that hlint suggestions, which are translated as warnings on a pr, will no longer mark the check as failed.
GitOrigin-RevId: dff2a50180de0c5f0702a9799b1f6359499da6a5
This PR generalizes a bunch of metadata structures.
Most importantly, it changes `SourceCache` to hold existentially quantified values:
```
data BackendSourceInfo =
forall b. Backend b => BackendSourceInfo (SourceInfo b)
type SourceCache = HashMap SourceName BackendSourceInfo
```
This changes a *lot* of things throughout the code. For now, all code using the schema cache explicitly casts sources to Postgres, meaning that if any non-Postgres `SourceInfo` makes it to the cache, it'll be ignored.
That means that after this PR is submitted, we can split work between two different aspects:
- creating `SourceInfo` for other backends
- handling those other sources down the line
GitOrigin-RevId: fb9ea00f32e840fc33c5467896fb1dfa5283ab42
resolves#134
The PR adds a new header(`Hasura-Internal-Request-Source`) to every request sent to the server.
Co-authored-by: Aleksandra Sikora <9019397+beerose@users.noreply.github.com>
GitOrigin-RevId: 9d1538fcf92fd5a00c649884b910da3f3993cd47
### Description
Our Prelude provides the very convenient `hoistMaybe :: Maybe b -> MaybeT m b`. This PR adds hlint rules to replace uses of `MaybeT $ pure $ x` with the cleaner `hoistMaybe x`, and rules to specifically replace `MaybeT $ pure Nothing` with `empty`.
GitOrigin-RevId: 7254f4954e34e4d7ca972dc7c12073d3ab8cb0b8
Fixes https://github.com/hasura/graphql-engine/issues/5704 by checking, for aggregate fields whether we are handling a numeric aggregation.
This PR also adds type information to `ColFld` such that we know the type of the field.
This is the second attempt. See #319 for a less invasive approach. @nicuveo suggested type information might be useful, and since it wasn't hard to add, I think this version is better as well.
GitOrigin-RevId: aa6a259fd5debe9466df6302839ddbbd0ea659b5
Earlier (pre catalog separation), the remote schema permissions were in `/v1/query`. This PR moves it to `/v1/metadata`.
GitOrigin-RevId: cb39d9df4cc2288f67231504e3a7909f2f8df4da
This PR was migrated from https://github.com/hasura/graphql-engine/pull/6300
---
Accept password instead of email in UserInfo Mutation type example
Co-authored-by: Tobias Törnros <17402497+tobiastornros@users.noreply.github.com>
GitOrigin-RevId: 9fbc0fc1ad4e6725b5411c271dd8e2d1ee7840be
This PR updates the svg logo assets inside the `assets/brand` directory with the new Hasura logo.
GitOrigin-RevId: 14c895be65dc3c149f4a78b07d83fa2c3ce3455e
fixes https://github.com/hasura/graphql-engine/issues/2109
This PR accepts a new config `allowed_skew` in the JWT config to provide for some leeway while comparing the JWT expiry time.
GitOrigin-RevId: ef50cf77d8e2780478685096ed13794b5c4c9de4
Fixes https://github.com/hasura/graphql-engine/issues/6385
In the v1.3.4-beta.2 version, the SQL generated for a query action containing relationship and configured with permissions parsed the `x-hasura-user-id` session variable value through the `hasura.user` postgres setting instead of passing the session variables as an JSON object to the query as it was in v1.3.3.
This PR fixes the SQL generation to that of v1.3.3
Co-authored-by: Rakesh Emmadi <12475069+rakeshkky@users.noreply.github.com>
GitOrigin-RevId: 838ba812f89b51df7fcead81b9d3c2885dfa39b4
#### Changelog - (have added an entry)
#### PR Description
This PR resolves https://github.com/hasura/graphql-engine/issues/6284.
- Updates the API being used as the issue requires.
- Places a check to raise an error whenever the user tries to save the custom_fields without _any_ input (it was possible in the previous versions of the console)
- Updated form (picture)
<img width="745" alt="image" src="https://user-images.githubusercontent.com/6604943/103933740-d866a480-5149-11eb-90b2-e1c1c4559902.png">
Co-authored-by: Aleksandra Sikora <9019397+beerose@users.noreply.github.com>
GitOrigin-RevId: df3127c3c58b5ecf2d6ab79cb95610a96592ca12
This PR was migrated from https://github.com/hasura/graphql-engine/pull/6254
---
>
### Description
>
### Changelog
- [ ] `CHANGELOG.md` is updated with user-facing content relevant to this PR. If no changelog is required, then add the `no-changelog-required` label.
### Affected components
- [ ] Server
- [ ] Console
- [ ] CLI
- [ ] Docs
- [ ] Community Content
- [ ] Build System
- [ ] Tests
- [ ] Other (list it)
### Related Issues
->
### Solution and Design
>
### Steps to test and verify
>
### Limitations, known bugs & workarounds
>
### Server checklist
#### Catalog upgrade
Does this PR change Hasura Catalog version?
- [ ] No
- [ ] Yes
- [ ] Updated docs with SQL for downgrading the catalog
#### Metadata
Does this PR add a new Metadata feature?
- [ ] No
- [ ] Yes
- Does `run_sql` auto manages the new metadata through schema diffing?
- [ ] Yes
- [ ] Not required
- Does `run_sql` auto manages the definitions of metadata on renaming?
- [ ] Yes
- [ ] Not required
- Does `export_metadata`/`replace_metadata` supports the new metadata added?
- [ ] Yes
- [ ] Not required
#### GraphQL
- [ ] No new GraphQL schema is generated
- [ ] New GraphQL schema is being generated:
- [ ] New types and typenames are correlated
#### Breaking changes
- [ ] No Breaking changes
- [ ] There are breaking changes:
1. Metadata API
Existing `query` types:
- [ ] Modify `args` payload which is not backward compatible
- [ ] Behavioural change of the API
- [ ] Change in response `JSON` schema
- [ ] Change in error code
2. GraphQL API
Schema Generation:
- [ ] Change in any `NamedType`
- [ ] Change in table field names
Schema Resolve:-
- [ ] Change in treatment of `null` value for any input fields
3. Logging
- [ ] Log `JSON` schema has changed
- [ ] Log `type` names have changed
Co-authored-by: Thomas Güttler <414336+guettli@users.noreply.github.com>
GitOrigin-RevId: 8381a182e9f380b98e0ebe918727e0ccae103e14
### Description
This PR updates the datadog integration screenshots.
### Changelog
- [ ] `CHANGELOG.md` is updated with user-facing content relevant to this PR. If no changelog is required, then add the `no-changelog-required` label.
### Affected components
- [x] Docs
### Affected pages
https://deploy-preview-289--hasura-docs-mono.netlify.app/graphql/cloud/metrics/integrations/datadog.html
Co-authored-by: Rikin Kachhia <54616969+rikinsk@users.noreply.github.com>
GitOrigin-RevId: 206234de7e461a04ea75715480fa714b35d185a1
This PR is a combination of the following other PRs:
- #169: move HasHttpManager out of RQL.Types
- #170: move UserInfoM to Hasura.Session
- #179: delete dead code from RQL.Types
- #180: move event related code to EventTrigger
GitOrigin-RevId: d97608d7945f2c7a0a37e307369983653eb62eb1
This PR was migrated from https://github.com/hasura/graphql-engine/pull/6171
---
### Description
A trivial change to make `dev.sh` use -Werror. This is what our CI uses, and it's annoying to have a PR rejected because of a warning that was missed at dev time. Since this is only for `dev.sh`, it won't impact most people's normal workflow.
Co-authored-by: Antoine Leblanc <1618949+nicuveo@users.noreply.github.com>
GitOrigin-RevId: 37c2f088c37326c244533a003bf9b8169448abc8
### Description
This PR updates the graphql schema to be backend-agnostic. To do so, it also moves the definition of operators to `BackendSchema`, to be specified differently per backend.
GitOrigin-RevId: 35b9d2d1bff93fb68b872d6ab0d3d12ec12c1b93