This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import os | |
| import requests | |
| import json | |
| import typer | |
| import concurrent.futures | |
| import re | |
| from tqdm import tqdm | |
| BASE_URL = "https://sciduct.bii.virginia.edu/fs/file/" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Bootstrap: docker | |
| From: debian:12-slim | |
| %post | |
| cd /tmp | |
| apt-get update | |
| apt-get install -y curl gdebi locales | |
| export LANGUAGE=en_US.UTF-8 | |
| export LANG=en_US.UTF-8 | |
| export LC_ALL=en_US.UTF-8 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from sanic import Sanic | |
| from sanic.response import json,text | |
| import asyncio | |
| app = Sanic("service") | |
| # import concurrent | |
| # thread_pool = concurrent.futures.ThreadPoolExecutor() | |
| async def do_step(step,duration,opts={}): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define([ | |
| 'intern!object', | |
| 'intern/chai!assert', | |
| 'intern/dojo/request', | |
| 'intern/dojo/node!../data-model', | |
| 'intern/dojo/promise/All' | |
| ], function (registerSuite, assert, request,dataModel,All) { | |
| var suite = { | |
| name: "Data Model Tests" | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var dh = domGeom.getMarginBox(grid.contentNode).h; | |
| var scrollPos = grid.getScrollPosition(); | |
| var rows = Query(".dgrid-row",grid.contentNode).filter(function(node){ | |
| return ((node.offsetTop>=scrollPos.y) && ((node.offsetTop + (.75 * node.offsetHeight)) <(scrollPos.y+dh))); | |
| }); | |
| grid.clearSelection(); | |
| grid.select(rows[0], rows[rows.length-1]); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| define(["dojo/_base/declare", "dgrid/OnDemandGrid", "dgrid/extensions/DijitRegistry","dojo/dom-geometry"], | |
| function(declare,Grid,DijitRegistryExt,domGeometry) { | |
| return declare([Grid,DijitRegistryExt], { | |
| resize: function(){ | |
| if (arguments.length>0){ | |
| domGeometry.setMarginBox(this.domNode, arguments[0]); | |
| } | |
| this.inherited("resize", arguments); | |
| } | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from starcluster.clustersetup import ClusterSetup | |
| from starcluster.logger import log | |
| class addRepository(ClusterSetup): | |
| def __init__(self, repositories=None): | |
| self.repositories=repositories | |
| if self.repositories: | |
| self.repositories= [repo.strip() for repo in repositories.split(',')] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Media({ | |
| mediaType: "application/x-bzip-compressed-tar", | |
| getQuality: function(object){ | |
| if (object && object.manifest && object.manifest.length>0){ | |
| return 1; | |
| } | |
| return 0; | |
| }, | |
| serialize: function(object, parameters, request){ | |
| //console.log("Serialize object to tbz: ", object, parameters, request); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| cid-59fd47:lrs dmachi$ rm -rf downloaded-modules/ | |
| cid-59fd47:lrs dmachi$ node $NODULES | |
| Downloading http://github.com/kriszyp/commonjs-utils/zipball/v0.2.2 | |
| request url: http://github.com/kriszyp/commonjs-utils/zipball/v0.2.2 | |
| Downloading http://github.com/kriszyp/pintura/zipball/v0.2.6 | |
| request url: http://github.com/kriszyp/pintura/zipball/v0.2.6 | |
| Downloading http://github.com/kriszyp/multi-node/zipball/v0.2.2 | |
| request url: http://github.com/kriszyp/multi-node/zipball/v0.2.2 | |
| Downloading http://github.com/kriszyp/perstore/zipball/v0.2.4 | |
| request url: http://github.com/kriszyp/perstore/zipball/v0.2.4 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var store = function(substores,options){ | |
| return { | |
| query: function(query){ | |
| var defs=[]; | |
| var results=[] | |
| substores.forEach(function(sub,index){ | |
| defs.push(when(sub.query(query), function(resultSet){ | |
| results[index]=resultSet; | |
| })); |
NewerOlder