Hostile 97% python Download

pyobjc-core 5.3

Apple keyed object archiveBacktick shell command-substitution syntax

Evidence

Python sleep waits at least one second test_modalsession.py · lines 1–48
1"""
2Check if NSModalSessions are properly wrapped.
3
4XXX: This is not a proper unittest, it requires human eyes to check if the
5output is correct.
6"""
7from __future__ import print_function
8import objc
9from Foundation import *
10from AppKit import *
11import time
12
13def doTest():
⋯6 lines
20 modalSession = app.beginModalSessionForWindow_(alertPanel)
21
22 print(modalSession, modalSession.__pointer__)
23 time.sleep(1)
24 finally:
25 if modalSession is not None:
⋯7 lines
33
34
35class AppDelegate (NSObject):
36 def applicationDidFinishLaunching_(self, aNotification):
37 doTest()
⋯11 lines
imports os AsyncPythonInterpreter.py · lines 1–20
1:7… _ = ['AsyncPythonInterpreter']
2
3try:
4 import fcntl
5except:
6 fcntl = None
7import os
8import sys
9import socket
10from netrepr import NetRepr, RemoteObjectPool, RemoteObjectReference
11import objc
12from Foundation import *
13
14IMPORT_MODULES = ['netrepr', 'remote_console', 'remote_pipe', 'remote_bootstrap']
15source = []
16for fn in IMPORT_MODULES:
17 for line in open(fn+'.py', 'rU'):
18 source.append(line)
19 source.append('\n\n')
20SOURCE = repr(''.join(sou …
socket.socket() call AsyncPythonInterpreter.py · lines 24–30
24:32… plit(':')
25 hostport = (host, int(port))
26 serversock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
27 # set close-on-exec
28 if hasattr(fcntl, 'FD_CLOEXEC'):
29 old = fcntl.fcntl(serversock.fileno(), fcntl.F_GETFD)
30 …
Python source contains .listen call text AsyncPythonInterpreter.py · lines 30–43
30:45… tl.F_SETFD, old | fcntl.FD_CLOEXEC)
31 # allow the address to be re-used in a reasonable amount of time
32 if os.name == 'posix' and sys.platform != 'cygwin':
33 serversock.setsockopt(socket.SOL_SOCKET, socket.SO_REUSEADDR, 1)
34
35 serversock.bind(hostport)
36 serversock.listen(5)
37 return serversock
38
39class AsyncPythonInterpreter(NSObject):
40
41 commandReactor = objc.IBOutlet('commandReactor')
42
43 def …
Call contains a loopback address argument AsyncPythonInterpreter.py · lines 80–85
80:6… rval = v
81 return rval
82 self.host = default(u'AsyncPythonInterpreterInterpreterHost', u'127.0.0.1', str)
83 self.port = default(u'AsyncPythonInterpreterInterpreterPort', 0, int)
84 self.interpreterPath = default(u'AsyncPythonInterpreterInterpreterPath', u'/usr/bin/python', unicode)
85 self.scriptPath = type(self).bundleForClass().pathForResource_ofType_(u'tcpi …

Showing the top 5 files — 4 more files (37 regions) not shown.

No evidence locations were recorded for this file. Raw result

Keyboard shortcuts on this page: j for the next sample, k for the previous one, x to go back to the feed, d to download the original bytes, r to re-queue the sample for analysis.