Skip to content

Update CLAUDE.md with environment setup instructions#26714

Open
harshach wants to merge 1 commit intomainfrom
fix/update-claude-md-env-setup
Open

Update CLAUDE.md with environment setup instructions#26714
harshach wants to merge 1 commit intomainfrom
fix/update-claude-md-env-setup

Conversation

@harshach
Copy link
Collaborator

Summary

  • Add Python virtual environment setup instructions (venv activation, worktree handling)
  • Add initial dev environment setup section (generate, install_dev_env, yarn)
  • Add Docker services, Java, and Node/Yarn environment notes
  • Fix Python version range (3.10-3.12 instead of 3.11+)

Test plan

  • Verify CLAUDE.md renders correctly on GitHub
  • Confirm venv instructions work in fresh worktree

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings March 24, 2026 07:23
@github-actions github-actions bot added backend safe to test Add this label to run secure Github workflows on PRs labels Mar 24, 2026
- **Backend**: Java 21 + Dropwizard REST API framework, multi-module Maven project
- **Frontend**: React + TypeScript, built with Webpack and Yarn; component library via `openmetadata-ui-core-components` (Tailwind CSS v4 with `tw:` prefix, react-aria-components foundation)
- **Ingestion**: Python 3.11+ with Pydantic 2.x, 75+ data source connectors
- **Ingestion**: Python 3.10-3.12 with Pydantic 2.x, 75+ data source connectors
Copy link

Choose a reason for hiding this comment

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

⚠️ Bug: Contradictory Python version requirements: 3.10-3.12 vs 3.11

The Architecture Overview (line 13) was updated to say "Python 3.10-3.12", but the new Environment Setup section (line 22) says "OpenMetadata requires Python 3.11", and the verify command (line 32) says "Should show Python 3.11.x". All the venv examples also hardcode python3.11. This is contradictory — either 3.10 and 3.12 are supported or they aren't. If the supported range is 3.10–3.12, the setup instructions should reflect that (e.g., python3.10 -m venv env should also work).

Suggested fix:

Pick one consistent statement. If 3.10-3.12 is the supported range, update line 22 to:
"OpenMetadata requires Python 3.10–3.12."
and update the verify comment to:
"# Should show Python 3.10.x, 3.11.x, or 3.12.x"
Or if 3.11 is the recommended version, clarify:
"OpenMetadata supports Python 3.10-3.12; 3.11 is recommended."

Was this helpful? React with 👍 / 👎 | Reply gitar fix to apply this suggestion

python --version # Should show Python 3.11.x
```

**In worktrees**: When claustre creates a worktree, the venv from the main repo is NOT copied. You need to either:
Copy link

Choose a reason for hiding this comment

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

💡 Quality: Typo: "claustre" should be "Claude Code" (or "claude")

Line 35 reads "When claustre creates a worktree" — this appears to be a typo for "Claude Code" or "Claude".

Suggested fix:

- **In worktrees**: When claustre creates a worktree, ...
+ **In worktrees**: When Claude Code creates a worktree, ...

Was this helpful? React with 👍 / 👎 | Reply gitar fix to apply this suggestion

**You MUST activate the Python venv before any Python work.** The system `python` command does not exist and system `python3` is too old (3.9). OpenMetadata requires Python 3.11.

```bash
# First-time setup (already done — venv exists at ~/Code/OpenMetadata/env):
Copy link

Choose a reason for hiding this comment

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

💡 Quality: Hardcoded user-specific path ~/Code/OpenMetadata/env

Lines 25 and 37 reference ~/Code/OpenMetadata/env, which is specific to the author's local machine layout. Since CLAUDE.md is checked into the repo and read by all contributors (and by Claude Code in any checkout location), this path will be wrong for most users. Use a repo-relative path instead.

Suggested fix:

Replace the absolute path with a relative reference:
- # First-time setup (already done — venv exists at ~/Code/OpenMetadata/env):
+ # First-time setup (creates venv at repo root):

- Or symlink the main repo's venv: `ln -s ~/Code/OpenMetadata/env env`
+ Or symlink the main repo's venv: `ln -s /path/to/main-repo/env env`

Was this helpful? React with 👍 / 👎 | Reply gitar fix to apply this suggestion

@gitar-bot
Copy link

gitar-bot bot commented Mar 24, 2026

Code Review ⚠️ Changes requested 0 resolved / 3 findings

Updates CLAUDE.md with environment setup instructions but contains contradictory Python version requirements (3.10-3.12 vs 3.11), a typo "claustre" instead of "Claude Code", and hardcoded user-specific paths that should be generalized for team use.

