添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
As Photoshop CC 2019 in now fully working (using this method: https://appdb.winehq.org/objectManager. ... &iId=37541 ), a friend of mine wrote me a little Python 3 script to get a 100% boot rate.
Using the "taskset" method only allows you to use 1 processor. This script will boot you PS CC 2019 with all CPUs working.
What does it do: The script will read and identity the CC 2019 boot process. If failure lines are found, kills the .exe and relaunch it. Another state doesn't return any errors, just a standy of the boot process. In this case the script start a countdown of 3 seconds to monitor if the process continues to boot. If not, kills the .exe and start it again.
Photoshop will 100% boot using the script. Your PS CC path (line 21) must be adapted to your configuration. The script can also be adapted to Photoshop CS 6. Enjoy it, and feel free to update it or make it better.

Code: Select all

#!/usr/bin/env python3
import subprocess, re, sys, signal
error_keywords = re.compile('^.*(Assertion|0x65372a0).*$')
success_keywords = re.compile('^.*(list_manager_QueryInterface).*$')
exited = False
process = None
successful_launch = False
timeout = 3
def kill_photoshop(signalnum, frame):
	if not successful_launch:
		print("No successful launch withing %d seconds, killing photoshop ..."%timeout, file=sys.stderr)
		process.kill()
signal.signal(signal.SIGALRM, kill_photoshop)
while not exited:
	process = subprocess.Popen(["wine64", "/home/artik/.wine/drive_c/Program Files/Adobe/Adobe Photoshop CC 2019/Photoshop.exe"], stderr=subprocess.PIPE)
	successful_launch = False
	signal.alarm(timeout)
	while True:
		if process.poll():
			break
		line = process.stderr.readline()
		# print("got line %d and process %s"%(len(line),process.poll()))
		if len(line) == 0 and process.poll() is not None:
			if process.poll() == 0:
				exited = True
			break
		if line:
			print(line.strip())
			if success_keywords.match(str(line)):
				print("Successful photoshop launch detected", file=sys.stderr)
				successful_launch = True
			if error_keywords.match(str(line)):
				print("Error keyword match, killing process", file=sys.stderr)
				process.kill()
				break
	print("Process return code %d"%process.wait())
			
artik wrote:...
Photoshop will 100% boot using the script. Your PS CC path (line 21) must be adapted to your configuration. The script can also be adapted to Photoshop CS 6. Enjoy it, and feel free to update it or make it better.
I've added the script, as a Wiki Note, to the Photoshop CC 2109 WineHQ AppDB page.
I'm pretty sure it's correct (I fixed a couple of minor items) but you might want to double check!
I've also linked the CC 2019 version of Photoshop against the bug you've (/ your friend) worked around:
Bug 35041 - Multiple apps and games crash with heap corruption or live-lock in libX11 (EA Origin, Garmin Express Fit, SMPlayer, LotRO launcher, Kindle for PC, Conan Exiles)('taskset -c 0 wine ./foo.exe' is a workaround)
Little improvement, added the wine setting:

Code: Select all

__GL_MaxFramesAllowed="1"
to fix the one frame delay with Nvidia cards. Does the "HowTo / Notes" can be updated ?
https://appdb.winehq.org/objectManager. ... &iId=37541
Thanks

Code: Select all

#!/usr/bin/env python3
import subprocess, re, sys, signal, os
error_keywords = re.compile('^.*(Assertion|0x65372a0).*$')
success_keywords = re.compile('^.*(list_manager_QueryInterface).*$')
os.environ['__GL_MaxFramesAllowed'] = "1"
exited = False
process = None
successful_launch = False
timeout = 3
def kill_photoshop(signalnum, frame):
	if not successful_launch:
		print("No successful launch withing %d seconds, killing photoshop ..."%timeout, file=sys.stderr)
		process.kill()
signal.signal(signal.SIGALRM, kill_photoshop)
while not exited:
	process = subprocess.Popen(["wine64", "/home/artik/.wine/drive_c/Program Files/Adobe/Adobe Photoshop CC 2019/Photoshop.exe"], env=os.environ, stderr=subprocess.PIPE)
	successful_launch = False
	signal.alarm(timeout)
	while True:
		if process.poll():
			break
		line = process.stderr.readline()
		# print("got line %d and process %s"%(len(line),process.poll()))
		if len(line) == 0 and process.poll() is not None:
			if process.poll() == 0:
				exited = True
			break
		if line:
			print(line.strip())
			if success_keywords.match(str(line)):
				print("Successful photoshop launch detected", file=sys.stderr)
				successful_launch = True
			if error_keywords.match(str(line)):
				print("Error keyword match, killing process", file=sys.stderr)
				process.kill()
				break
	print("Process return code %d"%process.wait())
artik wrote:Little improvement, added the wine setting:

Code: Select all

__GL_MaxFramesAllowed="1"
to fix the one frame delay with Nvidia cards. Does the "HowTo / Notes" can be updated ?
https://appdb.winehq.org/objectManager. ... &iId=37541
Thanks
Rigtheo, tis done. 8)
artik wrote: Thu Jun 13, 2019 5:45 am As Photoshop CC 2019 in now fully working (using this method: https://appdb.winehq.org/objectManager. ... &iId=37541), a friend of mine wrote me a little Python 3 script to get a 100% boot rate.
Using the "taskset" method only allows you to use 1 processor. This script will boot you PS CC 2019 with all CPUs working.
What does it do: The script will read and identity the CC 2019 boot process. If failure lines are found, kills the .exe and relaunch it. Another state doesn't return any errors, just a standy of the boot process. In this case the script start a countdown of 3 seconds to monitor if the process continues to boot. If not, kills the .exe and start it again.
Photoshop will 100% boot using the script. Your PS CC path (line 21) must be adapted to your configuration. The script can also be adapted to Photoshop CS 6. Enjoy it, and feel free to update it or make it better.

Code: Select all

#!/usr/bin/env python3
import subprocess, re, sys, signal
error_keywords = re.compile('^.*(Assertion|0x65372a0).*$')
success_keywords = re.compile('^.*(list_manager_QueryInterface).*$')
exited = False
process = None
successful_launch = False
timeout = 3
def kill_photoshop(signalnum, frame):
	if not successful_launch:
		print("No successful launch withing %d seconds, killing photoshop ..."%timeout, file=sys.stderr)
		process.kill()
signal.signal(signal.SIGALRM, kill_photoshop)
while not exited:
	process = subprocess.Popen(["wine64", "/home/artik/.wine/drive_c/Program Files/Adobe/Adobe Photoshop CC 2019/Photoshop.exe"], stderr=subprocess.PIPE)
	successful_launch = False
	signal.alarm(timeout)
	while True:
		if process.poll():
			break
		line = process.stderr.readline()
		# print("got line %d and process %s"%(len(line),process.poll()))
		if len(line) == 0 and process.poll() is not None:
			if process.poll() == 0:
				exited = True
			break
		if line:
			print(line.strip())
			if success_keywords.match(str(line)):
				print("Successful photoshop launch detected", file=sys.stderr)
				successful_launch = True
			if error_keywords.match(str(line)):
				print("Error keyword match, killing process", file=sys.stderr)
				process.kill()
				break
	print("Process return code %d"%process.wait())
							
								
				
    Privacy Policy
If you have a privacy inquiry regarding this site, please write to [email protected]

Hosted By