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

plainHTTP property in our API should named plainHttp #6940

Closed
rynowak opened this issue Dec 8, 2023 · 4 comments · Fixed by #6943
Closed

plainHTTP property in our API should named plainHttp #6940

rynowak opened this issue Dec 8, 2023 · 4 comments · Fixed by #6943
Assignees
Labels
bug Something is broken or not working as expected important This item is a high priority Issue we intend to address as soon as possible triaged This issue has been reviewed and triaged

Comments

@rynowak
Copy link
Contributor

rynowak commented Dec 8, 2023

Bug information

Steps to reproduce (required)

Recipes added a new property to environments that is spelled plainHTTP. This doesn't follow our API guidelines, and our tools even warn about it.

Run make generate in our repo.

Observed behavior (required)

Diagnostics were reported during compilation:

/Users/ryan/github.com/radius-project/radius/typespec/Applications.Core/environments.tsp:108:3 - warning @azure-tools/typespec-azure-core/casing-style: The names of Property types must use camelCase
> 108 |   @doc("Connect to the Bicep registry using HTTP (not-HTTPS). This should be used when the registry is known not to support HTTPS, for example in a locally-hosted registry. Defaults to false (use HTTPS/TLS).")
      |   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> 109 |   plainHTTP?: boolean;
      | ^^^^^^^^^^^^^^^^^^^^^^
/Users/ryan/github.com/radius-project/radius/typespec/Applications.Core/environments.tsp:144:3 - warning @azure-tools/typespec-azure-core/casing-style: The names of Property types must use camelCase
> 144 |   @doc("Connect to the Bicep registry using HTTP (not-HTTPS). This should be used when the registry is known not to support HTTPS, for example in a locally-hosted registry. Defaults to false (use HTTPS/TLS).")
      |   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> 145 |   plainHTTP?: boolean;
      | ^^^^^^^^^^^^^^^^^^^^^^

Desired behavior (required)

Property should be named plainHttp not plainHTTP.

This was named correctly in the design doc, but was checked in with the wrong casing: https://github.com/radius-project/design-notes/pull/30/files#diff-e5748769189a4eae9291406121d2e7625dd427de017d9b6f5dd317a7e0cac278R70

@rynowak rynowak added the bug Something is broken or not working as expected label Dec 8, 2023
@radius-triage-bot
Copy link

👋 @rynowak Thanks for filing this bug report.

A project maintainer will review this report and get back to you soon. If you'd like immediate help troubleshooting, please visit our Discord server.

For more information on our triage process please visit our triage overview

@rynowak
Copy link
Contributor Author

rynowak commented Dec 8, 2023

/cc @vishwahiremat

@vishwahiremat vishwahiremat self-assigned this Dec 8, 2023
@shalabhms shalabhms added the triaged This issue has been reviewed and triaged label Dec 11, 2023
@radius-triage-bot
Copy link

👍 We've reviewed this issue and have agreed to add it to our backlog. Please subscribe to this issue for notifications, we'll provide updates when we pick it up.

We also welcome community contributions! If you would like to pick this item up sooner and submit a pull request, please visit our contribution guidelines and assign this to yourself by commenting "/assign" on this issue.

For more information on our triage process please visit our triage overview

@shalabhms shalabhms added the important This item is a high priority Issue we intend to address as soon as possible label Dec 11, 2023
@radius-triage-bot
Copy link

We've prioritized work on this issue. Please subscribe to this issue for notifications, we'll provide updates as we make progress.

We also welcome community contributions! If you would like to pick this item up sooner and submit a pull request, please visit our contribution guidelines and assign this to yourself by commenting "/assign" on this issue.

For more information on our triage process please visit our triage overview

vishwahiremat added a commit that referenced this issue Dec 12, 2023
# Description

-Added  changes to rename plainHTTP property to plainHttp
- updated it on typespec and generated the code and updated unit tests. 

## Type of change

<!--

Please select **one** of the following options that describes your
change and delete the others. Clearly identifying the type of change you
are making will help us review your PR faster, and is used in authoring
release notes.

If you are making a bug fix or functionality change to Radius and do not
have an associated issue link please create one now.

-->

- This pull request fixes a bug in Radius and has an approved issue
(issue link required).
- This pull request is a minor refactor, code cleanup, test improvement,
or other maintenance task and doesn't change the functionality of Radius
(issue link optional).