⚠️ Bug: Contradictory Python version requirements: 3.10-3.12 vs 3.11

📄 CLAUDE.md:13 📄 CLAUDE.md:22 📄 CLAUDE.md:32 📄 CLAUDE.md:36

The Architecture Overview (line 13) was updated to say "Python 3.10-3.12", but the new Environment Setup section (line 22) says "OpenMetadata requires Python 3.11", and the verify command (line 32) says "Should show Python 3.11.x". All the venv examples also hardcode python3.11. This is contradictory — either 3.10 and 3.12 are supported or they aren't. If the supported range is 3.10–3.12, the setup instructions should reflect that (e.g., python3.10 -m venv env should also work).

Suggested fix
Pick one consistent statement. If 3.10-3.12 is the supported range, update line 22 to:
"OpenMetadata requires Python 3.10–3.12."
and update the verify comment to:
"# Should show Python 3.10.x, 3.11.x, or 3.12.x"
Or if 3.11 is the recommended version, clarify:
"OpenMetadata supports Python 3.10-3.12; 3.11 is recommended."
💡 Quality: Typo: "claustre" should be "Claude Code" (or "claude")

📄 CLAUDE.md:35

Line 35 reads "When claustre creates a worktree" — this appears to be a typo for "Claude Code" or "Claude".

Suggested fix
- **In worktrees**: When claustre creates a worktree, ...
+ **In worktrees**: When Claude Code creates a worktree, ...
💡 Quality: Hardcoded user-specific path ~/Code/OpenMetadata/env

📄 CLAUDE.md:25 📄 CLAUDE.md:37

Lines 25 and 37 reference ~/Code/OpenMetadata/env, which is specific to the author's local machine layout. Since CLAUDE.md is checked into the repo and read by all contributors (and by Claude Code in any checkout location), this path will be wrong for most users. Use a repo-relative path instead.

Suggested fix
Replace the absolute path with a relative reference:
- # First-time setup (already done — venv exists at ~/Code/OpenMetadata/env):
+ # First-time setup (creates venv at repo root):

- Or symlink the main repo's venv: `ln -s ~/Code/OpenMetadata/env env`
+ Or symlink the main repo's venv: `ln -s /path/to/main-repo/env env`
🤖 Prompt for agents
Code Review: Updates CLAUDE.md with environment setup instructions but contains contradictory Python version requirements (3.10-3.12 vs 3.11), a typo "claustre" instead of "Claude Code", and hardcoded user-specific paths that should be generalized for team use.

1. ⚠️ Bug: Contradictory Python version requirements: 3.10-3.12 vs 3.11
   Files: CLAUDE.md:13, CLAUDE.md:22, CLAUDE.md:32, CLAUDE.md:36

   The Architecture Overview (line 13) was updated to say "Python 3.10-3.12", but the new Environment Setup section (line 22) says "OpenMetadata requires Python 3.11", and the verify command (line 32) says "Should show Python 3.11.x". All the venv examples also hardcode `python3.11`. This is contradictory — either 3.10 and 3.12 are supported or they aren't. If the supported range is 3.10–3.12, the setup instructions should reflect that (e.g., `python3.10 -m venv env` should also work).

   Suggested fix:
   Pick one consistent statement. If 3.10-3.12 is the supported range, update line 22 to:
   "OpenMetadata requires Python 3.10–3.12."
   and update the verify comment to:
   "# Should show Python 3.10.x, 3.11.x, or 3.12.x"
   Or if 3.11 is the recommended version, clarify:
   "OpenMetadata supports Python 3.10-3.12; 3.11 is recommended."

2. 💡 Quality: Typo: "claustre" should be "Claude Code" (or "claude")
   Files: CLAUDE.md:35

   Line 35 reads "When claustre creates a worktree" — this appears to be a typo for "Claude Code" or "Claude".

   Suggested fix:
   - **In worktrees**: When claustre creates a worktree, ...
   + **In worktrees**: When Claude Code creates a worktree, ...

3. 💡 Quality: Hardcoded user-specific path ~/Code/OpenMetadata/env
   Files: CLAUDE.md:25, CLAUDE.md:37

   Lines 25 and 37 reference `~/Code/OpenMetadata/env`, which is specific to the author's local machine layout. Since CLAUDE.md is checked into the repo and read by all contributors (and by Claude Code in any checkout location), this path will be wrong for most users. Use a repo-relative path instead.

   Suggested fix:
   Replace the absolute path with a relative reference:
   - # First-time setup (already done — venv exists at ~/Code/OpenMetadata/env):
   + # First-time setup (creates venv at repo root):
   
   - Or symlink the main repo's venv: `ln -s ~/Code/OpenMetadata/env env`
   + Or symlink the main repo's venv: `ln -s /path/to/main-repo/env env`

