Skip to content

[BUG] #81

@jennifershtaway-bo

Description

@jennifershtaway-bo

I am running xcodebuild test-without-building in a python subprocess using this code:

command = "xcodebuild test-without-building -resultBundlePath [unique-path] -xctestrun [...]/build/run_24103/Build/Products/Automation_iphonesimulator16.1-x86_64.xctestrun -only-test-configuration AutoPNI -destination id=7AE8D24F-2C7B-44FA-88DA-E86367B1ED3D -only-testing HomeTabUITests/test_c1234"

p = subprocess.Popen(
            [command],
            stdout=subprocess.PIPE,
            # stdin=subprocess.PIPE,
            stderr=STDOUT,
            shell=True,
            cwd = self.hiroad_test_dir or None
        )
out = ""
for line in p.stdout:
            out += line.decode()
            self.my_logger.info(line.decode())
p.communicate()

when the process completes I use xcparse log [result-bundle-path] [unique-path]

which works fine and extracts information in the form of:
[unique-folder] > 1_test > Diagnostics, action.txt

but when I run one python script like this in one terminal, and then the same in another terminal (unique resultsbundlepaths and buildfilePaths based on time.time) the xcparse log command only creates a results folder that has action.txt in it, and nothing else. And the scripts fail.

Desktop (please complete the following information):

  • OS:
    ProductName: macOS
    ProductVersion: 13.2.1
    BuildVersion: 22D68
  • xcparse Version 2.3.1
  • Swift version swift-driver version: 1.62.15 Apple Swift version 5.7.1 (swiftlang-5.7.1.135.3 clang-1400.0.29.51)
  • XCResult version
    {
    "storage" : {
    "backend" : "fileBacked2",
    "compression" : "standard"
    },
    "dateCreated" : "2023-03-28T12:24:50.000-0700",
    "rootId" : {
    "hash" : "0~xUMFJ302Kitn_6q8eFdvxsYBtrtWLPYyY-ZqPmqPFb8mfLK0lI7ib4wF3Vj1dsljYK0vG-jzYRVx5EyIOkbCqg=="
    },
    "externalLocations" : [

],
"version" : {
"major" : 3,
"minor" : 39
}
}

Crash Report
Go to Finder & do "Go -> Go To Folder" and input "~/Library/Logs/DiagnosticReports". If there are any crash reports with "xcparse" in the name from the time, attach to this issue please.

To Reproduce
Steps to reproduce the behavior:
I assume run python xcodebuild test-without-building subprocess > wait for processes to complete > xcparse log to unique folders > in two windows at the same time > view results

Expected behavior
Expect Diagnostics folder to be created in xcparse log output

Additional context
only see action.txt in output

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions