-
Notifications
You must be signed in to change notification settings - Fork 184
Open
Labels
Description
Feature scope
CLI (options, error messages, logging, etc.)
Description
Any time a non-administrator user runs any meltano command on Windows, the warning below appears.
2025-01-21T17:44:43.696439Z [warning ] Failed to create symlink to 'meltano.exe': administrator privilege required
meltano/src/meltano/core/project.py
Lines 209 to 226 in 82ff2fb
try: | |
# check if running on Windows | |
if os.name == "nt": | |
executable = Path(sys.executable).parent / "meltano.exe" | |
# Admin privileges are required to create symlinks on Windows | |
if ctypes.windll.shell32.IsUserAnAdmin(): # type: ignore[attr-defined] | |
if executable.is_file(): | |
project.run_dir().joinpath("bin").symlink_to(executable) | |
else: | |
logger.warning( | |
"Could not create symlink: meltano.exe not " # noqa: G004 | |
f"present in {Path(sys.executable).parent!s}", | |
) | |
else: | |
logger.warning( | |
"Failed to create symlink to 'meltano.exe': " | |
"administrator privilege required", | |
) |
In my experience, the inability to create the symlink does not affect the users ability to use the meltano CLI. It would be nice to limit how this is shown because it implies there are a serious issue but provides no resolution steps.
Possible solutions:
- Set it to log at DEBUG instead of WARNING
- Provide a config to suppress the warning that is referenced in the warning
- Other?
chadcampling-opteon
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
To Discuss