Skip to content

Commit 7094bce

Browse files
danielkovclaude
andcommitted
chore: remove debug logging
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent f1831d4 commit 7094bce

File tree

3 files changed

+1
-46
lines changed

3 files changed

+1
-46
lines changed

internal/actions/release.go

Lines changed: 1 addition & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,10 @@ import (
1818
)
1919

2020
func Release() error {
21-
fmt.Println("RELEASE_ACTION_VERSION: pypi-trusted-publishing-debug-v2")
22-
2321
accessToken := environment.GetAccessToken()
2422
if accessToken == "" {
2523
return errors.New("github access token is required")
2624
}
27-
fmt.Println("INPUT_ENABLE_SDK_CHANGELOG: ", environment.GetSDKChangelog())
2825

2926
g, err := initAction()
3027
if err != nil {
@@ -152,18 +149,12 @@ func GetDirAndShouldUseReleasesMD(files []string, dir string, usingReleasesMd bo
152149
}
153150

154151
func addPublishOutputs(dir string, outputs map[string]string) error {
155-
fmt.Printf("DEBUG: addPublishOutputs called with dir=%s\n", dir)
156-
157152
wf, err := configuration.GetWorkflowAndValidateLanguages(false)
158153
if err != nil {
159154
return err
160155
}
161156

162-
fmt.Printf("DEBUG: Found %d targets in workflow\n", len(wf.Targets))
163-
164-
for targetID, target := range wf.Targets {
165-
logging.Info("DEBUG: Checking target %s (lang=%s)", targetID, target.Target)
166-
157+
for _, target := range wf.Targets {
167158
// Only add outputs for the target that was regenerated, based on output directory
168159
if dir != "." && target.Output != nil {
169160
output, err := filepath.Rel(".", *target.Output)
@@ -175,30 +166,11 @@ func addPublishOutputs(dir string, outputs map[string]string) error {
175166
output = filepath.Join(environment.GetWorkingDirectory(), output)
176167
}
177168

178-
logging.Info("DEBUG: dir=%s, output=%s", dir, output)
179169
if output != dir {
180-
logging.Info("DEBUG: Skipping target %s because output doesn't match dir", targetID)
181170
continue
182171
}
183172
}
184173

185-
// Debug: Print publishing config
186-
logging.Info("DEBUG: Processing target %s", target.Target)
187-
if target.Publishing != nil {
188-
logging.Info("DEBUG: Publishing config found for %s", target.Target)
189-
if target.Publishing.PyPi != nil {
190-
if target.Publishing.PyPi.UseTrustedPublishing != nil {
191-
logging.Info("DEBUG: PyPi.UseTrustedPublishing=%v", *target.Publishing.PyPi.UseTrustedPublishing)
192-
} else {
193-
logging.Info("DEBUG: PyPi.UseTrustedPublishing is nil")
194-
}
195-
} else {
196-
logging.Info("DEBUG: PyPi config is nil")
197-
}
198-
} else {
199-
logging.Info("DEBUG: Publishing config is nil for %s", target.Target)
200-
}
201-
202174
run.AddTargetPublishOutputs(target, outputs, nil)
203175
}
204176

internal/run/run.go

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -117,18 +117,6 @@ func Run(g Git, pr *github.PullRequest, wf *workflow.Workflow) (*RunResult, map[
117117

118118
fmt.Printf("Generating %s SDK in %s\n", lang, outputDir)
119119

120-
// Debug: Print publishing config
121-
if target.Publishing != nil {
122-
fmt.Printf("DEBUG: Publishing config found for %s\n", lang)
123-
if target.Publishing.PyPi != nil {
124-
fmt.Printf("DEBUG: PyPi config found, UseTrustedPublishing=%v\n", target.Publishing.PyPi.UseTrustedPublishing)
125-
} else {
126-
fmt.Printf("DEBUG: PyPi config is nil\n")
127-
}
128-
} else {
129-
fmt.Printf("DEBUG: Publishing config is nil for %s\n", lang)
130-
}
131-
132120
installationURL := getInstallationURL(lang, dir)
133121

134122
AddTargetPublishOutputs(target, outputs, &installationURL)

main.go

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,6 @@ import (
1515
)
1616

1717
func main() {
18-
fmt.Fprintln(os.Stderr, "ACTION_BINARY_VERSION: pypi-trusted-v4-stderr")
19-
fmt.Fprintf(os.Stderr, "INPUT_ACTION=%s\n", os.Getenv("INPUT_ACTION"))
20-
os.Stdout.Sync()
21-
os.Stderr.Sync()
22-
2318
if environment.IsDebugMode() {
2419
envs := os.Environ()
2520
slices.SortFunc(envs, func(i, j string) int {

0 commit comments

Comments
 (0)