Skip to content

Conversation

@onno-vos-dev
Copy link
Member

Fixes aws-beam/aws-elixir#198

Await for verification from reporter before merging

@onno-vos-dev onno-vos-dev requested a review from Copilot August 1, 2025 12:24

This comment was marked as outdated.

@onno-vos-dev onno-vos-dev force-pushed the add-atom-to-elixir-type-specs branch from 1cedcd1 to 7a46377 Compare August 1, 2025 12:26
@onno-vos-dev onno-vos-dev requested a review from Copilot August 1, 2025 12:26

This comment was marked as outdated.

@onno-vos-dev onno-vos-dev requested a review from Copilot August 1, 2025 12:30
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR updates the AWS Elixir code generator to accept both String.t() and Atom.t() types in generated type specifications, addressing issue #198. The change makes the generated types more flexible by allowing either strings or atoms as map keys and string parameters.

  • Updates all string type specifications to union types that accept both String.t() and Atom.t()
  • Modifies code generation templates to output the new union types
  • Updates test expectations to reflect the new type specifications

Reviewed Changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 3 comments.

File Description
lib/aws_codegen/types.ex Core type generation logic updated to emit String.t() | Atom.t() union types
priv/rest.ex.eex REST API template updated to generate union types for map keys
priv/post.ex.eex POST API template updated to generate union types for map keys
test/aws_codegen_test.exs Test expectations updated to match new union type specifications

@onno-vos-dev onno-vos-dev force-pushed the add-atom-to-elixir-type-specs branch from 591d76e to 1c41051 Compare August 1, 2025 13:06
@onno-vos-dev onno-vos-dev force-pushed the add-atom-to-elixir-type-specs branch from 1c41051 to f617eb0 Compare August 1, 2025 13:54
Copy link

@grant-zukowski-xumo grant-zukowski-xumo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I checked this with our local tool and all the calls work fine.

@onno-vos-dev onno-vos-dev merged commit 97298fd into master Aug 6, 2025
3 checks passed
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.

New spec is specific to keys in requests being strings

3 participants