iOS 27.2 beta:面向开发者的新变化,逐个beta解读
Apple于2026年9月16日(星期三)开启了27.2周期,距iOS 27.0发布仅两天:iOS和iPadOS 27.2 beta(24B5084k),配套的macOS、tvOS、visionOS和watchOS beta,以及Xcode 27.2 beta(27B5019j);第二个beta于9月21日(星期一)跟进(iOS 27.2 beta 2,24B5089g)。 iOS的发行说明很短,只有一项功能,即面向欧盟用户的扩展版App Tracking Transparency提示;Xcode的发行说明则带来了大多数开发者最先感受到的变化,一种JSON项目格式,外加一个部署目标bug和一个附有变通办法的代码补全崩溃;而且说明明确指出,iPhone Duo SDK不在27.2里。本文逐个beta解读这些说明,每出一个新beta就会补充一次。1235
TL;DR
- 构建版本。 iOS和iPadOS 27.2 beta为9月16日的24B5084k,beta 2为9月21日的24B5089g;同一天还有macOS 27.2 beta 2(26B5091g)、tvOS(24K5093g)、visionOS(24N5093f)和watchOS(24S5091f);Xcode 27.2 beta为9月16日的27B5019j,截至9月26日还没有第二个Xcode beta。1
- iOS只有一项功能。 “
AppTrackingTransparency(ATT) now supports an alternative expanded prompt and re-prompting on a yearly basis for EU users. The alternative prompt is required for users in France, Germany, Italy, Poland, and Romania.”(ATT现在支持面向欧盟用户的另一种扩展提示,以及按年重新提示;法国、德国、意大利、波兰和罗马尼亚的用户必须使用这种替代提示)iOS说明的其余部分是三项StoreKit Testing修复、一项StoreKit Testing已知问题、一项Health已知问题和一项Shortcuts已知问题。没有弃用,也没有链接到27.2后的行为变更。2 - 真正要紧的Xcode变化。 “Xcode now supports a JSON-based project format (.xcproj) that’s more readable, merge-friendly, and easier for coding agents to edit. Enable it in the file inspector. Projects using .xcproj also open in earlier versions of Xcode 27.”(Xcode现在支持一种基于JSON的项目格式(.xcproj),更易读、更便于合并,也更便于编码智能体编辑。在文件检查器中启用。使用.xcproj的项目也能在更早的Xcode 27版本中打开)3
- Xcode的两个陷阱。 27.2中的macOS、watchOS、tvOS和visionOS SDK会“incorrectly report 27.1 as a valid deployment target”(错误地把27.1报告为有效的部署目标),而Xcode“may crash when using code completion on macOS 27.2 beta”(在macOS 27.2 beta上使用代码补全时可能崩溃),并附有一个
defaults write变通办法。3 - 27.2里没有的东西。 iPhone Duo的SDK和模拟器:“Download Xcode 27.1 beta to get the iOS SDK and simulator support for iPhone Duo”(下载Xcode 27.1 beta以获得支持iPhone Duo的iOS SDK和模拟器),Apple的新闻稿也说,这款手机将于10月23日搭载iOS 27.1上市。35
哪个构建版本对应哪一项?
| 项目 | 构建版本 | 订阅源日期 |
|---|---|---|
| iOS 27.2 beta / iPadOS 27.2 beta | 24B5084k | 2026年9月16日(星期三) |
| macOS 27.2 beta | 26B5086k | 2026年9月16日(星期三) |
| tvOS 27.2 beta | 24K5088l | 2026年9月16日(星期三) |
| visionOS 27.2 beta | 24N5088l | 2026年9月16日(星期三) |
| watchOS 27.2 beta | 24S5086l | 2026年9月16日(星期三) |
| Xcode 27.2 beta | 27B5019j | 2026年9月16日(星期三) |
| iOS 27.2 beta 2 / iPadOS 27.2 beta 2 | 24B5089g | 2026年9月21日(星期一) |
| macOS 27.2 beta 2 | 26B5091g | 2026年9月21日(星期一) |
| tvOS 27.2 beta 2 | 24K5093g | 2026年9月21日(星期一) |
| visionOS 27.2 beta 2 | 24N5093f | 2026年9月21日(星期一) |
| watchOS 27.2 beta 2 | 24S5091f | 2026年9月21日(星期一) |
| Xcode 27.1 beta(Duo SDK) | 27A9269 | 2026年9月18日(星期五) |
顺序本身就说明了问题。Apple在还没有任何27.1 beta的时候就先发了27.2 beta,两天后才推出Xcode 27.1 beta,作为承载iPhone Duo的版本;时间线见Xcode 27一文,上手实测见Duo模拟器一文。截至9月26日,Apple的发行说明索引里仍然没有iOS 27.1的页面,只有“iOS & iPadOS 27 Release Notes”和“iOS & iPadOS 27.2 Beta 2 Release Notes”。12
iOS 27.2 beta的发行说明写了什么?
页面开头是说明范围的一句话:“The iOS & iPadOS 27.2 SDK provides support to develop apps for iPhone and iPad running iOS & iPadOS 27.2 beta 2. The SDK comes bundled with Xcode 27.2,”(iOS & iPadOS 27.2 SDK支持为运行iOS & iPadOS 27.2 beta 2的iPhone和iPad开发应用,并随Xcode 27.2一起提供)随后分四个领域展开。2
App Tracking Transparency。 唯一的新功能:“AppTrackingTransparency (ATT) now supports an alternative expanded prompt and re-prompting on a yearly basis for EU users. The alternative prompt is required for users in France, Germany, Italy, Poland, and Romania.”(面向欧盟的替代扩展提示与按年重新提示,并在五个国家强制使用)这条说明没有点出任何API。我的欧盟跟踪提示一文从头文件和参考页面中读出了说明没写的部分:新的requestTrackingAuthorization重载,它让欧盟其余国家也能用上扩展表单;以及“Additional Information”按钮,它会在不记录决定的情况下关闭提示。那篇文章还在beta模拟器上跑了探测:在第一个beta的运行时上,每一次弹出提示的运行显示的都是标准警告框,从未出现过表单。表单本身需要真机测试,设备须位于欧盟境内,并登录欧盟地区的Apple Account。
StoreKit Testing in Xcode。 有两个条目从27.0说明的Known Issues移到了Resolved:“Changing the storefront or locale using SKTestSession doesn’t propagate through Storefront.updates,”(用SKTestSession更改店面或区域设置不会通过Storefront.updates传递)以及“Failed purchases using SKTestSession might display error dialogs even when dialogsDisabled is set to true.”(即使dialogsDisabled设为true,SKTestSession中的失败购买仍可能弹出错误对话框)第三个Resolved条目“Intro offer eligibility does not reset immediately after calling SKTestSession.clearTransactions(),”(调用SKTestSession.clearTransactions()后,推介优惠资格不会立即重置)重复了27.0说明中已经列出的一项修复。新增一项Known Issue:“Making a purchase in-app for a subscription that is a member of a subscription bundle incorrectly allows the user to unbundle instead of throwing an error.”(在应用内购买属于订阅捆绑包的订阅时,会错误地允许用户拆分捆绑包,而不是抛出错误)2
Health与Shortcuts。 两项已知问题:“Personalized summaries may not generate as expected in the Insights tab,”(Insights标签页中的个性化摘要可能无法按预期生成)以及“Describe a Shortcut might fail with the error “Something went wrong. Try again later.””(Describe a Shortcut可能报错失败)。2
整个页面就这些。根据iOS 27发行说明一文9月21日的更新,beta 1和beta 2之间的章节和radar编号没有变化;变的是标题和Overview中的版本名称,从“Beta”变成了“Beta 2”。在Xcode 27.2的页面上,Overview中那句承诺Duo SDK将于“later this month in an upcoming release of Xcode 27.1”(本月晚些时候,在即将推出的Xcode 27.1版本中)提供的话,在9月17日到19日之间被替换成了下载提示框,这一点同一篇文章在9月19日的更新和脚注8中有记录;提示框的文字引自当前页面。3 那篇文章中列出的每一项27.0弃用和链接到27后的行为变更,在27.2 beta 2中都原样有效。2
Xcode 27.2 beta改变了什么?
Overview写道:“Xcode 27.2 beta includes Swift 6.4 and SDKs for iOS 27.2, iPadOS 27.2, tvOS 27.2, watchOS 27.2, macOS 27.2, and visionOS 27.2. Xcode 27.2 beta supports on-device debugging in iOS 17 and later, tvOS 17 and later, watchOS 10 and later, and visionOS. Xcode 27.2 beta requires a Mac running macOS Tahoe 26.6 or later.”(包含Swift 6.4和各平台27.2 SDK;支持在iOS 17及以上、tvOS 17及以上、watchOS 10及以上和visionOS上进行设备端调试;需要运行macOS Tahoe 26.6或更高版本的Mac)其下是一个提示框:“Download Xcode 27.1 beta to get the iOS SDK and simulator support for iPhone Duo.”3
JSON项目格式。 Project Format的New Features写道:“Xcode now supports a JSON-based project format (.xcproj) that’s more readable, merge-friendly, and easier for coding agents to edit. Enable it in the file inspector. Projects using .xcproj also open in earlier versions of Xcode 27. Learn more in Updating your Xcode project configuration file format.”三句话讲了三件事:该格式按项目选择启用,在27系列内向后兼容,而且Apple把编码智能体列为理由之一。凡是见过智能体花好几轮用正则表达式编辑project.pbxproj的人,都明白为什么会有编码智能体这一条;便于合并则是团队盼了十年的部分。我还没有转换过项目,所以这个文件在磁盘上长什么样,留待后续补充。3
部署目标陷阱。 SDK的Known Issues写道:“macOS, watchOS, tvOS, and visionOS SDKs in Xcode 27.2 incorrectly report 27.1 as a valid deployment target. Builds and other functionality may have unexpected behavior if this deployment target is used. Mac Catalyst builds with a 27.1 or 27.2 deployment target may be unable to use newly introduced API.”(Xcode 27.2中的macOS、watchOS、tvOS和visionOS SDK会错误地把27.1报告为有效的部署目标;使用该部署目标时,构建和其他功能可能出现意外行为;部署目标为27.1或27.2的Mac Catalyst构建可能无法使用新引入的API)Apple并没有为这四个系统发布27.1,Xcode 27.1 beta自己的Overview也把它们的SDK列为27,因此设为27.1的目标要求的是一个Apple尚未发布的系统版本。请使用27.0;只有当某个目标本就打算要求beta时才用27.2;无论27.1还是27.2,都要留意Apple关于Mac Catalyst的提醒。36
代码补全崩溃。 General的Known Issues写道:“Xcode may crash when using code completion on macOS 27.2 beta,”(在macOS 27.2 beta上使用代码补全时,Xcode可能崩溃)变通办法是defaults write com.apple.dt.Xcode CodeCompletionAssetsToLoad /dev/null,它会“turn[s] off enhanced code completion ranking”(关闭增强的代码补全排序)。macOS 27.2 beta 2的说明把这个崩溃列为已在系统端修复,所以运行beta 2的Mac应该不再需要这项默认设置。34
Device Hub与Simulator。 Device Hub有两项已知问题:对于“for OS versions before iOS 18.0, tvOS 18.0, watchOS 11.0, and visionOS 2.0”(早于iOS 18.0、tvOS 18.0、watchOS 11.0和visionOS 2.0的系统版本)的模拟器,键盘和鼠标输入不被接受;在开启“Simulate Hardware Keyboard”时断开连接的实体设备“may remain in “hardware keyboard” mode for up to 2 minutes”(可能在最长2分钟内停留在硬件键盘模式)。Simulator有一项已知问题,radar编号很老:“Some simulator runtimes are not completely deleted when removed, re-appearing after a reboot.”(部分模拟器运行时在移除后未被完全删除,重启后又会出现)3
Previews。 四项修复,其中一项是为智能体准备的:“The RenderPreview MCP tool now returns the list of available render destinations, and lets the caller specify which destination to use for rendering.”(RenderPreview MCP工具现在会返回可用渲染目标的列表,并允许调用方指定用哪个目标进行渲染)其余几项是缩略图网格的选择bug、针对不受支持平台的更清晰错误,以及“when previews fail because another user account on this Mac owns the Previews JIT directory”(因为这台Mac上另一个用户账户拥有Previews JIT目录而导致预览失败时)的更清晰错误。3
macOS 27.2 beta 2的发行说明写了什么?
共五个部分:列为已修复的代码补全崩溃;一项AppKit弃用,“The EnablePasteboardPrivacyDeveloperPreview user default has been removed”(EnablePasteboardPrivacyDeveloperPreview用户默认设置已被移除);一项全新安装时的Notifications已知问题,Mac“might not prompt you to allow notifications for some apps, such as Calendar, Maps, Find My, Home, and Weather,”(可能不会提示你允许部分应用的通知,例如日历、地图、查找、家庭和天气),变通办法是系统设置;与iOS相同的Shortcuts已知问题;以及与iOS相同的StoreKit Testing条目,三项已修复、一项新增。这个beta所基于的27.0版本,见macOS 27发行说明一文。4
27.2里没有什么?
iPhone Duo。Apple 9月16日的新闻稿写道:“When iPhone Duo becomes available on October 23, it will run iOS 27.1. This version builds on the foundation of iOS 27 and introduces features that were purpose-built for the new foldable design. Xcode 27.1 will add development support for iPhone Duo. This includes updated SDKs and a simulator that supports the all-new poses and orientations of iPhone Duo.”(iPhone Duo于10月23日上市时将运行iOS 27.1。这个版本以iOS 27为基础,引入专为全新折叠设计打造的功能。Xcode 27.1将加入对iPhone Duo的开发支持,包括更新的SDK,以及支持iPhone Duo全新姿态和方向的模拟器)Xcode 27.2 beta的说明也重复了这一指引。所以装上27.2 beta,可以测试欧盟提示和StoreKit修复,却测试不了折叠;一个既需要Duo API又需要27.2 SDK的项目,只能等待一个Apple尚未发布的构建版本。35
这周我会做什么
- 如果你在欧盟销售应用,尤其是在法国、德国、意大利、波兰或罗马尼亚销售(这时就必须检查),请在一台位于欧盟境内、登录欧盟地区Apple Account的设备上检查跟踪流程;在我的运行中,模拟器只显示了标准警告框。发布步骤,以及那个既不是同意也不是拒绝的返回值,见欧盟跟踪提示一文。2
- 在分支上而不是在main上试用
.xcproj:在文件检查器中启用,提交,然后在团队采用之前,先看看新文件里的合并冲突是什么样子。3 - 在Xcode 27.2中检查每个target的部署菜单,看看macOS、watchOS、tvOS和visionOS下是否出现了本不该有的27.1。3
- 如果涉及店面变更或
dialogsDisabled的StoreKit测试在27.0下不稳定,不妨在27.2上重新运行;这两个原因都已列为修复。2 - 如果你要为Duo构建,请把Xcode 27.1 beta和27.2 beta并排安装;目前两者谁也替代不了谁。35
常见问题
iOS 27.2 beta 2有什么新内容?
与beta 1是同一个页面,只是标题和Overview中的版本名称变了:面向欧盟的扩展版App Tracking Transparency提示、三项StoreKit Testing修复和三项已知问题。没有弃用,也没有以27.2 SDK为条件的行为变更。2
iOS 27.2什么时候发布?
Apple尚未公布日期。beta从9月16日开始,9月21日进入beta 2;订阅源出现正式版时,本文也会随之更新。1
iOS 27.2 beta支持iPhone Duo吗?
不支持。据Apple说明,Duo SDK和模拟器随Xcode 27.1 beta提供,手机在10月23日上市时运行iOS 27.1。35
.xcproj格式是什么?
它是Xcode 27.2 beta引入的基于JSON的Xcode项目格式,可通过文件检查器按项目选择启用;Apple称其“more readable, merge-friendly, and easier for coding agents to edit”(更易读、更便于合并,也更便于编码智能体编辑),而且更早的Xcode 27版本仍然可以打开。3
我应该在日常使用的设备上安装27.2 beta吗?
说明中列出的已知问题就是上面这些,没有提到数据丢失,但beta终究是beta。欧盟表单需要一台位于欧盟境内、登录欧盟地区Apple Account的设备;在我的运行中,模拟器只显示了标准警告框。StoreKit Testing的修复列在27.2的系统说明中,所以要重新运行这些测试,用27.2模拟器运行时应该就够了,无需在设备上安装。2
来源
-
Apple,Releases,2026年9月26日获取的RSS订阅源:日期为2026年9月21日(星期一)的“iOS 27.2 beta 2 (24B5089g)”、“iPadOS 27.2 beta 2 (24B5089g)”、“macOS 27.2 beta 2 (26B5091g)”、“tvOS 27.2 beta 2 (24K5093g)”、“visionOS 27.2 beta 2 (24N5093f)”和“watchOS 27.2 beta 2 (24S5091f)”;日期为2026年9月16日(星期三)的“Xcode 27.2 beta (27B5019j)”;日期为2026年9月18日(星期五)的“Xcode 27.1 beta (27A9269)”。日期为9月16日(星期三)的第一个beta条目“iOS 27.2 beta (24B5084k)”、“iPadOS 27.2 beta (24B5084k)”、“macOS 27.2 beta (26B5086k)”、“tvOS 27.2 beta (24K5088l)”、“visionOS 27.2 beta (24N5088l)”、“watchOS 27.2 beta (24S5086l)”和“Xcode 27.2 beta (27B5019j)”,出现在2026年9月17日获取的订阅源中,并连同这些构建版本记录在Xcode 27一文同日的更新及其脚注9中;9月26日获取的订阅源中,beta 2条目取代了第一个beta的系统条目。脚注5中的新闻稿也印证了这六个系统同批发布。 ↩↩↩↩
-
Apple,iOS & iPadOS 27.2 Beta 2 Release Notes,2026年9月26日获取:Overview;App Tracking Transparency,New Features(179504171);Health,Known Issues(186964423);Shortcuts,Known Issues(187499433);StoreKit Testing in Xcode,Resolved Issues(183933307、184155259、184255116)和Known Issues(186018916),均有引用。同日获取的发行说明索引列有“iOS & iPadOS 27 Release Notes”和“iOS & iPadOS 27.2 Beta 2 Release Notes”,没有27.1条目。 ↩↩↩↩↩↩↩↩↩↩↩
-
Apple,Xcode 27.2 Beta Release Notes,2026年9月26日获取:Overview及其提示框;General,Known Issues(186939138);Device Hub,Known Issues(181945323、182553164);Previews,Resolved Issues(183475595、185436582、186442676);Previews & Playgrounds,Resolved Issues(184564292);Project Format,New Features(184661114);SDK,Known Issues(187160501);Simulator,Known Issues(141290052),均有引用。 ↩↩↩↩↩↩↩↩↩↩↩↩↩↩↩↩↩
-
Apple,macOS 27.2 Golden Gate Beta 2 Release Notes,2026年9月26日获取:General(186939138)、AppKit(186955507)、Notifications(187312007)、Shortcuts(187499433)、StoreKit Testing in Xcode(183933307、184155259、184255116、186018916),均有引用。 ↩↩
-
Apple,“Get ready with the latest beta releases”,开发者新闻,2026年9月16日,于2026年9月26日从开发者新闻RSS订阅源读取:引用了“The beta versions of iOS 27.2, iPadOS 27.2, macOS 27.2, tvOS 27.2, visionOS 27.2, and watchOS 27.2 are now available.”以及“Note about iOS 27.1 and iPhone Duo”。 ↩↩↩↩↩
-
Apple,Xcode 27.1 Beta Release Notes,2026年9月26日获取,Overview:“Xcode 27.1 beta includes Swift 6.4 and SDKs for iOS 27.1, iPadOS 27, tvOS 27, watchOS 27, macOS 27, and visionOS 27.” ↩