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

logstash-output-opensearch/2.0.3 package update #33203

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

octo-sts[bot]
Copy link
Contributor

@octo-sts octo-sts bot commented Nov 4, 2024

@octo-sts octo-sts bot added request-version-update request for a newer version of a package automated pr labels Nov 4, 2024
Copy link
Contributor Author

octo-sts bot commented Nov 4, 2024

Gen AI suggestions to solve the build error:

Based on the error log, the issue appears to be with the gemspec file syntax. Here are the steps to fix this:

  1. First, check and fix the gemspec syntax error:
# The error is in logstash-output-opensearch.gemspec line 53
# Shows unexpected `end` token
  1. Proposed fixes:

a. Check the gemspec file for proper Ruby syntax:

# Open logstash-output-opensearch.gemspec
# Look for mismatched do/end blocks
# Ensure proper nesting of blocks
# Check for extra/missing end statements around line 53

b. Create a temporary fix in the melange YAML:

pipeline:
  - uses: git-checkout
    with:
      repository: https://github.com/opensearch-project/logstash-output-opensearch
      tag: 2.0.3
      
  - runs: |
      # Add gemspec validation step
      sed -i '53d' logstash-output-opensearch.gemspec  # Remove problematic line
      # Or fix the syntax directly
    
  - uses: ruby/build
  1. Additional debugging steps:
# Validate gemspec independently
gem build logstash-output-opensearch.gemspec

# Check Ruby syntax
ruby -c logstash-output-opensearch.gemspec

# Add verbose output to melange build
make MELANGE_EXTRA_OPTS="--create-build-log --cache-dir=.melangecache -v" REPO="./packages" package/logstash-output-opensearch
  1. Consider adding a patch:
pipeline:
  - uses: patch
    with:
      patches: patches/fix-gemspec-syntax.patch
  1. Create a temporary workaround in your melange.yaml:
environment:
  SKIP_GEMSPEC_VALIDATION: "1"

These steps should help resolve the gemspec syntax error and allow the build to proceed.

Signed-off-by: Jason Hall <[email protected]>
@imjasonh imjasonh enabled auto-merge (squash) November 17, 2024 03:29
imjasonh
imjasonh previously approved these changes Nov 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automated pr request-version-update request for a newer version of a package
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants