Post

Replies

Boosts

Views

Activity

Reply to Is it possible to derive all the internet addresses from a hostname using the Network framework
Years back, when iPhones took time from the phone company, it was not uncommon for AT&T to set time that was up to about two minutes off true time. My satellite tracking app, while not requiring high precision, needed better than that to avoid people hunting on the wrong side of the sky! I wrote a little SNTP library so my app didn't have to rely on clock time.The [S]NTP process relies on, simplifiying, averaging resonses from multiple time-servers. It collects those server names from a pool address (pool.ntp.org, etc) which uses DNS round robin to make a random selection from a pool of time servers that have volunteered to be in the pool, for example:% host pool.ntp.org pool.ntp.org has address 173.255.215.209 pool.ntp.org has address 44.190.6.254 pool.ntp.org has address 74.6.168.73 pool.ntp.org has address 96.8.121.205The client software then fires UDP queries at all the servers, filters out less reliable one and uses the rest averaging their responses in aggregate, and over time. I know, Quinn, that there's nothing new to you in this but I've laid it out for future readers.Some people, and organizations, used my library to get a true time when naughty users were trying to defeat software expiration by setting their device clock back to an earlier date. My library is antiquated (written many years ago) and somewhat redundant (it's my experience that Apple's devices keep sub-second accurate time). Because of the age of my software, and the remaining ability to defeat expiry dates, I started to write an improved version in Swift using the Network framework and tripped over the topic of my original question.I'm amused to re-read my Radar report related to this topic you suggested I submit in 2010 (FB6015112) .. today I'd add to to my CoreTime suggestion the ability to ask the OS for true time, regardless of any fiddling with the system clock setting! Happy Hogmanay ..
Dec ’19
Reply to "Swift System"
The documentation is sufficient, it looks like a fairly simple library. What I didn't know was what the word "system" might include .. I see the material, so far, covers the file system and that's a good start! While I'm back here, commenting on this, I'd like to ask if this will become part of Swift's body of open source work? It seems a good candidate, given its subject matter is platform independent.
Jun ’20
Reply to SwiftUI - integrating with SceneKit
Interesting .. I was struggling with this too and the example helped. One question, though. We don't know what is contained in "MyScene" but I assumed that it contained a node called "camera" for the pointOfView (POV) parameter, else cameraNode would be nil. So I put my scene in place of "MyScene" and ran it. Imagine my surprise when it rendered in the view, even though I have no POV node in my model. Just to be sure I changed the SceneView creation to: SceneView(scene: scene, pointOfView: nil, options: []) and it still rendered nicely. So SceneView has a default POV, which makes sense given pointOfView is an optional, but its location is not documented (it looks to be somewhere outside the model on the +Z axis). In fact, scene is optional too, which leaves me wondering what:SceneView() means?	Are there ways to provide values for those optionals after the `SceneView` is created?
Jun ’20
Reply to Unusual errors in xcodebuild
None of the suggestions made here have resolved the problem for me (nor for some others, as noted above). You don't even have to build anything to get this to happen: % xcodebuild --help 2022-04-22 19:10:49.692 xcodebuild[53065:8448383] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionSentinelHostApplications for extension Xcode.DebuggerFoundation.AppExtensionHosts.watchOS of plug-in com.apple.dt.IDEWatchSupportCore 2022-04-22 19:10:49.692 xcodebuild[53065:8448383] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionPointIdentifierToBundleIdentifier for extension Xcode.DebuggerFoundation.AppExtensionToBundleIdentifierMap.watchOS of plug-in com.apple.dt.IDEWatchSupportCore Usage: xcodebuild [-project <projectname>] [[-target <targetname>]...|-alltargets] . . . . This with Xcode 13.3.1 and CommandLineTools installed (both by request then, again, manually). Note, while --help causes trouble --usage does not: % xcodebuild --usage    Usage: xcodebuild [-project <projectname>] [[-target <targetname>]...|-alltargets] . . . . Be glad you're not on my other (M1) Mac: % xcodebuild --help objc[46924]: Class AppleTypeCRetimerRestoreInfoHelper is implemented in both /usr/lib/libauthinstall.dylib (0x20496deb0) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x105ad84f8). One of the two will be used. Which one is undefined. objc[46924]: Class AppleTypeCRetimerFirmwareAggregateRequestCreator is implemented in both /usr/lib/libauthinstall.dylib (0x20496df00) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x105ad8548). One of the two will be used. Which one is undefined. objc[46924]: Class AppleTypeCRetimerFirmwareRequestCreator is implemented in both /usr/lib/libauthinstall.dylib (0x20496df50) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x105ad8598). One of the two will be used. Which one is undefined. objc[46924]: Class ATCRTRestoreInfoFTABFile is implemented in both /usr/lib/libauthinstall.dylib (0x20496dfa0) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x105ad85e8). One of the two will be used. Which one is undefined. objc[46924]: Class AppleTypeCRetimerFirmwareCopier is implemented in both /usr/lib/libauthinstall.dylib (0x20496dff0) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x105ad8638). One of the two will be used. Which one is undefined. objc[46924]: Class ATCRTRestoreInfoFTABSubfile is implemented in both /usr/lib/libauthinstall.dylib (0x20496e040) and /Library/Apple/System/Library/PrivateFrameworks/MobileDevice.framework/Versions/A/MobileDevice (0x105ad8688). One of the two will be used. Which one is undefined. 2022-04-22 19:28:15.138 xcodebuild[46924:2646597] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionSentinelHostApplications for extension Xcode.DebuggerFoundation.AppExtensionHosts.watchOS of plug-in com.apple.dt.IDEWatchSupportCore 2022-04-22 19:28:15.138 xcodebuild[46924:2646597] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionPointIdentifierToBundleIdentifier for extension Xcode.DebuggerFoundation.AppExtensionToBundleIdentifierMap.watchOS of plug-in com.apple.dt.IDEWatchSupportCore Usage: xcodebuild [-project <projectname>] [[-target <targetname>]...|-alltargets] . . . .
Apr ’22
Reply to MacOS MapKit - CVDisplayLinkSetPaused alternating true/false several times per second
When using MKMapView within SwiftUI in MacOS, via NSViewRepresentable and a Coordinator, the are several console messages per second "CVDisplayLinkSetPaused", alternating between [TRUE]and [FALSE] when displaying a poly line and/or annotations. .. also seeing my log deluged with this effect, but in my case, none of the above conditions are true. There is significant use of SceneKit but no SwiftUI, MapView, or anything else from the quote above (unless "poly line" is equivalent to SceneKit drawing a twisty line through a 3-D space). MacBook Pro (16-inch, M1 Max, 2021); macOS 12.3.1 (21E258); Xcode 13.3.1 (13E500a)
May ’22
Reply to Can you install macOS Ventura on an separate volume? (Apple Silicon)
Exactly the same problem .. an overnight install ended up on my production APFS volume. I assumed that the installer, not having any input from me, defaulted to do that. However, I repeated the process watching it all the way and it happened again without any request for volume choice. This is a serious time waster .. I suppose I'm going to have to create an installer on an external disk which I can do but why are we having this issue and the other million developers are not?
Jun ’22
Reply to SCN to USDZ
I may be diverting the topic "SCN to USDZ" somewhat but I performed the above action (using Xcode [15.3 beta 2] to read .scn and export .usdz) on one of my, admittedly, complex .scn files. The scene in question is entirely line segments (closed loops - actually world coastlines). The exported .usdz model bears no similarity to the .scn file -- it's just over one kilobyte, and viewed in Xcode it does open, but is "empty." I know RealityKit doesn't provide for a ".line" primitive in meshes and wonder if .usdz is similarly constrained (it seems unlikely to me, but maybe Xcode doesn't support that structure either). The .scn file is large (1.1MB) but renders instantly in QuickLook .. could it be too large to be converted (again unlikely). I'm no expert in 3D technologies and could be missing something obvious, but what the Xcode "conversion" delivers is unexpected. I'm bringing this here as I continue to explore conversions in the hope of a suggestion or two, OR being told what I'm attempting to do is not possible (and I can stop wasting time)?
Feb ’24
Reply to "Enable-Private-Data" in a command line application ..
A minimal command line app is exhibiting the same unexpected behavior, and there's not much left to make mistakes in. Hopefully, someone will point out an appallingly simple error, else, I'll wrap this up into an FB. Source import Foundation import OSLog let loggingTest = Logger(subsystem: "com.ramsaycons", category: "LoggingTest") loggingTest.log("info: \(Bundle.main.infoDictionary!)") Info.plist <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>OSLogPreferences</key> <dict> <key>com.ramsaycons</key> <dict> <key>DEFAULT-OPTIONS</key> <dict> <key>Enable-Private-Data</key> <true/> </dict> </dict> </dict> </dict> </plist> Xcode run output (whitespace modified for readability): info: [ "DTPlatformBuild": , "LSMinimumSystemVersion": 14.5, "DTXcode": 1540, "CFBundleSupportedPlatforms": <__NSArrayM 0x600000e58720>(MacOSX), "DTSDKName": macosx14.5, "DTCompiler": com.apple.compilers.llvm.clang.1_0, "DTXcodeBuild": 15F31d, "DTSDKBuild": 23F73, "DTPlatformName": macosx, "DTPlatformVersion": 14.5, "BuildMachineOSBuild": 23F79, "OSLogPreferences": { "com.ramsaycons" = { "DEFAULT-OPTIONS" = { "Enable-Private-Data" = 1; }; }; }] Program ended with exit code: 0 Console.app output: default 17:16:33.869184-0400 LoggingTest info: <private>
May ’24
Reply to "Enable-Private-Data" in a command line application ..
Thanks, Quinn, for the explanation; I like the "for fun" stuff .. it makes perfect sense, and is a little obvious after the fact! In passing, I'll mention finding another way of defeating (which I won't be explicit about, though it's not too hard to find). Dropping a particular plist file into a particular /Library/Preferences/.. location enables opening for a command line app (and everything else). It's not useful to me (and neither is the config profile) because I need to ask someone else, with a wider range of models of the hardware I'm working with), to run my program. I won't ask someone else to open global holes in their security .. an app-local solution which only opens for that one app and only for the duration of its execution is essential. For my immediate need, I can wrap the command line into a trivial *.app. I'll file a bug and report the FB# here ..
May ’24