[Bug]: Same environment names with different project names
- Dominant language
- Java
- Stars
- 1.5k
- Forks
- 476
- Avg merge
- 18h 32m
- Merged PRs (30d)
- 216
Description
### Apache Hop version?
2.17.0-SNAPSHOT
### Java version?
docker image from official repo
### Operating system
Windows
### What happened?
With the 2.17.0 version, the environement name is correctly filtered by project name. But if we have the same environement name on wo different project, the two environments are added at the default project.
With this conf
```
{
"projectsConfig" : {
"lifecycleEnvironments" : [
{
"name" : "DEFAULT - LOCAL",
"purpose" : "Development",
"projectName" : "default",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/local/env-variables.json"
]
},
{
"name" : "DEFAULT - STAGING",
"purpose" : "Staging",
"projectName" : "default",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/staging/env-variables.json"
]
},
{
"name" : "DEFAULT-PROD",
"purpose" : "Production",
"projectName" : "default",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/production/env-variables.json"
]
},
{
"name" : "AD-LOCAL",
"purpose" : "Development",
"projectName" : "ad",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/local/env-variables.json"
]
},
{
"name" : "AD-STAGING",
"purpose" : "Staging",
"projectName" : "ad",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/staging/env-variables.json"
]
},
{
"name" : "AD-PROD",
"purpose" : "Production",
"projectName" : "ad",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/production/env-variables.json"
]
}
]
}
}
```
With this conf
```
{
"projectsConfig" : {
"lifecycleEnvironments" : [
{
"name" : "LOCAL",
"purpose" : "Development",
"projectName" : "default",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/local/env-variables.json"
]
},
{
"name" : "STAGING",
"purpose" : "Staging",
"projectName" : "default",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/staging/env-variables.json"
]
},
{
"name" : "PROD",
"purpose" : "Production",
"projectName" : "default",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/production/env-variables.json"
]
},
{
"name" : "LOCAL",
"purpose" : "Development",
"projectName" : "ad",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/local/env-variables.json"
]
},
{
"name" : "STAGING",
"purpose" : "Staging",
"projectName" : "ad",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/staging/env-variables.json"
]
},
{
"name" : "PROD",
"purpose" : "Production",
"projectName" : "ad",
"configurationFiles" : [
"${HOP_CONFIG_FOLDER}/environments/production/env-variables.json"
]
}
]
}
}
```
### Issue Priority
Priority: 2
### Issue Component
Component: Hop Gui
Contributor guide
Research direction
Start in the Hop GUI by reproducing the two lifecycle-environment configurations shown in the issue, focusing on how environments are filtered by projectName. Trace the environment-loading or project-selection entry point and verify that identical environment names remain associated with their respective projects; add or update a regression test if the relevant test area is found.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100