Skip to content

Instantly share code, notes, and snippets.

View minrk's full-sized avatar

Min RK minrk

View GitHub Profile
@minrk
minrk / test.py
Last active August 22, 2024 10:55
zmqtest.py
import zmq
print("imported")
print("has", zmq.has("ipc"))
with zmq.Context() as ctx:
print("context")
with ctx.socket(zmq.PUSH) as push, ctx.socket(zmq.PULL) as pull:
print("sockets")
url = "tcp://127.0.0.1:5555"
push.bind(url)
@ARTICLE{test,
author={Last Name, First},
journal={Computing in Science {\&} Engineering},
title={Thing \& Other thing},
year={3048},
volume={1},
number={1},
pages={1-2},
keywords={},
}
import asyncio
import pytest_asyncio
@pytest_asyncio.fixture(scope="module", loop_scope="module")
async def current_loop():
return asyncio.get_running_loop()
@pytest_asyncio.fixture(loop_scope="module", autouse=True)
async def cleanup_after():
yield
FROM python:3.12
RUN python3 -m pip install weasyprint wurlitzer jupyterlab
RUN python3 -c 'import weasyprint'
ENV HOME=/home/test
# make an unwritable cache directory
RUN useradd test \
&& mkdir -p $HOME/.fontconfig \
&& mkdir -p $HOME/.cache \
&& chown test $HOME
USER test
================================================================================
================================================================================
linux-armv7l
================================================================================
================================================================================
win-32
================================================================================
================================================================================
linux-ppc64le
linux-ppc64le::fenics-dolfinx-0.8.0-py311hd7d00f9_1.conda
import atexit
import statistics
import sys
import time
from subprocess import Popen
import psutil
def jupyterhub(interval):
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_basic_assembly_petsc_matrixcsr[none] - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_basic_assembly_petsc_matrixcsr[shared_facet] - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_assembly_bcs[none] - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_assembly_bcs[shared_facet] - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_petsc_assemble_manifold - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_matrix_assembly_block[none] - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.py::TestPETScAssemblers::test_matrix_assembly_block[shared_facet] - ModuleNotFoundError: No module named 'petsc4py'
FAILED unit/fem/test_assembler.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Created Date Query Total Results
2024-06-24 18:13:28 appendix.txt 0
2024-06-20 11:38:36 service 6
2024-06-20 09:34:56 service 6
2024-06-20 09:15:59 use_registry 3
2024-06-20 09:15:33 values 7
2024-06-20 09:14:02 base_url 2
2024-06-20 09:13:57 baseurl 0
2024-06-20 07:12:24 biospace 0
2024-06-19 18:37:48 jupyter 4
"""
Format stdin with ruff to stdout
When formatting fails, append error message
For use in an Automator Quick Action (Run Shell Script),
accessible everywhere via right click -> Services > ruff format,
or global keyboard shortcut registered in System Settings > Keyboard > Keyboard Shortcuts
Find the action under Services