AppImages aren't working correctly afterall.

This commit is contained in:
Andrew Hamilton 2017-07-04 14:49:46 +01:00
parent 50dac0aa58
commit d61b1504a6
3 changed files with 13 additions and 5 deletions

1
BUGS
View file

@ -7,6 +7,7 @@ Current
- If a job is paused for longer than the timeout period, sometimes it has
the timed out status when un-paused.
- Tmp files are being left behind after shutdown.
- All tools in AppImages aren't working correctly. See ./vigil --self_test
Current (tool related)

View file

@ -14,10 +14,10 @@ for dependency in tools.dependencies("ubuntu"):
else:
dist_deps.add(dependency)
dist_deps.update({"python3-pygments", "python3-pyinotify", "python3-docopt",
"util-linux", "python3-pil", "python3-pip",
"python3-setuptools"})
"util-linux", "python3-pil"})
dep_list = "\n - ".join(sorted(dist_deps))
print("""app: vigil-code-monitor
union: true
ingredients:
packages:
@ -27,7 +27,11 @@ ingredients:
- deb http://archive.ubuntu.com/ubuntu/ zesty main universe
script:
- ./usr/bin/python3 -m pip install $VIGIL_PATH
- export APPDIR=$(pwd)
- export PYTHONPATH=$APPDIR/usr/share/pyshared
- mkdir -p $PYTHONPATH
- (cd $VIGIL_PATH; /usr/bin/python3 setup.py install \
--prefix=$APPDIR/usr --install-lib=$PYTHONPATH)
- cp $VIGIL_PATH/appimage/vigil-icon.png .
- cp -a $VIGIL_PATH/tests .
- cp $VIGIL_PATH/test-all tests
@ -36,7 +40,7 @@ script:
- Type=Application
- Name=Vigil Code Monitor
- Comment=Vigil maintains an up-to-date set of reports for every file in a codebase.
- Exec=./bin/python3 -m vigil
- Exec=vigil
- Terminal=true
- Icon=vigil-icon.png
- Categories=Application;

View file

@ -18,11 +18,14 @@ class Worker:
self.result = None
self.process = None
self.child_pgid = None
self.script_path = (os.path.join(
os.environ["APPDIR"], "usr", "bin", "vigil-worker")
if "APPDIR" in os.environ else "vigil-worker")
@asyncio.coroutine
def create_process(self):
create = asyncio.create_subprocess_exec(
"vigil-worker", stdin=asyncio.subprocess.PIPE,
self.script_path, stdin=asyncio.subprocess.PIPE,
stdout=asyncio.subprocess.PIPE, stderr=asyncio.subprocess.PIPE,
preexec_fn=os.setsid)
self.process = yield from create