Skip to content

Instantly share code, notes, and snippets.

View kinow's full-sized avatar
💭
😬

Bruno P. Kinoshita kinow

💭
😬
View GitHub Profile
@kinow
kinow / database-diagram.py
Created July 28, 2019 05:28
database-diagram.py
#!/usr/bin/env python3
# THIS FILE IS PART OF THE CYLC SUITE ENGINE.
# Copyright (C) 2008-2019 NIWA & British Crown (Met Office) & Contributors.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
@kinow
kinow / test_scan.py
Created July 24, 2019 04:10
A possible test for cylc.flow.network.scan
import re
from collections import namedtuple
from pathlib import Path
from tempfile import TemporaryDirectory
from unittest import TestCase, main
from unittest.mock import patch
from cylc.flow import flags
from cylc.flow.exceptions import SuiteServiceFileError
from cylc.flow.network.scan import get_scan_items_from_fs
@kinow
kinow / isodatetime.txt
Last active June 19, 2019 05:01
isodatetime related work
- Airflow uses pendulum
- pendulum does not support recurrence
- maybe [this issue](https://github.com/sdispater/pendulum/issues/188) is about recurrence
- https://github.com/dateutil/dateutil/blob/master/dateutil/rrule.py does
- and so does https://dateutil.readthedocs.io/en/stable/rrule.html
@kinow
kinow / app.py
Created June 12, 2019 03:04
Sample addslash Tornado
import tornado.ioloop
import tornado.web
class AddSlashHandler(tornado.web.RequestHandler):
@tornado.web.addslash
def get(self):
pass
https://github.com/cylc/cylc-flow/milestone/77?closed=1
skipped: 3136, 3127, 3124, 3101, 3079, 3082, 3086, 3084, 3061, 3058, 3044, 3034, 3033, 3030, 3013, 3008, 2973
update mailmap, gitignore, typos, unused imports, small changes to docs, etc.
svnmucc -U https://dist.apache.org/repos/dist \
mkdir release/commons/imaging/ \
mkdir release/commons/imaging/binaries \
mkdir release/commons/imaging/source \
mv dev/commons/imaging/1.0-alpha1-RC3/RELEASE-NOTES.txt release/commons/imaging/RELEASE-NOTES.txt \
mv dev/commons/imaging/1.0-alpha1-RC3/HEADER.html release/commons/imaging/HEADER.html \
mv dev/commons/imaging/1.0-alpha1-RC3/README.html release/commons/imaging/README.html \
mv dev/commons/imaging/1.0-alpha1-RC3/binaries/README.html release/commons/imaging/binaries/README.html \
mv dev/commons/imaging/1.0-alpha1-RC3/binaries/HEADER.html release/commons/imaging/binaries/HEADER.html \
mv dev/commons/imaging/1.0-alpha1-RC3/binaries/commons-imaging-1.0-alpha1-bin.tar.gz release/commons/imaging/binaries/commons-imaging-1.0-alpha1-bin.tar.gz \
```diff
diff --git a/setup.py b/setup.py
index 74cbaf4..0042063 100644
--- a/setup.py
+++ b/setup.py
@@ -31,6 +31,7 @@ install_requires = [
'protobuf',
'python-jose',
'colorama',
+ 'cylc @ https://github.com/dwsutherland/cylc/tarball/protobuf-uis-feed#egg=cylc-8.0a1.dev'
@kinow
kinow / .pydeps
Created April 3, 2019 22:58
Pydeps config for cylc 8 master
[pydeps]
max_bacon = 2
verbose = 0
pylib = False
noshow = True
exclude =
os
re
sys
collections
$ tail -1000f /tmp/tmp.pfbdb4xtp8/cylctb-20190326T213057Z/tutorial/oneoff/05-tut.inherit/05-tut.inherit-run.stderr
2019-03-27T10:32:14+13:00 DEBUG - Loading site/user global config files
2019-03-27T10:32:14+13:00 DEBUG - Reading file /tmp/tmp.pfbdb4xtp8/etc/global.rc
2019-03-27T10:32:14+13:00 DEBUG - Generated /home/kinow/cylc-run/cylctb-20190326T213057Z/tutorial/oneoff/05-tut.inherit/.service/passphrase
2019-03-27T10:32:14+13:00 DEBUG - Loading site/user global config files
2019-03-27T10:32:14+13:00 DEBUG - Reading file /tmp/tmp.pfbdb4xtp8/etc/global.rc
2019-03-27T10:32:14+13:00 DEBUG - creating suite run directory: /home/kinow/cylc-run/cylctb-20190326T213057Z/tutorial/oneoff/05-tut.inherit
2019-03-27T10:32:14+13:00 DEBUG - creating suite log directory: /home/kinow/cylc-run/cylctb-20190326T213057Z/tutorial/oneoff/05-tut.inherit/log/suite
2019-03-27T10:32:14+13:00 DEBUG - creating suite job log directory: /home/kinow/cylc-run/cylctb-20190326T213057Z/tutorial/oneoff/05-tut.inherit/log/job
2019-03-27T10:32:14+1
@kinow
kinow / pyrightconfig.json
Created March 25, 2019 22:31
pyrightconfig.json for cylc
{
"include": [
"lib/cylc/",
"lib/parsec",
"lib/Jinja2Filters",
"bin"
],
"exclude": [
"lib/isodatetime/",
"lib/markupsafe/",