<!--

Please update the following to link the associated issue. This is
required for some kinds of changes (see above).

-->

Fixes: #6940

## Auto-generated summary

<!--
GitHub Copilot for docs will auto-generate a summary of the PR
-->

<!--
copilot:all
-->
### <samp>🤖[[deprecated]](https://githubnext.com/copilot-for-prs-sunset)
Generated by Copilot at 431e72a</samp>

### Summary
🔧🔄📝

<!--
1. 🔧 - This emoji represents a wrench, which can symbolize fixing,
adjusting, or improving something. This emoji could be used to indicate
that the changes are meant to improve the consistency and accuracy of
the property name across different files and languages.
2. 🔄 - This emoji represents a clockwise arrow, which can symbolize
updating, refreshing, or syncing something. This emoji could be used to
indicate that the changes are meant to update the property name to match
the latest specification and schema.
3. 📝 - This emoji represents a memo, which can symbolize writing,
editing, or documenting something. This emoji could be used to indicate
that the changes are meant to edit the property name to follow the
correct spelling and casing.
-->
This pull request renames the `plainHTTP` property to `plainHttp` in
various JSON, Go, and TypeScript files that are related to Bicep and
environment recipes. This is done to ensure consistency between the
code, the JSON schema, and the OpenAPI specification.

> _We are the renegades of `plainHttp`_
> _We defy the tyranny of `plainHTTP`_
> _We align the code with the schema and the spec_
> _We are the renegades of `plainHttp`_

### Walkthrough
* Rename `plainHTTP` property to `plainHttp` in all JSON, Go,
TypeScript, and OpenAPI files to ensure consistency and alignment with
naming conventions
([link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-5ebcba4c29787645de8388e21ceea2cd681cab503ffab539ac282adccd2de2f1L4-R4),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-2fc231a38ea62a42b47752ad6dff1e90a78b221b12d803073e4de8fa0f36f68aL42-R42),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-9c2e08918bebee99736d5983565f2e44042c9c138ffb376fa6d9f6054efc0d2eL40-R40),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-bc1502ced9e29d6d61dc028d22603e863f59a981bbc54a59879ba3177d8e62e9L426-R426),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-bc1502ced9e29d6d61dc028d22603e863f59a981bbc54a59879ba3177d8e62e9L444-R444),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-bc1502ced9e29d6d61dc028d22603e863f59a981bbc54a59879ba3177d8e62e9L465-R465),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-bc1502ced9e29d6d61dc028d22603e863f59a981bbc54a59879ba3177d8e62e9L483-R483),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-bc1502ced9e29d6d61dc028d22603e863f59a981bbc54a59879ba3177d8e62e9L3267-R3267),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-bc1502ced9e29d6d61dc028d22603e863f59a981bbc54a59879ba3177d8e62e9L3286-R3286),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-b9eb5dc9371937efbfc783c67791f6a4da924efc2126d841289ed88c936cc4bbL54-R54),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-65fb01db3055625aa2990fdbaf8053f34dbb4df3f6fded4710b12bc13fdeb12aL21-R21),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-31df6a867aea76382a87df5433b2c7d018f97461e5221da1a06810ac182f9fc7L4-R4),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-ac35cdfa65680d5d2be2d0513a686f4651b9a41eb951d05dcd446bc927090d68L2799-R2799),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-ac35cdfa65680d5d2be2d0513a686f4651b9a41eb951d05dcd446bc927090d68L2815-R2815),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-ac35cdfa65680d5d2be2d0513a686f4651b9a41eb951d05dcd446bc927090d68L4756-R4756),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-afd83699015b6426efe6ec70fcec90303e63689cef1b48839eb95d8435acd046L109-R109),
[link](https://github.com/radius-project/radius/pull/6943/files?diff=unified&w=0#diff-afd83699015b6426efe6ec70fcec90303e63689cef1b48839eb95d8435acd046L145-R145))

Signed-off-by: Vishwanath Hiremath <vhiremath@microsoft.com>
Co-authored-by: Karishma Chawla <kachawla@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken or not working as expected important This item is a high priority Issue we intend to address as soon as possible triaged This issue has been reviewed and triaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants