iOS example failing using Bazel version 1.1.0
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 30/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Stale
- Tech stack
- ios
- Domain
- build-system, mobile
Research direction
Start with the iOS tutorial and ios-app/BUILD, then reproduce bazel build //ios-app:ios-app using the reported Bazel version and the deprecated-attribute flag. Compare the example's objc_library and apple_binary attributes with the current rules, and consider the work done when the documented command builds successfully with supported attributes.
Written by the indexing model from the issue text.
Description
Hello,
Using Bazel version 1.1.0 installed using Homebrew and following the steps on the documentation https://docs.bazel.build/versions/master/tutorial/ios-app.html, I got the following error trying to build the iOS project :
➜ tutorial git:(source-only) ✗ bazel build //ios-app:ios-app
INFO: Writing tracer profile to '/private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/command.profile.gz'
ERROR: /private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/bundling/entitlements.bzl:300:25: Traceback (most recent call last):
File "/private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/bundling/entitlements.bzl", line 294
rule(<3 more arguments>)
File "/private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/bundling/entitlements.bzl", line 300, in rule
attr.label(<2 more arguments>)
'single_file' is no longer supported. use allow_single_file instead. You can use --incompatible_disable_deprecated_attr_params=false to temporarily disable this check.
ERROR: Skipping '//ios-app:ios-app': error loading package 'ios-app': in /private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/ios.bzl: in /private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/bundling/binary_support.bzl: Extension file 'apple/bundling/entitlements.bzl' has errors
WARNING: Target pattern parsing failed.
ERROR: error loading package 'ios-app': in /private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/ios.bzl: in /private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/external/build_bazel_rules_apple/apple/bundling/binary_support.bzl: Extension file 'apple/bundling/entitlements.bzl' has errors
INFO: Elapsed time: 0.163s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (1 packages loaded)
With --incompatible_disable_deprecated_attr_params=false I'm getting another error :
➜ tutorial git:(source-only) ✗ bazel build --incompatible_disable_deprecated_attr_params=false //ios-app:ios-app
INFO: Writing tracer profile to '/private/var/tmp/_bazel_mmosbah/50a095adb6c59f331d9d5d198a21d596/command.profile.gz'
ERROR: /Users/user_name/examples/tutorial/ios-app/BUILD:2:1: //ios-app:UrlGetClasses: no such attribute 'xibs' in 'objc_library' rule
ERROR: /Users/user_name/examples/tutorial/ios-app/BUILD:13:1: //ios-app:ios-app.apple_binary: no such attribute 'non_propagated_deps' in 'apple_binary' rule
ERROR: error loading package 'ios-app': Package 'ios-app' contains errors
INFO: Elapsed time: 0.156s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (1 packages loaded)
If i understand correctly the example project is not up to date with the latest version ?
What's the new equivalent of non_propagated_deps ?
Thanks !
- Dominant language
- Starlark
- Stars
- 957
- Forks
- 578
- Avg merge
- 2d 10h
- Merged PRs (30d)
- 2
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from bazelbuild/examples
-
Difficulty 4/5 3-5 days Newbie friendliness 45/100
bazelbuild/examples#706 · 2 comments ·
-
Difficulty 4/5 3-5 days Newbie friendliness 30/100
bazelbuild/examples#650 · 1 comment ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
bazelbuild/examples#642 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 30/100
bazelbuild/examples#641 · 1 reaction ·
-
Difficulty 3/5 1-2 days Newbie friendliness 38/100
bazelbuild/examples#634 · 2 comments ·
All issues in bazelbuild/examples
Similar issues
-
type/automation type/tech-debt
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
priority: p3
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
googleapis/librarian#7636 ·
-
package-update
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
oSoWoSo/vOid_Community_repOsitory#147 · 1 comment ·
-
bug
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
-
agentic-workflows cascade-suspected
Difficulty 1/5 Under an hour Newbie friendliness 88/100