text
stringlengths
11
6.3k
embedding
listlengths
768
768
func (m *MockDriver) TableNames(schema string, whitelist, blacklist []string) ([]string, error) { if len(whitelist) > 0 { return whitelist, nil } tables := []string{"pilots", "jets", "airports", "licenses", "hangars", "languages", "pilot_languages"} return strmangle.SetComplement(tables, blacklist), nil }
[ -0.6788721084594727, 0.658727765083313, 0.5156904458999634, 0.03673041611909866, 0.08860354870557785, -0.2566736042499542, -0.3354938328266144, 1.0580525398254395, 0.059583552181720734, 1.2421061992645264, -0.32955440878868103, 0.22194436192512512, -0.9081724286079407, 1.1748926639556885, ...
func (m *MockDriver) Columns(schema, tableName string, whitelist, blacklist []string) ([]drivers.Column, error) { return map[string][]drivers.Column{ "pilots": { {Name: "id", Type: "int", DBType: "integer"}, {Name: "name", Type: "string", DBType: "character"}, }, "airports": { {Name: "id", Type: "int", ...
[ -0.44017332792282104, -0.34210243821144104, 0.7304888963699341, -1.059583306312561, 0.2033141702413559, -0.6286648511886597, -0.2695055902004242, 0.32710573077201843, 0.44130346179008484, 0.1682409942150116, -0.7187434434890747, 0.0948588028550148, -0.04241994023323059, 0.31460967659950256...
func (m *MockDriver) ForeignKeyInfo(schema, tableName string) ([]drivers.ForeignKey, error) { return map[string][]drivers.ForeignKey{ "jets": { {Table: "jets", Name: "jets_pilot_id_fk", Column: "pilot_id", ForeignTable: "pilots", ForeignColumn: "id", ForeignColumnUnique: true}, {Table: "jets", Name: "jets_airp...
[ -0.30016830563545227, -0.04382824897766113, 0.8400970697402954, -0.2951495945453644, -0.30778801441192627, -0.12347214668989182, -0.16362890601158142, 0.07721289247274399, -0.5065445303916931, 0.3601153790950775, -0.6595759987831116, -0.2621804475784302, -0.13800649344921112, 0.75228500366...
func (m *MockDriver) TranslateColumnType(c drivers.Column) drivers.Column { if c.Nullable { switch c.DBType { case "bigint", "bigserial": c.Type = "null.Int64" case "integer", "serial": c.Type = "null.Int" case "smallint", "smallserial": c.Type = "null.Int16" case "decimal", "numeric", "double preci...
[ -0.023951245471835136, -0.6278660297393799, 0.7705404758453369, -0.6991003751754761, 0.7348154187202454, -1.0238702297210693, 0.2881687581539154, -0.07668624073266983, 0.43044254183769226, 0.477610319852829, -1.0160075426101685, -0.40068286657333374, -0.2976611256599426, 0.1321554481983184...
func (m *MockDriver) PrimaryKeyInfo(schema, tableName string) (*drivers.PrimaryKey, error) { return map[string]*drivers.PrimaryKey{ "pilots": { Name: "pilot_id_pkey", Columns: []string{"id"}, }, "airports": { Name: "airport_id_pkey", Columns: []string{"id"}, }, "jets": { Name: "jet_id...
[ -0.34418436884880066, -0.4636518955230713, 0.584345281124115, -0.43753674626350403, -0.7924808263778687, 0.1472429633140564, -0.4920000731945038, 0.5159667134284973, -0.48740074038505554, 0.41260164976119995, -0.7404689788818359, -0.45111557841300964, -0.2577701807022095, 0.562716722488403...
func (m *MockDriver) UseLastInsertID() bool { return false }
[ -0.2122528851032257, -0.7130045890808105, 0.6640264987945557, -0.257404088973999, -0.031777143478393555, 0.0491044744849205, 0.7498104572296143, 0.5531273484230042, -0.01867060549557209, 0.27190741896629333, -0.3242659568786621, -0.7574854493141174, -1.951563835144043, 0.9132319092750549, ...
func (m *MockDriver) UseTopClause() bool { return false }
[ -1.0694580078125, -0.9409793615341187, 0.7156116366386414, -0.09859046339988708, -0.7427157759666443, -0.3086943030357361, 0.16075293719768524, 0.4379744231700897, -0.33794981241226196, -0.18725712597370148, 0.25058653950691223, -1.222891926765442, -1.7309831380844116, 0.8002612590789795, ...
func (m *MockDriver) Open() error { return nil }
[ -1.354746699333191, -0.3629873991012573, 0.27305659651756287, 0.12348373979330063, -0.03702078387141228, 0.46591535210609436, 1.115896224975586, 2.087019205093384, -0.06178120896220207, -0.5709936618804932, 0.03553946316242218, -0.5977008938789368, -1.3670536279678345, 0.686673104763031, ...
func (m *MockDriver) Close() {}
[ -1.2708669900894165, -0.9585897326469421, 0.6333193182945251, 0.35120469331741333, -0.17739006876945496, 0.9356859922409058, 1.002622127532959, 0.8879904747009277, -0.47498777508735657, -0.3324015736579895, 0.5946764945983887, -0.6707817912101746, -1.5925366878509521, 1.7789909839630127, ...
func (m *MockDriver) RightQuote() byte { return '"' }
[ 0.38248971104621887, -0.5753775238990784, 0.5247251987457275, 0.42833489179611206, 0.3862646222114563, -0.004967337474226952, -0.8244445323944092, 0.14347341656684875, -0.29544976353645325, 0.17789016664028168, 0.1262870579957962, -0.1951061487197876, -1.6942615509033203, 1.096746563911438...
func (m *MockDriver) LeftQuote() byte { return '"' }
[ 0.45320814847946167, -0.9625795483589172, 0.5185826420783997, 0.14094187319278717, 0.650455892086029, 0.42048823833465576, -1.003273367881775, -0.00997046660631895, 0.09728259593248367, 0.5875465273857117, -0.2379876971244812, -0.6509377956390381, -2.1330249309539795, 1.7305567264556885, ...
func (m *MockDriver) UseIndexPlaceholders() bool { return false }
[ -1.3834367990493774, 0.5143114924430847, 0.3054988384246826, -0.1305420994758606, -0.14047254621982574, 0.24553094804286957, 1.023947834968567, 0.3155239522457123, 0.3671192526817322, -0.3534722328186035, -0.33383655548095703, -1.3089361190795898, -1.7570843696594238, 0.618108332157135, ...
func Run() { // initialize the shell initialize() // interpret each input indefinetly for { err := interpret() if err == nil { continue } if err == io.EOF { fmt.Fprintln(os.Stderr, err) break } fmt.Println(err) } }
[ 0.5070411562919617, -0.5971630811691284, 0.9123113751411438, -0.8529519438743591, 0.589961588382721, 0.7194375991821289, 0.10467209666967392, 0.9457655549049377, -0.8151750564575195, -0.8626599907875061, 0.49626415967941284, 0.3043938875198364, -0.1591152846813202, 1.0373400449752808, 0....
func ValidateSignature(ctx context.Context, req *http.Request, v ClientStorage) error { preq, err := newProviderRequest(req) if err != nil { return err } if err = v.ValidateNonce(ctx, preq.clientKey, preq.nonce, preq.timestamp, req); err != nil { return err } signer, invalidClient := v.GetSigner(ctx, preq.cli...
[ -0.8786144256591797, -0.33113086223602295, 0.43930310010910034, 0.9049574136734009, -0.11457856744527817, -0.5075031518936157, 0.38000544905662537, -0.29721787571907043, 0.5423867106437683, 0.16599449515342712, 0.2787776589393616, 0.06326865404844284, -0.6003082990646362, 0.703704178333282...
func NewLoginRequest() *LoginRequest { this := LoginRequest{} return &this }
[ -1.3182311058044434, -1.1310993432998657, 0.12151423841714859, 0.9341117739677429, -0.9600844979286194, -0.3599912226200104, -0.48791247606277466, -0.09910519421100616, 0.29813939332962036, -0.7512300610542297, -0.45304253697395325, 0.7647930979728699, -0.7711341381072998, -0.0674982890486...
func NewLoginRequestWithDefaults() *LoginRequest { this := LoginRequest{} return &this }
[ -1.1747043132781982, -0.7608996629714966, 0.04741669073700905, 0.9192185997962952, 0.10439420491456985, -0.41055092215538025, -1.1315052509307861, -0.5661893486976624, 0.44000881910324097, -0.7000100612640381, -0.694141149520874, -0.7966049313545227, -0.909166693687439, 0.3681603968143463,...
func (o *LoginRequest) GetChallenge() string { if o == nil || o.Challenge == nil { var ret string return ret } return *o.Challenge }
[ 0.6245017051696777, 0.4886133670806885, 0.2074223756790161, 1.222981333732605, 0.18839100003242493, -0.8412196040153503, 0.49113327264785767, -0.1803661435842514, 0.7145456075668335, -0.5434761643409729, -0.10296939313411713, -1.4928252696990967, -0.8444029092788696, 0.9330522418022156, ...
func (o *LoginRequest) GetChallengeOk() (*string, bool) { if o == nil || o.Challenge == nil { return nil, false } return o.Challenge, true }
[ 0.5679415464401245, -0.0985952839255333, 0.39470162987709045, 0.5237036943435669, 0.4579412639141083, -0.17176850140094757, 0.8851245045661926, 1.0590780973434448, 0.05597526952624321, 0.7130038142204285, -1.181313157081604, -1.1719892024993896, 0.47448769211769104, 0.9094868898391724, 0...
func (o *LoginRequest) HasChallenge() bool { if o != nil && o.Challenge != nil { return true } return false }
[ 0.7726729512214661, 0.6865765452384949, 0.19169439375400543, 0.8444501161575317, 0.6765717267990112, -0.9346305727958679, -0.32990047335624695, 0.4864586293697357, 0.28240224719047546, -0.7720020413398743, -1.12918221950531, -1.3337228298187256, -0.3985869586467743, 0.7110719084739685, 0...
func (o *LoginRequest) SetChallenge(v string) { o.Challenge = &v }
[ 0.17788194119930267, 0.02700388804078102, -0.3109774589538574, 0.6894685626029968, -0.4373704493045807, -0.9886056780815125, -0.6333235502243042, -1.0239534378051758, 0.07549513876438141, -0.24657562375068665, -0.23210251331329346, 0.8339114785194397, -0.7960614562034607, 0.097072638571262...
func (o *LoginRequest) GetClient() OAuth2Client { if o == nil || o.Client == nil { var ret OAuth2Client return ret } return *o.Client }
[ -0.3407253623008728, 0.3100852966308594, 0.5424447655677795, 1.341690182685852, -0.5616858005523682, -0.5698800086975098, 0.8641055226325989, -0.5884299278259277, 1.0670005083084106, -1.112476110458374, 0.14572463929653168, -0.4429400861263275, -0.2129388302564621, -0.22339345514774323, ...
func (o *LoginRequest) GetClientOk() (*OAuth2Client, bool) { if o == nil || o.Client == nil { return nil, false } return o.Client, true }
[ -0.23787297308444977, -0.30599239468574524, 0.22300074994564056, 0.5147280693054199, -0.37181663513183594, 0.0628078356385231, 1.069665551185608, -0.02239464409649372, 0.07530771195888519, 0.20035721361637115, -0.6172769665718079, -0.1542838215827942, 0.41762641072273254, -0.19404284656047...
func (o *LoginRequest) HasClient() bool { if o != nil && o.Client != nil { return true } return false }
[ -0.12226357311010361, 0.46768051385879517, 0.278548002243042, 0.32038211822509766, 0.36011824011802673, -0.015005848370492458, 0.3781777024269104, 0.4846949279308319, 0.4192771911621094, -1.4042025804519653, -0.3861903250217438, -0.6164979934692383, -0.038914747536182404, -0.78060340881347...
func (o *LoginRequest) SetClient(v OAuth2Client) { o.Client = &v }
[ -1.0265263319015503, -0.2660578787326813, 0.062157224863767624, 0.5018298625946045, -0.9951524138450623, -0.17152567207813263, -0.26522204279899597, -1.2839666604995728, 0.43811169266700745, -0.6988112330436707, 0.13081258535385132, 1.5106284618377686, 0.5130845308303833, -1.07156670093536...
func (o *LoginRequest) GetOidcContext() OpenIDConnectContext { if o == nil || o.OidcContext == nil { var ret OpenIDConnectContext return ret } return *o.OidcContext }
[ -0.24291400611400604, -0.5274050235748291, 0.4813392758369446, -0.08891148865222931, -0.26479384303092957, -0.5824477672576904, -0.07693316042423248, -1.9362010955810547, 1.4192458391189575, -0.0834721177816391, -0.40910854935646057, -1.1877696514129639, -1.1294832229614258, -0.55603271722...
func (o *LoginRequest) GetOidcContextOk() (*OpenIDConnectContext, bool) { if o == nil || o.OidcContext == nil { return nil, false } return o.OidcContext, true }
[ -0.2488354742527008, -0.6347832083702087, 0.4560984671115875, -0.47645580768585205, 0.381865918636322, -0.2327469289302826, 0.8891287446022034, -0.7018866539001465, 0.7723994255065918, 0.2778880298137665, -0.6879500150680542, -0.7711427211761475, -0.23439404368400574, -0.46115684509277344,...
func (o *LoginRequest) HasOidcContext() bool { if o != nil && o.OidcContext != nil { return true } return false }
[ 0.42922088503837585, -0.1160665825009346, 0.36482667922973633, -0.5999025106430054, 0.779059886932373, -1.0634173154830933, -0.081346295773983, -0.5969581007957458, 0.8812642693519592, -0.6087338328361511, -0.9722029566764832, -0.6440051794052124, -0.44886648654937744, 0.22007018327713013,...
func (o *LoginRequest) SetOidcContext(v OpenIDConnectContext) { o.OidcContext = &v }
[ -0.5688514113426208, -0.9801967740058899, 0.11512865126132965, -0.7351049184799194, -0.3104894757270813, -0.11956609785556793, -0.47350919246673584, -2.315901517868042, 1.3177603483200073, 0.04154202342033386, -0.5442067384719849, 0.12986911833286285, -0.3815435469150543, -1.09081149101257...
func (o *LoginRequest) GetRequestUrl() string { if o == nil || o.RequestUrl == nil { var ret string return ret } return *o.RequestUrl }
[ -0.7370312213897705, 0.61689293384552, 0.5164147019386292, 2.068525791168213, 0.0803540050983429, 0.014614065177738667, 0.1215306967496872, -0.22994394600391388, 1.2122689485549927, -0.6256783604621887, 0.14080075919628143, -1.5662412643432617, -0.6801215410232544, 0.44780784845352173, -...
func (o *LoginRequest) GetRequestUrlOk() (*string, bool) { if o == nil || o.RequestUrl == nil { return nil, false } return o.RequestUrl, true }
[ -0.9371923208236694, 0.3950723707675934, 0.5833132863044739, 1.386693000793457, -0.29007503390312195, 0.041522298008203506, -0.0970911979675293, 0.6567778587341309, -0.1030067428946495, -0.9804906845092773, -0.40156304836273193, -0.4267761707305908, -0.3530257046222687, -0.0675894170999527...
func (o *LoginRequest) HasRequestUrl() bool { if o != nil && o.RequestUrl != nil { return true } return false }
[ -0.44602736830711365, 0.5505969524383545, 0.36993929743766785, 1.3504976034164429, 0.3730136752128601, -0.0352441668510437, -0.2172021120786667, 0.20194725692272186, 0.2739187777042389, -1.1429458856582642, -0.644526481628418, -1.4126704931259155, -0.41818949580192566, -0.00151235144585371...
func (o *LoginRequest) SetRequestUrl(v string) { o.RequestUrl = &v }
[ -1.1433203220367432, 0.16820871829986572, 0.1279386729001999, 1.2238409519195557, -0.6804168820381165, 0.2705002427101135, -0.5949029326438904, -0.7506743669509888, 0.5799604058265686, -0.21316786110401154, 0.19091102480888367, 0.41038861870765686, -0.15097323060035706, -0.7901526689529419...
func (o *LoginRequest) GetRequestedAccessTokenAudience() []string { if o == nil || o.RequestedAccessTokenAudience == nil { var ret []string return ret } return o.RequestedAccessTokenAudience }
[ -0.4414774775505066, -0.6982983350753784, 0.6040398478507996, 0.7047742605209351, 0.29220789670944214, -0.2514616847038269, 0.10941203683614731, -0.340297132730484, 0.06772409379482269, -0.6758113503456116, 0.10979072749614716, 0.28312379121780396, 0.11657319962978363, 0.8329808712005615, ...
func (o *LoginRequest) GetRequestedAccessTokenAudienceOk() ([]string, bool) { if o == nil || o.RequestedAccessTokenAudience == nil { return nil, false } return o.RequestedAccessTokenAudience, true }
[ -0.22649317979812622, -0.5715786814689636, 0.948724627494812, 0.49980151653289795, -0.0439177006483078, -0.07157521694898605, 0.3093346357345581, 0.5155105590820312, -0.025163311511278152, 0.03805815801024437, 0.1593462973833084, -0.2065907120704651, 0.9767130017280579, 0.6062265634536743,...
func (o *LoginRequest) HasRequestedAccessTokenAudience() bool { if o != nil && o.RequestedAccessTokenAudience != nil { return true } return false }
[ -0.0791749581694603, -0.3841905891895294, 0.5428493618965149, 0.07619478553533554, 0.4593786895275116, -0.9045659303665161, -0.10343923419713974, 0.609950065612793, -0.1838284283876419, -1.07697331905365, 0.07042603194713593, -0.25573763251304626, 0.6428791284561157, 0.8312286734580994, ...
func (o *LoginRequest) SetRequestedAccessTokenAudience(v []string) { o.RequestedAccessTokenAudience = v }
[ -1.258213758468628, -1.0540210008621216, 0.4132188558578491, 0.19534620642662048, 0.1474720984697342, -0.011977271176874638, -0.10363342612981796, -0.3110429346561432, 0.10965022444725037, -0.20321233570575714, 0.0749572217464447, 0.4772154688835144, 0.22892947494983673, 0.5432146787643433...
func (o *LoginRequest) GetRequestedScope() []string { if o == nil || o.RequestedScope == nil { var ret []string return ret } return o.RequestedScope }
[ -1.2257585525512695, -0.18095360696315765, 0.24459312856197357, 0.9572116732597351, 0.3767125606536865, -0.3106539845466614, 0.1158025786280632, -0.29316943883895874, 1.0327686071395874, -0.8905516862869263, 0.19980724155902863, 0.7718165516853333, -0.807763934135437, 0.4417826235294342, ...
func (o *LoginRequest) GetRequestedScopeOk() ([]string, bool) { if o == nil || o.RequestedScope == nil { return nil, false } return o.RequestedScope, true }
[ -1.4098113775253296, -0.2788599729537964, 0.4657215178012848, 0.2484418749809265, -0.062031883746385574, -0.1647903174161911, 0.5645135045051575, 0.6440359354019165, 0.6730246543884277, 0.2878408432006836, -0.9201672077178955, 0.3255062699317932, -0.183844193816185, 0.6784128546714783, 0...
func (o *LoginRequest) HasRequestedScope() bool { if o != nil && o.RequestedScope != nil { return true } return false }
[ -0.9115189909934998, 0.3937302827835083, 0.10318785905838013, -0.029478294774889946, 0.6541193723678589, -0.8835014700889587, -0.16687224805355072, 0.34803307056427, 0.6961569786071777, -1.0840792655944824, -0.3195078670978546, -0.26999157667160034, -0.2902372479438782, 0.5501260757446289,...
func (o *LoginRequest) SetRequestedScope(v []string) { o.RequestedScope = v }
[ -2.486051559448242, -0.24994757771492004, 0.06381924450397491, -0.006908501032739878, 0.04067615419626236, -0.26614677906036377, -0.14988188445568085, -0.6568103432655334, 0.7905142903327942, -0.14393775165081024, -0.43311935663223267, 0.8535970449447632, -0.4899253249168396, 0.33056002855...
func (o *LoginRequest) GetSessionId() string { if o == nil || o.SessionId == nil { var ret string return ret } return *o.SessionId }
[ 0.7795048356056213, -0.7194726467132568, 0.38270267844200134, 1.2140023708343506, -0.050920143723487854, 0.19148406386375427, 0.9215775728225708, -0.8352154493331909, 2.262495279312134, 0.025530222803354263, 0.06597226113080978, -0.8636662364006042, -0.7499942779541016, 0.90516197681427, ...
func (o *LoginRequest) GetSessionIdOk() (*string, bool) { if o == nil || o.SessionId == nil { return nil, false } return o.SessionId, true }
[ 0.021702732890844345, -0.4970090687274933, 0.46697455644607544, 1.1133917570114136, 0.4229721426963806, 0.20790478587150574, 1.260994791984558, -0.062345247715711594, 1.1418203115463257, 0.4484303593635559, -0.9011329412460327, -0.6580435037612915, -0.23352301120758057, 0.30178067088127136...
func (o *LoginRequest) HasSessionId() bool { if o != nil && o.SessionId != nil { return true } return false }
[ 0.7035568356513977, -0.66118323802948, 0.3546887934207916, 0.5840599536895752, 0.17093180119991302, -0.3238988518714905, 0.09488660097122192, 0.10282351076602936, 1.6361440420150757, 0.1149989664554596, -0.3954436182975769, -0.5560777187347412, -0.22755786776542664, 0.5380681753158569, -...
func (o *LoginRequest) SetSessionId(v string) { o.SessionId = &v }
[ 0.5999933481216431, -0.9247778654098511, 0.1061386689543724, 0.5139221549034119, -1.1404627561569214, 0.2720530331134796, 0.015997661277651787, -1.1306748390197754, 1.37383234500885, 0.4821992814540863, -0.1932182013988495, 1.2003793716430664, -0.3416125774383545, -0.1914694458246231, -0...
func (o *LoginRequest) GetSkip() bool { if o == nil || o.Skip == nil { var ret bool return ret } return *o.Skip }
[ -0.6666384935379028, 0.586742639541626, 0.5379968881607056, 0.8779895901679993, -0.543631374835968, -0.1024363562464714, 0.9331021308898926, -0.008911804296076298, 0.7047882080078125, -0.686586856842041, 0.17528432607650757, -1.3418275117874146, -0.3559320867061615, -0.4045546054840088, ...
func (o *LoginRequest) GetSkipOk() (*bool, bool) { if o == nil || o.Skip == nil { return nil, false } return o.Skip, true }
[ -1.4387387037277222, 0.7553274631500244, 0.6747602820396423, 0.600223958492279, 0.2797129154205322, 0.3678593933582306, 0.5573574304580688, 0.9754132032394409, -0.07168412208557129, -0.4678431749343872, -0.7942099571228027, -1.0289040803909302, 0.7003940343856812, -0.1839960217475891, 0....
func (o *LoginRequest) HasSkip() bool { if o != nil && o.Skip != nil { return true } return false }
[ -0.47815170884132385, 0.6455131769180298, 0.5880327224731445, 0.4490249752998352, 0.4314061105251312, -0.22625485062599182, -0.03206637501716614, 0.4981353282928467, 0.2809120714664459, -0.4679741859436035, -0.3267346918582916, -1.885850191116333, 0.40254685282707214, -0.8606458902359009, ...
func (o *LoginRequest) SetSkip(v bool) { o.Skip = &v }
[ -0.9250600337982178, 0.947344183921814, 0.11430783569812775, 0.8823637366294861, -0.7568027973175049, 0.05630961433053017, -0.18189126253128052, -0.9958293437957764, 0.07433678209781647, 0.43062224984169006, 0.1783335953950882, -0.26443901658058167, 0.3442670404911041, -1.5316755771636963,...
func (o *LoginRequest) GetSubject() string { if o == nil || o.Subject == nil { var ret string return ret } return *o.Subject }
[ 0.3790890574455261, 0.4850728213787079, 0.10168534517288208, 0.871248722076416, -0.670767605304718, -0.06686089932918549, 0.7935467958450317, -0.6948599219322205, 0.6333132982254028, -1.070215106010437, 0.3143755793571472, -1.0146692991256714, -0.3007228970527649, 0.162019744515419, 0.72...
func (o *LoginRequest) GetSubjectOk() (*string, bool) { if o == nil || o.Subject == nil { return nil, false } return o.Subject, true }
[ 0.3446078896522522, 0.016481362283229828, 0.5647906064987183, 0.7271682620048523, -0.6723666787147522, 0.24244529008865356, 0.5848659873008728, 0.2878115773200989, -0.0275444183498621, 0.5453014373779297, -0.588848888874054, -0.3760134279727936, 0.5330067276954651, 0.233439102768898, 0.0...
func (o *LoginRequest) HasSubject() bool { if o != nil && o.Subject != nil { return true } return false }
[ 0.5436825156211853, 0.36246269941329956, 0.1881788969039917, 0.16114090383052826, -0.24494557082653046, -0.19031307101249695, -0.19498825073242188, 0.08097624033689499, -0.08131241798400879, -1.560483455657959, -0.5054796934127808, -0.8905187249183655, 0.2788851261138916, -0.30872642993927...
func (o *LoginRequest) SetSubject(v string) { o.Subject = &v }
[ -0.11422600597143173, 0.18399378657341003, -0.3635915219783783, 0.015688521787524223, -1.7642828226089478, 0.012200922705233097, -0.3459565043449402, -1.456470251083374, -0.006690304260700941, -0.5632925033569336, 0.1622576117515564, 1.0567313432693481, -0.23002319037914276, -0.75301587581...
func GetKVPairs(tags []string, delimiter string) ([]*KV, error) { pairs := make([]*KV, 0) if delimiter == "" { delimiter = "=" } for _, tag := range tags { // loop through the device tags // match any tag that is of the form key=value matched, err := regexp.MatchString(".+"+delimiter+".+", tag) if err != ...
[ -0.8423029184341431, 0.331914484500885, 0.6803511381149292, 0.9355965256690979, -1.1551510095596313, -0.4882681667804718, -1.1872727870941162, 0.22034761309623718, -0.6535251140594482, 0.9136929512023926, 0.055436789989471436, -0.8810172080993652, -0.7124075293540955, 0.5512369871139526, ...
func GetKVsByKey(tags []string, key, delimiter string) ([]*KV, error) { kvs, err := GetKVPairs(tags, delimiter) if err != nil { return nil, err } foundKvs := make([]*KV, 0) for _, kv := range kvs { if kv.Key == key { foundKvs = append(foundKvs, kv) } } return foundKvs, nil }
[ -0.2713693380355835, 0.2223070114850998, 0.5898450613021851, 1.3036302328109741, -1.0204113721847534, -0.7193282842636108, -1.4121582508087158, -0.03882787376642227, -0.5704919695854187, 1.2091343402862549, 0.18335914611816406, -0.48426321148872375, -0.08653721213340759, 0.8043781518936157...
func AddTag(client *packngo.Client, deviceID, tag string) error { device, _, err := client.Devices.Get(deviceID) if err != nil { return err } tags := append(device.Tags, tag) client.Devices.Update(deviceID, &packngo.DeviceUpdateRequest{ Tags: &tags, }) return nil }
[ -0.2414548397064209, 0.22723200917243958, 0.4415211081504822, 0.03614658862352371, 0.334877073764801, 0.16713960468769073, -0.9194302558898926, 0.0512772873044014, -0.2630866467952728, 0.04480726644396782, 0.2014898806810379, 0.10346966236829758, -0.35230594873428345, 1.0626505613327026, ...
func RemoveTag(client *packngo.Client, deviceID, tag string) error { device, _, err := client.Devices.Get(deviceID) if err != nil { return err } tags := make([]string, 0) for _, t := range device.Tags { if t != tag { tags = append(tags, t) } } client.Devices.Update(deviceID, &packngo.DeviceUpdateRequest...
[ -0.5148487687110901, -0.22522364556789398, 0.2367820143699646, -0.22656017541885376, 0.0821879431605339, -0.3564753830432892, -0.4700520932674408, 0.5491644740104675, -0.33093884587287903, 0.968231737613678, -0.33493921160697937, -0.016816692426800728, -0.7124062180519104, 0.87537211179733...
func UpdateTag(client *packngo.Client, deviceID, tag, newTag string) error { device, _, err := client.Devices.Get(deviceID) if err != nil { return err } tags := make([]string, 0) for _, t := range device.Tags { if t == tag { t = newTag } tags = append(tags, t) } client.Devices.Update(deviceID, &packng...
[ -0.8567313551902771, -0.7211945056915283, 0.1961435079574585, -0.11310268193483353, 0.14356175065040588, -0.11103332787752151, -0.7079986929893494, -0.1092139482498169, -0.6717722415924072, 1.2481309175491333, -0.23096409440040588, 0.5296159982681274, -0.34081754088401794, 1.01071143150329...
func (p *Noise) addNoise(value interface{}) interface{} { n := p.generator.Rand() switch v := value.(type) { case int: case int8: case int16: case int32: case int64: if v > 0 && (n > math.Nextafter(float64(math.MaxInt64), 0) || int64(n) > math.MaxInt64-v) { p.Log.Debug("Int64 overflow, setting value to MaxI...
[ -0.6840925812721252, 0.645729660987854, 0.8086937069892883, 0.3022935390472412, 0.22092466056346893, -0.013154452666640282, 0.017411302775144577, -0.967462420463562, 0.6291073560714722, -0.6426368951797485, 1.0114977359771729, -0.48170462250709534, -1.0012949705123901, 1.0926718711853027, ...
func (p *Noise) Init() error { fieldFilter, err := filter.NewIncludeExcludeFilter(p.IncludeFields, p.ExcludeFields) if err != nil { return fmt.Errorf("creating fieldFilter failed: %w", err) } p.fieldFilter = fieldFilter switch p.NoiseType { case "", "laplacian": p.generator = &distuv.Laplace{Mu: p.Mu, Scale:...
[ -0.5160922408103943, -0.07744003087282181, 0.6581409573554993, -0.7821455001831055, 0.33876508474349976, 0.7368305325508118, -0.1626645177602768, 0.4930327236652374, -0.5363454222679138, -0.40901607275009155, -0.248459592461586, 0.8852452039718628, -0.17108440399169922, 0.7475128173828125,...
func (p *AzureProvider) GetExternalMetric(namespace string, metricSelector labels.Selector, info provider.ExternalMetricInfo) (*external_metrics.ExternalMetricValueList, error) { // Note: // metric name and namespace is used to lookup for the CRD which contains configuration to call azure // if not found then ign...
[ -0.05824296921491623, 0.4845878481864929, 0.8543537259101868, 0.4533536732196808, -0.44266626238822937, 0.49418753385543823, -0.5345978140830994, -0.16046984493732452, -0.3142499029636383, 0.9549530744552612, 0.7482767701148987, 0.423910528421402, -0.6213850975036621, 0.5560781359672546, ...
func (p *AzureProvider) ListAllExternalMetrics() []provider.ExternalMetricInfo { externalMetricsInfo := []provider.ExternalMetricInfo{} // not implemented yet // TODO // iterate over all of the resources we have access // build metric info from https://docs.microsoft.com/en-us/azure/monitoring-and-diagnostics/mo...
[ 0.22111600637435913, -0.3297429382801056, 0.49886152148246765, 0.060290876775979996, -0.5881731510162354, 0.47300177812576294, -0.6573560237884521, -0.16679833829402924, 0.04264337942004204, 0.12060060352087021, 0.10513706505298615, 1.1042195558547974, -0.5305442214012146, 1.23176681995391...
func newFormat(format string) eval.Format { return parseFormat(format, NO_STRING, NO_STRING, nil) }
[ 0.5753927826881409, -0.9075205326080322, 0.17244206368923187, -0.4596133530139923, -1.275933861732483, -0.9599283933639526, -0.7432214021682739, -0.021954763680696487, 0.15782199800014496, -1.205028772354126, 0.9293917417526245, 0.6333306431770325, 0.2669661343097687, 0.15795981884002686, ...
func TestShortestQueueArrBehBeforeAssignWithOverride(t *testing.T) { t.Parallel() var queues []*Queue var procs []*Processor var j, receivedJob *Job var ab ArrBeh var i int queues = make([]*Queue, 3) for i = 0; i < 3; i++ { queues[i] = NewQueue() queues[i].QueueId = i } procs = make([]*Processor, 3) for...
[ 0.656237006187439, -0.8152555227279663, 0.8272121548652649, -0.7311393022537231, 0.07379478216171265, -0.7541888356208801, 0.21436463296413422, -0.310131698846817, 0.3757205605506897, -0.05074084922671318, -0.26901963353157043, 0.18757668137550354, -0.4134206473827362, 1.1491737365722656, ...
func (p Prometheus) Name() string { return "Prometheus probe for " + p.URL + " [" + p.Key + "]" }
[ -0.535912036895752, -0.4609295427799225, 0.5498523116111755, -0.2866373360157013, -0.7969241142272949, 0.3306911289691925, -1.093465805053711, 0.22813796997070312, -0.37747082114219666, 2.0320181846618652, 0.28038275241851807, -0.009266202338039875, -0.5020067095756531, 0.11648755520582199...
func (p Prometheus) Value() (float64, error) { resp, err := http.Get(p.URL) if err != nil { return -1.0, err } if resp.StatusCode != http.StatusOK { return -1.0, err } fvalue, err := p.findValue(resp.Body) if err != nil { return -1.0, err } return fvalue, nil }
[ -0.0408126600086689, 0.29215800762176514, 0.6606782674789429, 0.322632372379303, 0.6238104701042175, 0.4030320346355438, -0.3088911473751068, -0.6752193570137024, -0.2054024040699005, 0.23030981421470642, 1.1469143629074097, 0.76729816198349, -0.9910382628440857, 0.5722799897193909, 0.42...
func (p Prometheus) findValue(body io.Reader) (float64, error) { scanLines := bufio.NewScanner(body) for scanLines.Scan() { // for each line // now we're splitting by spaces scanWords := bufio.NewScanner(strings.NewReader(scanLines.Text())) scanWords.Split(bufio.ScanWords) if scanWords.Scan() { // line is no...
[ 0.44508084654808044, 0.01059012208133936, 0.6579098701477051, -0.06291273981332779, 0.22233246266841888, -0.7289446592330933, -0.4231712818145752, 0.1355160027742386, -1.0798115730285645, 0.34500014781951904, 1.2220948934555054, 0.1497187316417694, -0.878933310508728, 1.6312315464019775, ...
func NewInfo(path string) *Info { c := &Info{ path: path, } c.Load() return c }
[ 0.8230118751525879, -0.8491804003715515, 0.05553610250353813, 0.12909142673015594, -0.7829696536064148, 0.43189194798469543, 0.03631940111517906, -0.7913916110992432, -0.714472234249115, -0.43076273798942566, -0.30899935960769653, 0.34075599908828735, 0.5824348330497742, -0.288688629865646...
func (c *Info) Save() error { c.RLock() b, _ := json.MarshalIndent(c, "", "\t") c.RUnlock() // We try to make the file owner by the directory owner, if the file // doesn't exist. if _, err := os.Stat(c.path); os.IsNotExist(err) { var st syscall.Stat_t // If the parent directory doesn't exist, we should retu...
[ -0.00608071917667985, -0.10036556422710419, 0.6175790429115295, -0.5436387062072754, 0.8054250478744507, -0.2640293538570404, 0.5115251541137695, -0.7745504975318909, -0.956794023513794, -0.1881919652223587, -0.35721519589424133, -0.1813724786043167, 0.16264081001281738, 0.0220137573778629...
func (c *Info) Load() error { b, err := ioutil.ReadFile(c.path) if err != nil { return err } c.Lock() err = json.Unmarshal(b, c) c.Unlock() return err }
[ -0.15748758614063263, -0.1752566695213318, 0.7356166243553162, -1.1661174297332764, 0.10940825939178467, 0.2530346214771271, -0.41082876920700073, -0.5443923473358154, -1.5393742322921753, 0.22495250403881073, -0.41368937492370605, -0.4096914529800415, -0.6830594539642334, -1.3658820390701...
func (c *Info) Self() string { c.RLock() self := c.SelfName c.RUnlock() return self }
[ -0.13613787293434143, -1.2315428256988525, 0.39797312021255493, 0.3101755678653717, -0.4130970239639282, 0.6473760008811951, 1.2931050062179565, -0.7416321635246277, -0.8308731913566589, -0.8130285739898682, -0.4341698884963989, 0.18864993751049042, -0.5684333443641663, -0.4127286672592163...
func (c *Info) IP() net.IP { self := c.Self() s, err := net.ResolveTCPAddr("tcp", DefaultPort(self)) if err != nil { return nil } return s.IP }
[ 0.20448726415634155, 0.46137088537216187, 0.3720741271972656, 0.7619200944900513, 0.526962399482727, 0.46137359738349915, 0.6735745072364807, 0.6419513821601868, -0.6837928295135498, -0.5701981782913208, 0.6548899412155151, -1.1369140148162842, -0.42763274908065796, -0.6404153108596802, ...
func (c *Info) SetSelf(self string) error { c.Lock() c.SelfName = self c.Unlock() return c.Save() }
[ -0.21103130280971527, -0.8621616959571838, 0.08129662275314331, 0.2939491868019104, -0.6526415348052979, 0.5305770039558411, 0.8203647136688232, 0.29029935598373413, -0.5717385411262512, -0.21128033101558685, -1.6313875913619995, 0.4265328347682953, -0.5730319023132324, 0.14602543413639069...
func DefaultPort(hostport string) string { if !strings.ContainsRune(hostport, ':') { return hostport + ":" + "4934" } return hostport }
[ 0.9268100261688232, 0.2532319724559784, 0.18669919669628143, 0.5168198347091675, 0.42506179213523865, 0.3866227865219116, -0.16061469912528992, 0.22833040356636047, 0.4128534197807312, -0.14927847683429718, 0.6205360293388367, -0.7843071818351746, -0.9243493676185608, -0.09008120000362396,...
func LoadApp() *App { cls := config.DefaultConfigLoaders() cfg := config.LoadConfig(cls) l := gerr.NewSimpleLog() th := translation.NewTranslatorHelper() return &App{ cfg: cfg, l: l, th: th, } }
[ 0.7093269228935242, -0.21989746391773224, 0.45571428537368774, 0.5925153493881226, -0.8593385219573975, 0.529583752155304, -0.40973424911499023, -0.3586278557777405, 0.44770294427871704, 0.24793680012226105, -0.5076494216918945, -1.0300159454345703, -0.34951165318489075, 0.3108140826225281...
func createTarget(s *scope, args []pyObject) *core.BuildTarget { isTruthy := func(i int) bool { return args[i] != nil && args[i] != None && args[i].IsTruthy() } name := string(args[nameBuildRuleArgIdx].(pyString)) testCmd := args[testCMDBuildRuleArgIdx] test := isTruthy(testBuildRuleArgIdx) // A bunch of error ...
[ -0.451930969953537, -0.8772475123405457, 0.5946006774902344, -0.2087147831916809, 0.6459366679191589, 0.12727993726730347, -0.1016262024641037, -0.14842301607131958, -0.1913147121667862, -0.16729198396205902, 0.10435393452644348, 0.5143657326698303, -0.4779042899608612, -0.2539826929569244...
func validateSandbox(state *core.BuildState, target *core.BuildTarget) error { if target.IsFilegroup || len(state.Config.Sandbox.ExcludeableTargets) == 0 { return nil } if !target.IsRemoteFile { if target.Sandbox && (target.Test == nil || target.Test.Sandbox) { return nil } } if target.Label.PackageName ...
[ -0.807567298412323, -0.10011564195156097, 0.680695116519928, -0.1933886557817459, 0.25962385535240173, 0.31416553258895874, -0.5181698799133301, -0.2620753049850464, 0.8269620537757874, 0.5276673436164856, 0.5102866291999817, 0.5776856541633606, -0.06125745549798012, 0.5158541202545166, ...
func sizeAndTimeout(s *scope, size *core.Size, timeout pyObject, defaultTimeout cli.Duration) time.Duration { switch t := timeout.(type) { case pyInt: if t > 0 { return time.Duration(t) * time.Second } case pyString: return time.Duration(mustSize(s, string(t)).Timeout) } if size != nil { return time.Dur...
[ 0.5541499257087708, -0.40992775559425354, 0.37987780570983887, -0.3250051438808441, -0.20235705375671387, -0.5240569710731506, -0.524447500705719, 0.14418792724609375, 0.7068610191345215, 1.5265910625457764, -0.005818870849907398, 0.4586915969848633, 0.13234160840511322, 0.1182462573051452...
func mustSize(s *scope, name string) *core.Size { size, present := s.state.Config.Size[name] s.Assert(present, "Unknown size %s", name) return size }
[ -0.3438170254230499, 0.5726249814033508, 0.5034029483795166, -0.16268478333950043, -0.19606603682041168, 0.22872698307037354, -0.33226513862609863, -0.5515834093093872, 0.920174241065979, 0.6501786112785339, -0.1795101910829544, -0.2035549134016037, -0.7807274460792542, 0.4378994107246399,...
func decodeCommands(s *scope, obj pyObject) (string, map[string]string) { if obj == nil || obj == None { return "", nil } else if cmd, ok := obj.(pyString); ok { return strings.TrimSpace(string(cmd)), nil } cmds, ok := asDict(obj) s.Assert(ok, "Unknown type for command [%s]", obj.Type()) // Have to convert al...
[ -0.7031554579734802, -0.9650371074676514, 0.49641934037208557, -0.6552635431289673, -0.15157054364681244, -1.3966602087020874, -0.17700281739234924, -0.2792562246322632, 0.8617057800292969, 0.043554872274398804, -0.10775444656610489, 0.1654871553182602, 0.47360941767692566, 1.0212137699127...
func populateTarget(s *scope, t *core.BuildTarget, args []pyObject) { if t.IsRemoteFile { for _, url := range mustList(args[urlsBuildRuleArgIdx]) { t.AddSource(core.URLLabel(url.(pyString))) } } else if t.IsTextFile { t.FileContent = args[fileContentArgIdx].(pyString).String() } addMaybeNamed(s, "srcs", ar...
[ -0.6302395462989807, -0.5926939845085144, 0.5930434465408325, -0.9509053826332092, 0.8014165759086609, 0.1527237892150879, -0.033983830362558365, -0.09498918056488037, 0.019126690924167633, 0.3743334114551544, -0.07698030024766922, 0.41707608103752136, 0.32976865768432617, 0.33327585458755...
func addEntryPoints(s *scope, arg pyObject, target *core.BuildTarget) { entryPointsPy, ok := asDict(arg) s.Assert(ok, "entry_points must be a dict") entryPoints := make(map[string]string, len(entryPointsPy)) for name, entryPointPy := range entryPointsPy { entryPoint, ok := entryPointPy.(pyString) s.Assert(ok, ...
[ -0.35240671038627625, -0.7302525639533997, 0.31279218196868896, -0.32110822200775146, -0.17040888965129852, 0.026073286309838295, 0.30174756050109863, 0.3182743787765503, 0.3464028537273407, 0.5738321542739868, -0.2941047251224518, 0.11194801330566406, 0.14860029518604279, 0.76399010419845...
func addEnv(s *scope, arg pyObject, target *core.BuildTarget) { envPy, ok := asDict(arg) s.Assert(ok, "env must be a dict") env := make(map[string]string, len(envPy)) for name, val := range envPy { v, ok := val.(pyString) s.Assert(ok, "Values of env must be strings, found %v at key %v", val.Type(), name) env...
[ -1.3879482746124268, -0.5495093464851379, 0.6216720342636108, -0.45139098167419434, 0.4602009654045105, 0.5666379332542419, -0.10980609059333801, 0.40990906953811646, -0.29868796467781067, 0.5358825922012329, -0.0003002044395543635, 0.7155225276947021, 0.6847533583641052, 0.496603697538375...
func addMaybeNamed(s *scope, name string, obj pyObject, anon func(core.BuildInput), named func(string, core.BuildInput), systemAllowed, tool bool) { if obj == nil { return } if l, ok := asList(obj); ok { for _, li := range l { if bi := parseBuildInput(s, li, name, systemAllowed, tool); bi != nil { anon(bi...
[ -0.06028583645820618, -0.0975746363401413, 0.8426676988601685, 0.07271788269281387, -0.20874890685081482, 0.4876699149608612, 0.008574502542614937, -0.11661987751722336, 0.6171435117721558, -0.3466646075248718, -0.46890243887901306, 0.6205760836601257, -0.3973824977874756, 1.44390606880187...
func addMaybeNamedOrString(s *scope, name string, obj pyObject, anon func(core.BuildInput), named func(string, core.BuildInput), systemAllowed, tool bool) { if obj == nil { return } if str, ok := asString(obj); ok { if bi := parseBuildInput(s, str, name, systemAllowed, tool); bi != nil { anon(bi) } return...
[ -0.11821099370718002, -1.013279914855957, 0.5784118175506592, -0.05287010595202446, -1.2032601833343506, 0.8769351243972778, 0.11247431486845016, -0.7953317761421204, 0.8366377949714661, -0.3683496415615082, -0.6772845387458801, 0.6987259387969971, 0.2995684742927551, 0.5440443158149719, ...
func addMaybeNamedOutput(s *scope, name string, obj pyObject, anon func(string), named func(string, string), t *core.BuildTarget, optional bool) { if obj == nil { return } if l, ok := asList(obj); ok { for _, li := range l { if li != None { out, ok := li.(pyString) s.Assert(ok, "outs must be strings")...
[ -0.35608142614364624, -0.15370231866836548, 0.8846902251243591, -0.34657639265060425, -0.34698185324668884, -0.34679263830184937, 0.007247117348015308, -0.06881897896528244, 0.8857607841491699, 0.17429493367671967, -0.288506418466568, 0.04989396035671234, 0.3104948103427887, 1.001027584075...
func addMaybeNamedSecret(s *scope, name string, obj pyObject, anon func(string), named func(string, string), t *core.BuildTarget, optional bool) { validateSecret := func(secret string) { s.NAssert(strings.HasPrefix(secret, "//"), "Secret %s of %s cannot be a build label", secret, t.Label.Name) s.Assert(filepath...
[ -0.41723015904426575, -0.4823007583618164, 0.8591598272323608, -0.01805168017745018, -0.4973272979259491, 0.43973636627197266, -0.5076335072517395, -0.5210905075073242, 0.5204758644104004, 0.008174735121428967, -0.7736362814903259, 0.5245132446289062, 0.3183150589466095, 1.238720417022705,...
func addDependencies(s *scope, name string, obj pyObject, target *core.BuildTarget, exported, internal bool) { addStrings(s, name, obj, func(str string) { if s.state.Config.Bazel.Compatibility && !core.LooksLikeABuildLabel(str) && !strings.HasPrefix(str, "@") { // *sigh*... Bazel seems to allow an implicit : on t...
[ -0.23323297500610352, -0.5471302270889282, 0.5682393312454224, -0.20262068510055542, -0.2526397705078125, 0.6202312111854553, 0.10328496992588043, 0.47380882501602173, 1.1357241868972778, 0.17623598873615265, -0.08856131881475449, -0.31928321719169617, 0.37094733119010925, -0.0567756593227...
func addStrings(s *scope, name string, obj pyObject, f func(string)) { if obj != nil && obj != None { l, ok := asList(obj) if !ok { s.Error("Argument %s must be a list, not %s", name, obj.Type()) } for _, li := range l { str, ok := li.(pyString) if !ok && li != None { s.Error("%s must be strings",...
[ -0.3306117653846741, 0.015109702944755554, 0.553658127784729, -0.3230249583721161, -0.042140424251556396, -0.38651201128959656, -0.21147242188453674, -0.14916066825389862, 0.3348102271556854, 0.2448921948671341, -0.05798995494842529, 0.3776322305202484, -0.08927898854017258, 0.686173617839...
func addProvides(s *scope, name string, obj pyObject, t *core.BuildTarget) { if obj != nil && obj != None { d, ok := asDict(obj) s.Assert(ok, "Argument %s must be a dict, not %s, %v", name, obj.Type(), obj) for k, v := range d { str, ok := v.(pyString) s.Assert(ok, "%s values must be strings", name) t.A...
[ -0.7447832822799683, 0.2030216008424759, 0.6319617033004761, -0.5532770156860352, 0.35075148940086365, 0.3322311341762543, -0.939983069896698, -0.2847285270690918, 0.6420963406562805, 0.9397537708282471, 0.21841931343078613, -0.12166986614465714, -0.048491720110177994, 0.41995614767074585,...
func parseVisibility(s *scope, vis string) core.BuildLabel { if vis == "PUBLIC" || (s.state.Config.Bazel.Compatibility && vis == "//visibility:public") { return core.WholeGraph[0] } l := s.parseLabelInPackage(vis, s.pkg) if s.state.Config.Bazel.Compatibility { // Bazel has a couple of special aliases for this s...
[ 0.12917883694171906, -0.6398853659629822, 0.688194990158081, 0.448546826839447, -0.08551829308271408, 0.22701764106750488, 0.47801923751831055, 0.48725607991218567, 1.0815821886062622, 1.1010491847991943, 0.1340728998184204, -0.0022596947383135557, 0.6273631453514099, 0.20239298045635223, ...
func parseSource(s *scope, src string, systemAllowed, tool bool) core.BuildInput { if core.LooksLikeABuildLabel(src) { pkg := s.pkg if tool && s.pkg.Subrepo != nil && s.pkg.Subrepo.IsCrossCompile { // Tools should be parsed with the host OS and arch pkg = &core.Package{ Name: pkg.Name, } } label :...
[ 0.09935101121664047, -0.15095274150371552, 0.5332285761833191, 0.2018817663192749, -0.6623002886772156, 0.41503390669822693, 0.6763190031051636, -0.03277847543358803, 0.6480883359909058, 0.10476529598236084, 0.035048939287662506, 0.4984073042869568, -0.012313476763665676, -0.07634897530078...
func checkLabel(s *scope, label core.BuildLabel) core.BuildLabel { s.NAssert(label.IsAllTargets(), ":all labels are not permitted here") s.NAssert(label.IsAllSubpackages(), "... labels are not permitted here") return label }
[ 0.2513248026371002, -1.0018274784088135, 0.4519192576408386, 0.4367218613624573, 0.38823163509368896, 1.364741325378418, -0.1358816921710968, 0.3687823414802551, 0.8433067202568054, 0.8052749037742615, 1.209557056427002, 0.994274377822876, -0.9361510872840881, 0.36352407932281494, 0.4015...
func callbackFunction(s *scope, name string, obj pyObject, requiredArguments int, arguments string) *pyFunc { if obj != nil && obj != None { f := obj.(*pyFunc) s.Assert(len(f.args) == requiredArguments, "%s callbacks must take exactly %d %s (%s takes %d)", name, requiredArguments, arguments, f.name, len(f.args)) ...
[ 0.3539672791957855, -0.5713716745376587, 0.5954636335372925, -0.18943890929222107, 0.1376824975013733, -0.08314454555511475, 0.8312944173812866, -0.23087741434574127, 1.0747817754745483, 0.07065662741661072, -0.28110647201538086, 0.6981289386749268, -0.26506268978118896, -0.006400284823030...
func asList(obj pyObject) (pyList, bool) { if l, ok := obj.(pyList); ok { return l, true } else if l, ok := obj.(pyFrozenList); ok { return l.pyList, true } return nil, false }
[ -0.5603176355361938, -0.9556961059570312, 0.6218760013580322, -0.007783540058881044, -0.0956742912530899, -0.5218296647071838, -0.920803427696228, -0.23781001567840576, 1.1001026630401611, 1.1409962177276611, -1.6920591592788696, -0.13311822712421417, -0.22449137270450592, 0.77484285831451...
func mustList(obj pyObject) pyList { if l, ok := asList(obj); ok { return l } return pyList{} }
[ -0.3796859085559845, -0.5164772868156433, 0.5250129699707031, 0.37080827355384827, 0.08089737594127655, 0.8214126825332642, -1.0488643646240234, -0.6180362701416016, 1.8185502290725708, 0.8192780613899231, -0.8129115104675293, 0.06731341034173965, 0.3269180655479431, 0.48321667313575745, ...
func asDict(obj pyObject) (pyDict, bool) { if d, ok := obj.(pyDict); ok { return d, true } else if d, ok := obj.(pyFrozenDict); ok { return d.pyDict, true } return nil, false }
[ -0.07709300518035889, -0.10942559689283371, 0.5736396908760071, -0.3778369724750519, -1.3445625305175781, -0.28805607557296753, -0.21819956600666046, -0.7541160583496094, 0.4169946610927582, -0.1032327339053154, -0.7686256170272827, 0.07630351930856705, 0.055159829556941986, 0.972986876964...
func asString(obj pyObject) (pyString, bool) { if s, ok := obj.(pyString); ok { return s, true } return "", false }
[ -1.1381713151931763, -0.4876370131969452, 0.5409672856330872, -0.4987523853778839, -0.30227580666542053, 0.13755960762500763, 0.3511689603328705, -0.9714378714561462, 0.5297828316688538, 1.176717758178711, -0.7667074203491211, 0.05996537581086159, 0.6803499460220337, -0.310702919960022, ...
func (v *Eth1DataVotesView) Reset() error { return v.SetBacking(v.Type().DefaultNode()) }
[ -0.4616274833679199, 1.3710103034973145, 0.1452288031578064, 0.37985023856163025, 0.9524708390235901, -0.2454998791217804, 0.09868216514587402, -0.0006295412313193083, -0.49998044967651367, 0.20707160234451294, 0.43270638585090637, 0.7575786113739014, -0.3019716739654541, -0.60106110572814...
func (thread *Thread) Authorize(ctx aero.Context, action string) error { if !ctx.HasSession() { return errors.New("Neither logged in nor in session") } if action == "edit" { user := GetUserFromContext(ctx) if thread.CreatedBy != user.ID && user.Role != "admin" { return errors.New("Can't edit the threads o...
[ -0.4674077033996582, 0.02937149628996849, 0.5680999755859375, 1.1105879545211792, 0.8425058722496033, -0.16936489939689636, 0.5800245404243469, -0.6060813665390015, 0.99237060546875, 0.8401872515678406, 0.9115616679191589, 1.6313440799713135, -0.41976070404052734, 0.1953917294740677, 0.4...
func (thread *Thread) Create(ctx aero.Context) error { data, err := ctx.Request().Body().JSONObject() if err != nil { return err } userID, ok := ctx.Session().Get("userId").(string) if !ok || userID == "" { return errors.New("Not logged in") } user, err := GetUser(userID) if err != nil { return err ...
[ -0.0056260693818330765, -0.06463538855314255, 0.9300734996795654, 0.6904410123825073, 0.8340933322906494, 0.5241797566413879, 0.5424076914787292, -0.8451483249664307, -0.037191372364759445, 0.33461660146713257, -0.23436163365840912, 0.32380208373069763, -0.9406725168228149, 0.3958203792572...