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
macro_rules! code_value { | |
( | |
$NAME:ident { | |
$( | |
$( $IN:pat )|+ => $VARIANT:ident => $OUT:expr | |
),* | |
} | |
) => ( | |
#[derive(Clone, Copy, Debug)] | |
pub enum $NAME { |
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
@app.route('/manifest/:id', methods=['POST']) | |
def manifest(): | |
user = get_user_from_db_by_id(id) | |
return send_file('/tmp/dash/' + user.manifest_filename + '.mpd', filename=(str(id) + '.mpd')) |
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
diff --git a/src/main/java/edu/stanford/survey/server/CatAlgorithmPromis.java b/src/main/java/edu/stanford/survey/server/CatAlgorithmPromis.java | |
index cbf03a8e..a8cca090 100644 | |
--- a/src/main/java/edu/stanford/survey/server/CatAlgorithmPromis.java | |
+++ b/src/main/java/edu/stanford/survey/server/CatAlgorithmPromis.java | |
@@ -70,7 +70,8 @@ public CatAlgorithm initialize(ItemBank itemBank) { | |
int nCategory = 0; | |
for (Response r : item.responses()) { | |
if (r.difficulty() < 1 || r.difficulty() > item.betas().length + 1) { | |
- throw new IllegalArgumentException("Item " + item.code() + " has a response with a difficulty out of range"); | |
+ log.debug("Item " + item.code() + " has a response with a difficulty out of range"); |
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 debounce from 'lodash/debounce'; | |
import { isInView } from './utils.js'; | |
const header = document.querySelector('.site-header'); | |
let headerRect = header.getBoundingClientRect(); | |
window.addEventListener('resize', debounce(() => { | |
headerRect = header.getBoundingClientRect(); | |
}, 100)); |
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
impl DataSchemaValue for schema::MonitorCodeType { | |
fn from_value(data: &calamine::DataType) -> Result<schema::MonitorCodeType, MCWAnesthError> { | |
if let calamine::DataType::String(ref input) = *data { | |
match &input as &str { | |
"A Line" => Ok(schema::MonitorCodeType("Arterial Line".to_string())), | |
"CVP Line" => Ok(schema::MonitorCodeType("Central Venous Line".to_string())), | |
"PA Line" => Ok(schema::MonitorCodeType("Pulmonary Artery Line".to_string())), | |
"TEE" => Ok(schema::MonitorCodeType("Transesophageal Echocardiogram".to_string())), | |
"BIS" => Ok(schema::MonitorCodeType("Bispectral Index".to_string())), | |
"EEG" => Ok(schema::MonitorCodeType("Electroencephalogram".to_string())), |
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
//! # Schema types | |
//! Enumerate valid types in AQI Schema | |
extern crate chrono; | |
extern crate regex; | |
use self::chrono::prelude::{Date, DateTime, Local}; | |
use self::regex::Regex; | |
use ::AQIError; |
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 React, { Component } from 'react'; | |
import { renderToString, renderToStaticMarkup } from 'react-dom/server'; | |
import flush from 'styled-jsx/server'; | |
import PropTypes from 'prop-types'; | |
import ActiveEvent from './ActiveEvent.js'; | |
export default class EmailGenerator extends Component { | |
constructor(props) { | |
super(props); |
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 React, { Component } from 'react'; | |
import { renderToString, renderToStaticMarkup } from 'react-dom/server'; | |
import PropTypes from 'prop-types'; | |
import download from 'downloadjs'; | |
import ActiveEvent from './ActiveEvent.js'; | |
export default class EmailGenerator extends Component { | |
constructor(props) { |
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
root = true | |
[*] | |
indent_style = space | |
indent_size = 2 | |
end_of_line = lf | |
charset = utf-8 | |
trim_trailing_whitespace = true | |
insert_final_newline = true |
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
[36mBuilt-in Atom Packages[39m (91) | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] | |
├── [email protected] |