Skip to content

Conversation

@parthea
Copy link
Contributor

@parthea parthea commented Oct 30, 2025

This PR fixes an issue where generation fails for libraries when /input/packages/google-cloud-<api> does not exist.

Traceback (most recent call last):
  File "/app/./cli.py", line 620, in handle_generate
    _copy_files_needed_for_post_processing(output, input, library_id, is_mono_repo)
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/app/./cli.py", line 372, in _copy_files_needed_for_post_processing
    shutil.copytree(
    ~~~~~~~~~~~~~~~^
        source_dir,
        ^^^^^^^^^^^
    ...<2 lines>...
        ignore=shutil.ignore_patterns("client-post-processing"),
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    )
    ^
  File "/usr/local/lib/python3.14/shutil.py", line 652, in copytree
    with os.scandir(src) as itr:
         ~~~~~~~~~~^^^^^
FileNotFoundError: [Errno 2] No such file or directory: '/input/packages/google-cloud-hypercomputecluster'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/app/./cli.py", line 1582, in <module>
    args.func(
    ~~~~~~~~~^
        librarian=args.librarian,
        ^^^^^^^^^^^^^^^^^^^^^^^^^
    ...<2 lines>...
        input=args.input,
        ^^^^^^^^^^^^^^^^^
    )
    ^
  File "/app/./cli.py", line 628, in handle_generate
    raise ValueError("Generation failed.") from e
ValueError: Generation failed.

@parthea parthea requested review from a team as code owners October 30, 2025 21:45
@ohmayr ohmayr merged commit 22b9640 into main Oct 30, 2025
25 checks passed
@ohmayr ohmayr deleted the fix-generate-issue branch October 30, 2025 21:52
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.

2 participants