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

fix(build): uname handling for mac M1 arch. Fixes #13112 #13113

Merged
merged 5 commits into from
Jun 5, 2024

Conversation

Adrien-D
Copy link
Member

Fixes #13112

Motivation

Unable to build the project using make start UI=true, and fails because of my M1 arch

Modifications

I updated the TARGET_PLATFORM value on the Makefile to be able to also handle my arch value which is aarch64

Verification

image

Signed-off-by: Adrien Delannoy <a.delannoyfr@gmail.com>
@agilgur5 agilgur5 changed the title fix: Target platform uname handling for mac M1 arch. Fixes #13112 fix(build): uname handling for mac M1 arch. Fixes #13112 May 29, 2024
@agilgur5 agilgur5 added area/build Build or GithubAction/CI issues area/contributing Contributing docs, ownership, etc. Also devtools like devcontainer and Nix labels May 29, 2024
@agilgur5
Copy link
Contributor

Follow-up to #12754

Makefile Outdated Show resolved Hide resolved
Signed-off-by: Adrien Delannoy <a.delannoyfr@gmail.com>
Signed-off-by: Adrien Delannoy <a.delannoyfr@gmail.com>
@Adrien-D
Copy link
Member Author

Adrien-D commented Jun 5, 2024

@agilgur5 I implemented your last option as it looks way nicer

Also I was facing an issue running make pre-commit -B described here , so I implemented the recommended fix

vscode ➜ ~/go/src/github.com/argoproj/argo-workflows (fix-make-mac-m1) $ mkdocs build --strict
Traceback (most recent call last):
  File "/home/vscode/.local/bin/mkdocs", line 8, in <module>
    sys.exit(cli())
  File "/home/vscode/.local/lib/python3.10/site-packages/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
  File "/home/vscode/.local/lib/python3.10/site-packages/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
  File "/home/vscode/.local/lib/python3.10/site-packages/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/vscode/.local/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/vscode/.local/lib/python3.10/site-packages/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
  File "/home/vscode/.local/lib/python3.10/site-packages/mkdocs/__main__.py", line 281, in build_command
    cfg = config.load_config(**kwargs)
  File "/home/vscode/.local/lib/python3.10/site-packages/mkdocs/config/base.py", line 362, in load_config
    from mkdocs.config.defaults import MkDocsConfig
  File "/home/vscode/.local/lib/python3.10/site-packages/mkdocs/config/defaults.py", line 7, in <module>
    from mkdocs.config import config_options as c
  File "/home/vscode/.local/lib/python3.10/site-packages/mkdocs/config/config_options.py", line 36, in <module>
    from mkdocs import plugins, theme, utils
  File "/home/vscode/.local/lib/python3.10/site-packages/mkdocs/theme.py", line 16, in <module>
    from mkdocs import localization, utils
  File "/home/vscode/.local/lib/python3.10/site-packages/mkdocs/localization.py", line 16, in <module>
    from babel.support import NullTranslations, Translations
  File "/home/vscode/.local/lib/python3.10/site-packages/babel/support.py", line 23, in <module>
    from babel.dates import format_date, format_datetime, format_time, format_timedelta
  File "/home/vscode/.local/lib/python3.10/site-packages/babel/dates.py", line 34, in <module>
    from babel import localtime
  File "/home/vscode/.local/lib/python3.10/site-packages/babel/localtime/__init__.py", line 41, in <module>
    LOCALTZ = get_localzone()
  File "/home/vscode/.local/lib/python3.10/site-packages/babel/localtime/__init__.py", line 37, in get_localzone
    return _get_localzone()
  File "/home/vscode/.local/lib/python3.10/site-packages/babel/localtime/_unix.py", line 49, in _get_localzone
    tzinfo = _get_tzinfo(zone_name)
  File "/home/vscode/.local/lib/python3.10/site-packages/babel/localtime/_helpers.py", line 21, in _get_tzinfo
    return zoneinfo.ZoneInfo(tzenv)
  File "/usr/lib/python3.10/zoneinfo/_tzpath.py", line 67, in find_tzfile
    _validate_tzfile_path(key)
  File "/usr/lib/python3.10/zoneinfo/_tzpath.py", line 81, in _validate_tzfile_path
    raise ValueError(
ValueError: ZoneInfo keys may not be absolute paths, got: /UTC

@agilgur5
Copy link
Contributor

agilgur5 commented Jun 5, 2024

Yea I got the ZoneInfo error recently too and upvoted that workaround earlier 😅 -- there's almost certainly some dep somewhere causing that (which would not be the first time I've had a random TZ build error pop up in Python due to deps). I do have a branch to add a Poetry config and poetry.lock to the repo that may help prevent such a thing.

Copy link
Contributor

@agilgur5 agilgur5 left a comment

Choose a reason for hiding this comment

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

LGTM now, thanks for the fixes

@agilgur5 agilgur5 enabled auto-merge (squash) June 5, 2024 17:12
@agilgur5
Copy link
Contributor

agilgur5 commented Jun 5, 2024

Ah hitting the DCO issue dcoapp/app#211; it was just resolved, needs a new commit to re-trigger

Signed-off-by: Anton Gilgur <agilgur5@gmail.com>
@agilgur5 agilgur5 merged commit 58dbcd0 into argoproj:main Jun 5, 2024
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/build Build or GithubAction/CI issues area/contributing Contributing docs, ownership, etc. Also devtools like devcontainer and Nix
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to run Controller locally on Arm mac M1
2 participants