pulumi / pulumi/pulumi-java

[programgen] unify import naming logic between sdk-gen and program-gen

Open
#611 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area/codegen kind/enhancement language/java size/S
Dominant language
Java
Stars
85
Forks
26
Avg merge
11h 49m
Merged PRs (30d)
22

Description

Issue details

In #596 we collect type imports from used types (resources, args, functions etc.) and emit them at the beginning of the file. The logic for generating an import statement out of a schema.Type is very simple but is not exactly done the same way that sdk-gen does using import maps. It would be great to use the same logic for both purposes so that changing the sdk-gen doesn't result in out-of-sync programs

Affected area/feature

Programgen

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the sdk-gen import-map logic and the program-gen logic that turns schema.Type values into import statements, following the type-import work from #596. The change is done when both generators use the same naming logic and generated programs remain in sync with sdk-gen imports.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
tooling
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.