Options

Auto-apply is off → Gitar will not commit updates to this branch.
Display: compact → Showing less information.

Comment with these commands to change:

Auto-apply Compact
gitar auto-apply:on         
gitar display:verbose         

Was this helpful? React with 👍 / 👎 | Gitar

Copy link
Contributor

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

Updates CLAUDE.md to document local/devcontainer environment setup steps (Python venv, initial dependency installation, and Docker/Java/Node notes) for working on OpenMetadata.

Changes:

  • Updates stated Python version range for ingestion.
  • Adds a new “Environment Setup” section covering venv activation, worktrees, initial dependency installs, and Docker compose usage.
  • Adjusts the “Prerequisites and Setup” command list to include venv activation and ingestion install steps.

Comment on lines +75 to +76
make generate # Generate Pydantic models from JSON schemas
cd ingestion && make install_dev_env # Install Python dev dependencies
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

Same ordering issue in the “Prerequisites and Setup” block: make generate is listed before cd ingestion && make install_dev_env, but generate requires the dev install tooling first. Please reorder these commands to avoid a failing first-time setup.

Suggested change
make generate # Generate Pydantic models from JSON schemas
cd ingestion && make install_dev_env # Install Python dev dependencies
cd ingestion && make install_dev_env # Install Python dev dependencies
make generate # Generate Pydantic models from JSON schemas

Copilot uses AI. Check for mistakes.
- **Backend**: Java 21 + Dropwizard REST API framework, multi-module Maven project
- **Frontend**: React + TypeScript, built with Webpack and Yarn; component library via `openmetadata-ui-core-components` (Tailwind CSS v4 with `tw:` prefix, react-aria-components foundation)
- **Ingestion**: Python 3.11+ with Pydantic 2.x, 75+ data source connectors
- **Ingestion**: Python 3.10-3.12 with Pydantic 2.x, 75+ data source connectors
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

The docs now claim ingestion supports Python 3.10-3.12, but the repo’s test matrix and tooling only cover 3.10/3.11 (e.g., ingestion/noxfile.py SUPPORTED_PYTHON_VERSIONS and .github/workflows/py-tests.yml). Please align this line with the versions that are actually supported/tested, or update CI/tooling if 3.12 is intended to be supported.

Suggested change
- **Ingestion**: Python 3.10-3.12 with Pydantic 2.x, 75+ data source connectors
- **Ingestion**: Python 3.9-3.11 with Pydantic 2.x, 75+ data source connectors

Copilot uses AI. Check for mistakes.

### Python Virtual Environment (REQUIRED)

**You MUST activate the Python venv before any Python work.** The system `python` command does not exist and system `python3` is too old (3.9). OpenMetadata requires Python 3.11.
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

This paragraph makes environment-specific assertions (e.g., python doesn’t exist, python3 is 3.9, and “OpenMetadata requires Python 3.11”). In this repo, CI/dev tooling runs on Python 3.10/3.11 and ingestion/pyproject.toml only requires >=3.9, so these statements are misleading. Consider rewording to “use Python 3.10/3.11 (3.11 recommended)” and avoid claiming system interpreters are missing/too old.

Copilot uses AI. Check for mistakes.
Comment on lines +25 to +27
# First-time setup (already done — venv exists at ~/Code/OpenMetadata/env):
# python3.11 -m venv env

Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

The venv setup snippet is written as if a venv already exists at a specific personal path (~/Code/OpenMetadata/env). Since this file lives in-repo, please avoid hard-coded home-directory paths and “already done” notes; use a repo-relative path (./env) or describe it generically so it works for all environments.

Copilot uses AI. Check for mistakes.
python --version # Should show Python 3.11.x
```

**In worktrees**: When claustre creates a worktree, the venv from the main repo is NOT copied. You need to either:
Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

The phrase “When claustre creates a worktree” is unclear (and “claustre” doesn’t appear elsewhere in the repo). Please clarify what tool/process this refers to (e.g., git worktree or Claude Code creating a worktree) so readers know when this guidance applies.

Suggested change
**In worktrees**: When claustre creates a worktree, the venv from the main repo is NOT copied. You need to either:
**In worktrees**: When Claude Code creates a Git worktree for this repository, the venv from the main repo is NOT copied. You need to either:

Copilot uses AI. Check for mistakes.
Comment on lines +35 to +38
**In worktrees**: When claustre creates a worktree, the venv from the main repo is NOT copied. You need to either:
- Create a new venv in the worktree: `python3.11 -m venv env && source env/bin/activate && cd ingestion && make install_dev`
- Or symlink the main repo's venv: `ln -s ~/Code/OpenMetadata/env env`

Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

The worktree symlink example hard-codes a local path (~/Code/OpenMetadata/env), which won’t work for most checkouts. Consider describing this as “symlink to the main repo’s env directory” and using a relative path example (or a placeholder path) so it’s portable.

Copilot uses AI. Check for mistakes.
Comment on lines +46 to +55
# Generate Pydantic models from JSON schemas (required after schema changes)
make generate

# Install ingestion module with all dev dependencies
cd ingestion
make install_dev_env # Full dev environment (edit mode + all extras)
# OR for lighter install:
make install_dev # Just dev dependencies
cd ..

Copy link

Copilot AI Mar 24, 2026

Choose a reason for hiding this comment

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

The initial setup runs make generate before installing the Python dev dependencies. The root Makefile’s generate target explicitly warns to run install_dev first, and make generate depends on Python tooling installed by the dev install. Please swap the order (install first, then generate) or use the existing make install_dev generate flow.

Suggested change
# Generate Pydantic models from JSON schemas (required after schema changes)
make generate
# Install ingestion module with all dev dependencies
cd ingestion
make install_dev_env # Full dev environment (edit mode + all extras)
# OR for lighter install:
make install_dev # Just dev dependencies
cd ..
# Install ingestion module with all dev dependencies (required before make generate)
cd ingestion
make install_dev_env # Full dev environment (edit mode + all extras)
# OR for lighter install:
make install_dev # Just dev dependencies
cd ..
# Generate Pydantic models from JSON schemas (required after schema changes)
make generate

Copilot uses AI. Check for mistakes.
@github-actions
Copy link
Contributor

🟡 Playwright Results — all passed (17 flaky)

✅ 3113 passed · ❌ 0 failed · 🟡 17 flaky · ⏭️ 207 skipped

Shard Passed Failed Flaky Skipped
🟡 Shard 1 451 0 4 2
🟡 Shard 2 541 0 5 33
🟡 Shard 3 543 0 3 27
🟡 Shard 4 537 0 1 45
✅ Shard 5 511 0 0 67
🟡 Shard 6 530 0 4 33
🟡 17 flaky test(s) (passed on retry)
  • Features/DataAssetRulesDisabled.spec.ts › Verify the Store Procedure entity item action after rules disabled (shard 1, 1 retry)
  • Flow/Tour.spec.ts › Tour should work from help section (shard 1, 1 retry)
  • Flow/Tour.spec.ts › Tour should work from URL directly (shard 1, 2 retries)
  • Pages/UserCreationWithPersona.spec.ts › Create user with persona and verify on profile (shard 1, 1 retry)
  • Features/BulkImport.spec.ts › Database (shard 2, 1 retry)
  • Features/DataQuality/TestCaseImportExportE2eFlow.spec.ts › EditAll User: Complete export-import-validate flow (shard 2, 1 retry)
  • Features/DataQuality/TestCaseIncidentPermissions.spec.ts › User with TEST_CASE.EDIT_ALL can see edit icon on incidents (shard 2, 1 retry)
  • Features/DataQuality/TestCaseResultPermissions.spec.ts › User with TEST_CASE.EDIT_ALL can see edit action on test case (shard 2, 1 retry)
  • Features/Glossary/GlossaryHierarchy.spec.ts › should cancel move operation (shard 2, 1 retry)
  • Features/Permissions/GlossaryPermissions.spec.ts › Team-based permissions work correctly (shard 3, 1 retry)
  • Features/TableSorting.spec.ts › Topics Table should have sorting on name column (shard 3, 1 retry)
  • Pages/Customproperties-part2.spec.ts › entityReferenceList shows item count, scrollable list, no expand toggle (shard 3, 1 retry)
  • Pages/DomainDataProductsRightPanel.spec.ts › Should assign tier for data product from domain context (shard 4, 1 retry)
  • Pages/Lineage.spec.ts › Lineage creation from Topic entity (shard 6, 1 retry)
  • Pages/ODCSImportExport.spec.ts › Multi-object ODCS contract - object selector shows all schema objects (shard 6, 1 retry)
  • Pages/ServiceEntity.spec.ts › Delete Pipeline Service (shard 6, 1 retry)
  • Pages/Users.spec.ts › Permissions for table details page for Data Consumer (shard 6, 1 retry)

📦 Download artifacts

How to debug locally
# Download playwright-test-results-<shard> artifact and unzip
npx playwright show-trace path/to/trace.zip    # view trace

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backend safe to test Add this label to run secure Github workflows on PRs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants