diff
stringlengths
65
26.7k
message
stringlengths
7
9.92k
diff --git a/tests/virgil-cards.js b/tests/virgil-cards.js index <HASH>..<HASH> 100644 --- a/tests/virgil-cards.js +++ b/tests/virgil-cards.js @@ -130,7 +130,7 @@ test('create private virgil card', function (t) { var token = VirgilSDK.utils.generateValidationToken( username, identityType, - process.env.VIRGIL_APP_PRIVATE_KEY.replace(/\\n/g, '\n'), + process.env.VIRGIL_APP_PRIVATE_KEY.replace(/\\n/g, '\n').replace(/\|/g, '\n'), // workaround for travis env vars process.env.VIRGIL_APP_PRIVATE_KEY_PASSWORD );
Update test, add workaround for travis env variables new lines
diff --git a/tests/big-ass-files.test.js b/tests/big-ass-files.test.js index <HASH>..<HASH> 100644 --- a/tests/big-ass-files.test.js +++ b/tests/big-ass-files.test.js @@ -4,7 +4,9 @@ describe.only('when some big files start coming in, this adapter', function() { // Set up a route which listens to uploads app.post('/upload', function (req, res, next) { assert(_.isFunction(req.file)); - req.file('avatar').upload(adapter.receive(), function (err, files) { + req.file('avatar').upload(adapter.receive({ + maxBytes: 50000000 // 50 MB + }), function (err, files) { if (err) throw err; res.statusCode = 200; return res.end();
Adjust maxBytes for the big ass file test.
diff --git a/plenum/test/client/test_client_retry.py b/plenum/test/client/test_client_retry.py index <HASH>..<HASH> 100644 --- a/plenum/test/client/test_client_retry.py +++ b/plenum/test/client/test_client_retry.py @@ -100,7 +100,7 @@ def testClientNotRetryRequestWhenReqnackReceived(looper, nodeSet, client1, origTrans = alpha.transmitToClient def nackReq(self, req, frm): - self.transmitToClient(RequestNack(*req.key, reason="testing"), frm) + self.transmitToClient(RequestNack(*req.key, "testing"), frm) def onlyTransNack(msg, remoteName): if not isinstance(msg, RequestNack):
Fix testClientNotRetryRequestWhenReqnackReceived
diff --git a/src/StreamEncryption.php b/src/StreamEncryption.php index <HASH>..<HASH> 100644 --- a/src/StreamEncryption.php +++ b/src/StreamEncryption.php @@ -31,6 +31,10 @@ class StreamEncryption // On versions affected by this bug we need to fread the stream until we // get an empty string back because the buffer indicator could be wrong $this->wrapSecure = true; + + if (PHP_VERSION_ID >= 50600) { + $this->method = STREAM_CRYPTO_METHOD_TLSv1_0_CLIENT | STREAM_CRYPTO_METHOD_TLSv1_1_CLIENT | STREAM_CRYPTO_METHOD_TLSv1_2_CLIENT; + } } public function enable(Stream $stream)
Explicitly set supported TLS version for PHP<I>+
diff --git a/Model/ExtendedFieldModel.php b/Model/ExtendedFieldModel.php index <HASH>..<HASH> 100644 --- a/Model/ExtendedFieldModel.php +++ b/Model/ExtendedFieldModel.php @@ -240,7 +240,7 @@ class ExtendedFieldModel extends FieldModel $entity->deletedId = $id; $this->dispatchEvent('post_delete', $entity, false, $event); } - + /** * @param string $object *
Actually run php-cs-fixer (for real)
diff --git a/rinoh/flowable.py b/rinoh/flowable.py index <HASH>..<HASH> 100644 --- a/rinoh/flowable.py +++ b/rinoh/flowable.py @@ -26,7 +26,7 @@ from .dimension import DimensionBase, PT from .draw import ShapeStyle, Rectangle, Line, LineStyle, Stroke from .layout import (InlineDownExpandingContainer, VirtualContainer, MaybeContainer, discard_state, ContainerOverflow, - EndOfContainer, PageBreakException) + EndOfContainer, PageBreakException, CONTENT) from .style import Styled, Style, OptionSet, Attribute, Bool from .text import StyledText from .util import ReadAliasAttribute, NotImplementedAttribute @@ -118,7 +118,8 @@ class Flowable(Styled): as specified in its style's `space_above` attribute. Similarly, the flowed content is followed by a vertical space with a height given by the `space_below` style attribute.""" - container.page._empty = False + if container.type == CONTENT: + container.page._empty = False top_to_baseline = 0 state = state or self.initial_state(container) if state.initial:
Fix infinite loop. Non-content containers should not influence a page's "emptyness".
diff --git a/fragments/config.py b/fragments/config.py index <HASH>..<HASH> 100644 --- a/fragments/config.py +++ b/fragments/config.py @@ -55,6 +55,7 @@ class FragmentsConfig(dict): except Exception, exc: raise ConfigurationFileCorrupt(exc.message) self.update(parsed_json) + self['version'] = tuple(self['version']) else: raise ConfigurationFileNotFound("Could not access %r, if the file exists, check its permissions" % self.path)
config['version'] should always be a tuple
diff --git a/api/src/opentrons/api/session.py b/api/src/opentrons/api/session.py index <HASH>..<HASH> 100755 --- a/api/src/opentrons/api/session.py +++ b/api/src/opentrons/api/session.py @@ -135,6 +135,7 @@ class Session(object): self.modules = None self.metadata = {} self.api_level = None + self.protocol_text = protocol.text self.startTime = None self._motion_lock = motion_lock diff --git a/api/tests/opentrons/api/test_session.py b/api/tests/opentrons/api/test_session.py index <HASH>..<HASH> 100755 --- a/api/tests/opentrons/api/test_session.py +++ b/api/tests/opentrons/api/test_session.py @@ -138,6 +138,7 @@ async def test_load_and_run_v2( session.run() assert len(session.command_log) == 4, \ "Clears command log on the next run" + assert session.protocol_text == protocol.text @pytest.mark.api1_only @@ -183,6 +184,7 @@ async def test_load_and_run( session.run() assert len(session.command_log) == 6, \ "Clears command log on the next run" + assert session.protocol_text == protocol.text def test_init(run_session):
fix(api): reflect protocol text over rpc (#<I>) The session needs a protocol text member exposed via rpc to let apps that aren't the one that uploaded the protocol see what the protocol was. The app also relies on it (perhaps incorrectly) in a couple ways, for instance the creation method, and without this exposed it can't decide what it is. In addition, add a test to catch the regression in the future.
diff --git a/lib/twostroke/runtime/lib/string.rb b/lib/twostroke/runtime/lib/string.rb index <HASH>..<HASH> 100644 --- a/lib/twostroke/runtime/lib/string.rb +++ b/lib/twostroke/runtime/lib/string.rb @@ -44,7 +44,7 @@ module Twostroke::Runtime md = re.match s, offset break unless md && (offset.zero? || global) retn << md.pre_match[offset..-1] - retn << Types.to_string(callback.(scope, nil, [*md.to_a.map { |c| Types::String.new c }, Types::Number.new(md.begin 0), sobj])).string + retn << Types.to_string(callback.(scope, nil, [*md.to_a.map { |c| Types::String.new(c || "") }, Types::Number.new(md.begin 0), sobj])).string offset = md.end 0 end
avoid passing nil into Types::String.new
diff --git a/lib/itamae/recipe.rb b/lib/itamae/recipe.rb index <HASH>..<HASH> 100644 --- a/lib/itamae/recipe.rb +++ b/lib/itamae/recipe.rb @@ -2,6 +2,8 @@ require 'itamae' module Itamae class Recipe + NotFoundError = Class.new(StandardError) + attr_reader :path attr_reader :runner attr_reader :dependencies @@ -55,6 +57,9 @@ module Itamae def include_recipe(target) target = ::File.expand_path(target, File.dirname(@path)) + unless File.exist?(target) + raise NotFoundError, "File not found. (#{target})" + end recipe = Recipe.new(@runner, target) @dependencies << recipe end
If a file to be included doesn't exist, raise an error.
diff --git a/shardingsphere-db-protocol/shardingsphere-db-protocol-postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/generic/PostgreSQLCommandCompletePacket.java b/shardingsphere-db-protocol/shardingsphere-db-protocol-postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/generic/PostgreSQLCommandCompletePacket.java index <HASH>..<HASH> 100644 --- a/shardingsphere-db-protocol/shardingsphere-db-protocol-postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/generic/PostgreSQLCommandCompletePacket.java +++ b/shardingsphere-db-protocol/shardingsphere-db-protocol-postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/generic/PostgreSQLCommandCompletePacket.java @@ -46,7 +46,7 @@ public final class PostgreSQLCommandCompletePacket implements PostgreSQLIdentifi return; } String delimiter = "INSERT".equals(sqlCommand) ? " 0 " : " "; - payload.writeStringNul(String.join(delimiter, sqlCommand, Long.toString(rowCount))); + payload.writeStringNul(sqlCommand + delimiter + rowCount); } @Override
Simplify String concat in PostgreSQLCommandCompletePacket (#<I>)
diff --git a/tests/test_popobject_create.py b/tests/test_popobject_create.py index <HASH>..<HASH> 100644 --- a/tests/test_popobject_create.py +++ b/tests/test_popobject_create.py @@ -97,7 +97,8 @@ class testMlocusPopCreate(unittest.TestCase): def testConstruction(self): pop = fwdpy11.MlocusPop(self.diploids, self.gametes, self.mutations) - self.assertTrue(pop.N, 1) + self.assertEqual(pop.N, 1) + self.assertEqual(pop.nloci, 2) def testStaticMethod(self): pop = fwdpy11.MlocusPop.create(
test that MlocusPop.nloci is assigned
diff --git a/js/language/c.js b/js/language/c.js index <HASH>..<HASH> 100644 --- a/js/language/c.js +++ b/js/language/c.js @@ -50,13 +50,13 @@ Rainbow.extend('c', [ 3: 'storage.type', 4: 'entity.name.function' }, - 'pattern': /\b((un)?signed|const)?\s?(void|char|short|int|long|float|double)\*?\s+((\w+)(?=\())?/g + 'pattern': /\b((un)?signed|const)?\s?(void|char|short|int|long|float|double)\*?\s+((\w+)(?=\s?\())?/g }, { 'matches': { 2: 'entity.name.function' }, - 'pattern': /(\w|\*)(\s(\w+)(?=\())?/g + 'pattern': /(\w|\*)(\s(\w+)(?=\s?\())?/g }, { 'name': 'storage.modifier',
Add support for functions with spaces before the parenthesis
diff --git a/spec/functional/resource/deploy_revision_spec.rb b/spec/functional/resource/deploy_revision_spec.rb index <HASH>..<HASH> 100644 --- a/spec/functional/resource/deploy_revision_spec.rb +++ b/spec/functional/resource/deploy_revision_spec.rb @@ -42,14 +42,16 @@ describe Chef::Resource::DeployRevision, :unix_only => true do FileUtils.remove_entry_secure observe_order_file end - ohai = Ohai::System.new - ohai.require_plugin("os") + before(:all) do + @ohai = Ohai::System.new + @ohai.require_plugin("os") + end let(:node) do Chef::Node.new.tap do |n| n.name "rspec-test" - n.consume_external_attrs(ohai.data, {}) + n.consume_external_attrs(@ohai.data, {}) end end
[OC-<I>] move ohai into before(:all) in deploy_rev test
diff --git a/complexity.go b/complexity.go index <HASH>..<HASH> 100644 --- a/complexity.go +++ b/complexity.go @@ -14,7 +14,9 @@ import ( // Complexity calculates the cyclomatic complexity of a function. // The 'fn' node is either a *ast.FuncDecl or a *ast.FuncLit. func Complexity(fn ast.Node) int { - v := complexityVisitor{} + v := complexityVisitor{ + complexity: 1, + } ast.Walk(&v, fn) return v.complexity } @@ -27,7 +29,7 @@ type complexityVisitor struct { // Visit implements the ast.Visitor interface. func (v *complexityVisitor) Visit(n ast.Node) ast.Visitor { switch n := n.(type) { - case *ast.FuncDecl, *ast.IfStmt, *ast.ForStmt, *ast.RangeStmt: + case *ast.IfStmt, *ast.ForStmt, *ast.RangeStmt: v.complexity++ case *ast.CaseClause: if n.List != nil { // ignore default case
Fix cyclomatic complexity for function literals
diff --git a/lib/gclitest/index.js b/lib/gclitest/index.js index <HASH>..<HASH> 100644 --- a/lib/gclitest/index.js +++ b/lib/gclitest/index.js @@ -114,6 +114,8 @@ exports.createDisplay = function(options) { var options = { window: window, display: window.display, + isNode: false, + isFirefox: false, isPhantomjs: isPhantomjs, isHttp: window.location.protocol === 'http:', hideExec: true diff --git a/lib/server/commands/test.js b/lib/server/commands/test.js index <HASH>..<HASH> 100644 --- a/lib/server/commands/test.js +++ b/lib/server/commands/test.js @@ -64,6 +64,9 @@ exports.items = [ display: window.display, isNode: true, isJsdom: true, + isHttp: false, + isFirefox: false, + isPhantomjs: false, isUnamdized: main.useUnamd }; helpers.resetResponseTimes();
refactor-<I>: Clearer flags for tests Be clearer about what environment we are running in by explicitly setting isNode, isFirefox, etc.
diff --git a/src/Repo/Data/Entity/Retro/Downline/Compressed/Phase1.php b/src/Repo/Data/Entity/Retro/Downline/Compressed/Phase1.php index <HASH>..<HASH> 100644 --- a/src/Repo/Data/Entity/Retro/Downline/Compressed/Phase1.php +++ b/src/Repo/Data/Entity/Retro/Downline/Compressed/Phase1.php @@ -9,6 +9,7 @@ namespace Praxigento\BonusHybrid\Repo\Data\Entity\Retro\Downline\Compressed; * Retrospective Downline Tree that is Compressed in Phase 1 */ class Phase1 + extends \Praxigento\Core\Data\Entity\Base { const ATTR_CALC_ID = 'calc_id'; const ATTR_CUSTOMER_ID = 'customer_ref'; @@ -19,4 +20,10 @@ class Phase1 const ATTR_PV = 'pv'; const ATTR_TV = 'tv'; const ENTITY_NAME = 'prxgt_bon_hyb_retro_cmprs_phase1'; + + public function getPrimaryKeyAttrs() + { + $result = [self::ATTR_CALC_ID, self::ATTR_CUSTOMER_ID]; + return $result; + } } \ No newline at end of file
MOBI-<I> - Repositories and queries
diff --git a/agreement.rb b/agreement.rb index <HASH>..<HASH> 100644 --- a/agreement.rb +++ b/agreement.rb @@ -7,7 +7,8 @@ module TicketSharing attr_accessor :direction, :remote_url def initialize(attrs = {}) - self.direction = attrs['direction'] if attrs['direction'] + self.direction = attrs['direction'] if attrs['direction'] + self.remote_url = attrs['remote_url'] if attrs['remote_url'] end def self.parse(json) @@ -21,7 +22,6 @@ module TicketSharing end def send_to_partner - # Client API subject to change. client = Client.new(remote_url) client.post('/agreements', self.to_json) end
Connecting the Sharing::Agreement dots. An api request is successfully sent after a Sharing::Agreement is created! * Connecting the front end to the back end * Cleaning up errors * Adding some more test coverage * Making the UI reflect the mockups a bit more * Adding some missing pieces
diff --git a/Resources/public/Admin.js b/Resources/public/Admin.js index <HASH>..<HASH> 100644 --- a/Resources/public/Admin.js +++ b/Resources/public/Admin.js @@ -114,7 +114,7 @@ var Admin = { jQuery("input[type='checkbox']:not('label.btn>input'), input[type='radio']:not('label.btn>input')", subject).iCheck({ checkboxClass: 'icheckbox_square-blue', - radioClass: 'iradio_sqaure-blue' + radioClass: 'iradio_square-blue' }); } },
typo fix in css class name
diff --git a/spec/functional/callbacks_spec.rb b/spec/functional/callbacks_spec.rb index <HASH>..<HASH> 100644 --- a/spec/functional/callbacks_spec.rb +++ b/spec/functional/callbacks_spec.rb @@ -156,6 +156,20 @@ describe "Callbacks" do end end + context "By default" do + it "should not run callbacks when no callbacks were explicitly defined" do + EDoc { key :name, String }.embedded_callbacks_off?.should == true + end + + it "should run callbacks when a callback was explicitly defined" do + EDoc { + key :name, String + before_save :no_op + def noop; end + }.embedded_callbacks_on?.should == true + end + end + context "Turning embedded callbacks off" do before do @root_class = Doc { include CallbacksSupport; embedded_callbacks_off } @@ -164,9 +178,6 @@ describe "Callbacks" do @root_class.many :children, :class => @child_class @child_class.many :children, :class => @grand_child_class - - @root_class.many :children, :class => @child_class - @child_class.many :children, :class => @grand_child_class end it "should not run create callbacks" do
Add specs for embedded callback deferral
diff --git a/api/handler/api/util.go b/api/handler/api/util.go index <HASH>..<HASH> 100644 --- a/api/handler/api/util.go +++ b/api/handler/api/util.go @@ -29,16 +29,20 @@ func requestToProto(r *http.Request) (*api.Request, error) { ct, _, err := mime.ParseMediaType(r.Header.Get("Content-Type")) if err != nil { - ct = "application/x-www-form-urlencoded" + ct = "text/plain; charset=UTF-8" //default CT is text/plain r.Header.Set("Content-Type", ct) } - switch ct { - case "application/x-www-form-urlencoded": - // expect form vals - default: - data, _ := ioutil.ReadAll(r.Body) - req.Body = string(data) + //set the body: + if r.Body != nil { + switch ct { + case "application/x-www-form-urlencoded": + // expect form vals in Post data + default: + + data, _ := ioutil.ReadAll(r.Body) + req.Body = string(data) + } } // Set X-Forwarded-For if it does not exist
-bugfix #<I> set body corretly in case of missing content-type (#<I>)
diff --git a/django_plotly_dash/__init__.py b/django_plotly_dash/__init__.py index <HASH>..<HASH> 100644 --- a/django_plotly_dash/__init__.py +++ b/django_plotly_dash/__init__.py @@ -26,6 +26,6 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ''' -__version__ = "0.7.0" +__version__ = "0.8.0" from .dash_wrapper import DjangoDash
Update version to prerelease <I> (#<I>)
diff --git a/src/ValuSo/Annotation/AnnotationBuilder.php b/src/ValuSo/Annotation/AnnotationBuilder.php index <HASH>..<HASH> 100644 --- a/src/ValuSo/Annotation/AnnotationBuilder.php +++ b/src/ValuSo/Annotation/AnnotationBuilder.php @@ -237,8 +237,9 @@ class AnnotationBuilder implements EventManagerAwareInterface protected function configureOperation(AnnotationCollection $annotations, MethodReflection $method, ArrayObject $serviceSpec) { - // Skip if no annotations are present - if (!$annotations->count()) { + // Skip if no annotations are present and operations + // has previously been configured + if (!$annotations->count() && isset($serviceSpec['operations'][$method->getName()])) { return; }
Fixes issue, where operation wasn't parsed if it wasn't annotated
diff --git a/pipes/iam/__main__.py b/pipes/iam/__main__.py index <HASH>..<HASH> 100644 --- a/pipes/iam/__main__.py +++ b/pipes/iam/__main__.py @@ -20,7 +20,7 @@ def main(): help='Set DEBUG output') parser.add_argument('-e', '--env', - choices=('build', 'dev', 'stage', 'prod'), + choices=('build', 'dev', 'stage', 'prod', 'sox', 'pci'), default='dev', help='Deploy environment') parser.add_argument('-a',
fix: Add environments for IAM See also: PSOBAT-<I>
diff --git a/src/plugins/Entity/Entity.Controller.js b/src/plugins/Entity/Entity.Controller.js index <HASH>..<HASH> 100644 --- a/src/plugins/Entity/Entity.Controller.js +++ b/src/plugins/Entity/Entity.Controller.js @@ -159,7 +159,6 @@ Entity.Controller = meta.Controller.extend // Force update hover if is needed. if(this._flags & this.Flag.UPDATE_HOVER) { - console.log("update_hover"); this._checkHover(Input.ctrl.getEvent()); this._flags &= ~this.Flag.UPDATE_HOVER; }
Re: Update hover when new entity is added.
diff --git a/test/libwebsocket/test_url.rb b/test/libwebsocket/test_url.rb index <HASH>..<HASH> 100644 --- a/test/libwebsocket/test_url.rb +++ b/test/libwebsocket/test_url.rb @@ -4,6 +4,12 @@ class TestURL < Test::Unit::TestCase def test_parse url = LibWebSocket::URL.new + assert url.parse('ws://example.com') + assert !url.secure + assert_equal 'example.com', url.host + assert_equal '/', url.resource_name + + url = LibWebSocket::URL.new assert url.parse('ws://example.com/') assert !url.secure assert_equal 'example.com', url.host
Test also URL without trailing slash
diff --git a/spec/pro_motion/data_table_screen_spec.rb b/spec/pro_motion/data_table_screen_spec.rb index <HASH>..<HASH> 100644 --- a/spec/pro_motion/data_table_screen_spec.rb +++ b/spec/pro_motion/data_table_screen_spec.rb @@ -1,6 +1,5 @@ -include ContributorsModule - describe 'DataTableScreen' do + extend ContributorsModule class TestDataTableScreen < ProMotion::DataTableScreen model Contributor
Specs require an extend, not an include
diff --git a/packages/react-scripts/scripts/start.js b/packages/react-scripts/scripts/start.js index <HASH>..<HASH> 100644 --- a/packages/react-scripts/scripts/start.js +++ b/packages/react-scripts/scripts/start.js @@ -171,7 +171,6 @@ checkBrowsers(paths.appPath, isInteractive) devServer.close(); process.exit(); }); - process.stdin.resume(); } }) .catch(err => {
Skip stdin resuming to support lerna parallel (#<I>)
diff --git a/spec/phone_spec/app/spec_runner.rb b/spec/phone_spec/app/spec_runner.rb index <HASH>..<HASH> 100644 --- a/spec/phone_spec/app/spec_runner.rb +++ b/spec/phone_spec/app/spec_runner.rb @@ -64,7 +64,9 @@ if !defined?(RHO_WP7) && !(System.get_property('platform') == 'Blackberry' && (S config[:files] << "spec/uri_spec" end +if !defined?(RHO_WP7) && !defined?( RHO_ME ) config[:files] << "spec/database_spec" +end end
bb: fix phone_spec
diff --git a/lib/editorlib.php b/lib/editorlib.php index <HASH>..<HASH> 100644 --- a/lib/editorlib.php +++ b/lib/editorlib.php @@ -106,7 +106,7 @@ function get_texteditor($editorname) { function get_available_editors() { $editors = array(); foreach (get_plugin_list('editor') as $editorname => $dir) { - $editors[$editorname] = get_string('modulename', 'editor_'.$editorname); + $editors[$editorname] = get_string('pluginname', 'editor_'.$editorname); } return $editors; } @@ -185,7 +185,7 @@ abstract class texteditor { } //TODO: this is very wrong way to do admin settings - this has to be rewritten -require_once($CFG->libdir.'/formslib.php'); +require_once($CFG->libdir.'/formslib.php'); /** * Editor settings moodle form class. *
fixed recent regression when fixing pluginname in editors
diff --git a/public/js/editors/libraries.js b/public/js/editors/libraries.js index <HASH>..<HASH> 100644 --- a/public/js/editors/libraries.js +++ b/public/js/editors/libraries.js @@ -681,6 +681,16 @@ var libraries = [ 'url': 'https://cdnjs.cloudflare.com/ajax/libs/mori/0.3.2/mori.js', 'label': 'mori 0.3.2', 'group': 'Data structures' + }, + { + 'url': 'http://cdn.jsdelivr.net/ramda/0.15.1/ramda.min.js', + 'label': 'Ramda 0.15.1', + 'group': 'Ramda' + }, + { + 'url': 'http://cdn.jsdelivr.net/ramda/latest/ramda.min.js', + 'label': 'Ramda Latest', + 'group': 'Ramda' } ];
Add Ramda as an available library
diff --git a/src/Codeception/Lib/Generator/Cest.php b/src/Codeception/Lib/Generator/Cest.php index <HASH>..<HASH> 100644 --- a/src/Codeception/Lib/Generator/Cest.php +++ b/src/Codeception/Lib/Generator/Cest.php @@ -13,11 +13,11 @@ class Cest { class {{name}}Cest { - public function _before() + public function _before({{actor}} \$I) { } - public function _after() + public function _after({{actor}} \$I) { }
Repair TestCase/Cest.php such that the _before and _after methods receive "the guy" in their argument lists.
diff --git a/satpy/readers/yaml_reader.py b/satpy/readers/yaml_reader.py index <HASH>..<HASH> 100644 --- a/satpy/readers/yaml_reader.py +++ b/satpy/readers/yaml_reader.py @@ -40,7 +40,7 @@ from pyresample.geometry import AreaDefinition from satpy.composites import IncompatibleAreas from satpy.config import recursive_dict_update from satpy.projectable import Projectable -from satpy.readers import DatasetDict, DatasetID +from satpy.readers import DATASET_KEYS, DatasetDict, DatasetID from satpy.readers.helper_functions import get_area_slices, get_sub_area from trollsift.parser import globify, parse @@ -203,8 +203,7 @@ class AbstractYAMLReader(six.with_metaclass(ABCMeta, object)): """Get the dataset matching a given a dataset id.""" if ids is None: ids = self.ids.keys() - keys = dsid._asdict().keys() - for key in keys: + for key in DATASET_KEYS: value = getattr(dsid, key) if value is None: continue
Fix test by using DATASET_KEYS instead of DatasetID's as_dict
diff --git a/logback-access/src/main/java/ch/qos/logback/access/jetty/RequestLogImpl.java b/logback-access/src/main/java/ch/qos/logback/access/jetty/RequestLogImpl.java index <HASH>..<HASH> 100644 --- a/logback-access/src/main/java/ch/qos/logback/access/jetty/RequestLogImpl.java +++ b/logback-access/src/main/java/ch/qos/logback/access/jetty/RequestLogImpl.java @@ -146,9 +146,6 @@ public class RequestLogImpl extends ContextBase implements RequestLog, getStatusManager().add(new InfoStatus(msg, this)); } -// private void addWarn(String msg) { -// getStatusManager().add(new WarnStatus(msg, this)); -// } private void addError(String msg) { getStatusManager().add(new ErrorStatus(msg, this)); } @@ -219,6 +216,10 @@ public class RequestLogImpl extends ContextBase implements RequestLog, this.fileName = fileName; } + public void setResource(String resource) { + this.resource = resource; + } + public boolean isStarted() { return started; }
added setter for 'resource'
diff --git a/src/editor/components/TableComponent.js b/src/editor/components/TableComponent.js index <HASH>..<HASH> 100644 --- a/src/editor/components/TableComponent.js +++ b/src/editor/components/TableComponent.js @@ -213,13 +213,14 @@ export default class TableComponent extends CustomSurface { // console.log('IS RIGHT BUTTON') // this will be handled by onContextMenu if (target.type === 'cell') { + let targetCell = this.props.node.get(target.id) let _needSetSelection = true let _selData = this._getSelectionData() - if (_selData) { + if (_selData && targetCell) { let { startRow, startCol, endRow, endCol } = getCellRange(this.props.node, _selData.anchorCellId, _selData.focusCellId) _needSetSelection = ( - target.colIdx < startCol || target.colIdx > endCol || - target.rowIdx < startRow || target.rowIdx > endRow + targetCell.colIdx < startCol || targetCell.colIdx > endCol || + targetCell.rowIdx < startRow || targetCell.rowIdx > endRow ) } if (_needSetSelection) {
Fix TableComponent's right-click handling.
diff --git a/src/scripts/cli-script-helper-functions.php b/src/scripts/cli-script-helper-functions.php index <HASH>..<HASH> 100644 --- a/src/scripts/cli-script-helper-functions.php +++ b/src/scripts/cli-script-helper-functions.php @@ -257,6 +257,19 @@ function printInfo($str, $append_new_line = true) { if( ((bool)$append_new_line) ) { echo PHP_EOL; } } +function normalizeNameSpaceName($namespace_name){ + + $namespace_name = ''.$namespace_name; + + if(strlen($namespace_name) > 1 && $namespace_name[0] === '\\') { + + //strip off the preceding \ + $namespace_name = substr($namespace_name, 1); + } + + return $namespace_name; +} + /** * * @@ -516,6 +529,7 @@ function createController($argc, array $argv) { } //validation passed + $namepace_4_controller = normalizeNameSpaceName($namepace_4_controller); $namepace_declaration = "namespace {$namepace_4_controller};"; } else { @@ -530,6 +544,7 @@ function createController($argc, array $argv) { } //validation passed + $namepace_4_controller = normalizeNameSpaceName($namepace_4_controller); $namepace_declaration = "namespace {$namepace_4_controller};"; }
Fixed bug in ./vendor/bin/s3mvc-create-controller-wizard that creates controller with namespace prefixed with \
diff --git a/addon/components/block-slot.js b/addon/components/block-slot.js index <HASH>..<HASH> 100644 --- a/addon/components/block-slot.js +++ b/addon/components/block-slot.js @@ -12,7 +12,7 @@ const { * The maximum allowed number of block parameters supported * * @memberof module:addon/components/block-slot - * @const {Number} blockParamsAllowed + * @constant {Number} blockParamsAllowed * @default 10 */ const blockParamsAllowed = 10
fixed use of constant in docBlock to be consistent with style docs
diff --git a/src/article/InternalArticleSchema.js b/src/article/InternalArticleSchema.js index <HASH>..<HASH> 100644 --- a/src/article/InternalArticleSchema.js +++ b/src/article/InternalArticleSchema.js @@ -120,7 +120,8 @@ Figure.schema = { class TableFigure extends Figure {} TableFigure.schema = { type: 'table-figure', - content: CHILD('table') + content: CHILD('table'), + footnotes: CHILDREN('fn') } class Groups extends XMLElementNode {}
Keep footnotes inside Table Figure.
diff --git a/src/asset.js b/src/asset.js index <HASH>..<HASH> 100644 --- a/src/asset.js +++ b/src/asset.js @@ -2,7 +2,7 @@ import * as validators from './validators' export default function (Vue: GlobalAPI): void { - const extend = Vue.util.extend + const { extend } = Vue.util // set global validators asset const assets: Object = Object.create(null)
:shirt: refactor: destructuring
diff --git a/models/classes/http/Controller.php b/models/classes/http/Controller.php index <HASH>..<HASH> 100644 --- a/models/classes/http/Controller.php +++ b/models/classes/http/Controller.php @@ -37,7 +37,10 @@ abstract class Controller use HttpRequestHelperTrait; use HttpFlowTrait; + /** @var ServerRequestInterface */ protected $request; + + /** @var ResponseInterface */ protected $response; /** @@ -52,6 +55,11 @@ abstract class Controller return $this; } + public function isJsonRequest(): bool + { + return $this->request && current($this->request->getHeader('content-type')) === 'application/json'; + } + /** * Set Psr7 http response *
add isJsonRequest method for controller
diff --git a/lib/puppet/type/exec.rb b/lib/puppet/type/exec.rb index <HASH>..<HASH> 100644 --- a/lib/puppet/type/exec.rb +++ b/lib/puppet/type/exec.rb @@ -413,7 +413,8 @@ module Puppet `grep` determines it's already there. Note that this command follows the same rules as the main command, - which is to say that it must be fully qualified if the path is not set. + such as which user and group it's run as. + This also means it must be fully qualified if the path is not set. It also uses the same provider as the main command, so any behavior that differs by provider will match. EOT @@ -456,7 +457,9 @@ module Puppet This would run `logrotate` only if that test returned true. Note that this command follows the same rules as the main command, - which is to say that it must be fully qualified if the path is not set. + such as which user and group it's run as. + This also means it must be fully qualified if the path is not set. + It also uses the same provider as the main command, so any behavior that differs by provider will match.
(docs) Clarification on unless and only Could probably clearer that the `unless` and `only` parameters have all the same parameters as the main exec, not just the path. (DOCUMENT-<I>)
diff --git a/src/components/Button.js b/src/components/Button.js index <HASH>..<HASH> 100644 --- a/src/components/Button.js +++ b/src/components/Button.js @@ -43,7 +43,6 @@ const Button = React.createClass({ <button aria-label={this.props.ariaLabel} onClick={this.props.type === 'disabled' ? null : this.props.onClick} - role='button' style={Object.assign({}, styles.component, styles[this.props.type], this.props.style)} > <div style={styles.children}>
Removes button role now that element is native button
diff --git a/squad/core/models.py b/squad/core/models.py index <HASH>..<HASH> 100644 --- a/squad/core/models.py +++ b/squad/core/models.py @@ -856,7 +856,12 @@ class Test(models.Model): @property def full_name(self): - return join_name(self.suite.slug, self.name) + suite = '' + if self.metadata is None: + suite = self.suite.slug + else: + suite = self.metadata.suite + return join_name(suite, self.name) class History(object): def __init__(self, since, count, last_different):
core: models: use metadata for retrieving test full name Prioritize SuiteMetadata.suite in favor of Suite.slug when making test's full name. This will reduce one prefetch_related when fetching tests.
diff --git a/src/Http/FormAuthenticationModule.php b/src/Http/FormAuthenticationModule.php index <HASH>..<HASH> 100644 --- a/src/Http/FormAuthenticationModule.php +++ b/src/Http/FormAuthenticationModule.php @@ -102,6 +102,7 @@ class FormAuthenticationModule implements ServiceModuleInterface $this->session->delete('_two_factor_verified'); $this->session->delete('_cached_groups_user_id'); $this->session->delete('_cached_groups'); + $this->session->delete('_last_authenticated_at_ping_sent'); $this->session->regenerate(true); return new RedirectResponse($request->requireHeader('HTTP_REFERER'));
also delete _last_authenticated_at_ping_sent from session on logout
diff --git a/angular-loggly-logger.js b/angular-loggly-logger.js index <HASH>..<HASH> 100644 --- a/angular-loggly-logger.js +++ b/angular-loggly-logger.js @@ -168,7 +168,7 @@ } else if(angular.isObject(msg)){ //handling JSON objects - sending.messageObj = msg; + sending = angular.extend({}, msg, sending); } else{ //sending plain text
Removed messageObj field Removed messageObj field for the custom object and extended custom json object fields to the parent json.
diff --git a/solidity/test/BancorFormula.js b/solidity/test/BancorFormula.js index <HASH>..<HASH> 100644 --- a/solidity/test/BancorFormula.js +++ b/solidity/test/BancorFormula.js @@ -48,4 +48,19 @@ contract('BancorFormula', () => { assert(retVal.lessThan(maxVal), `Result of function fixedExp(${maxExp.plus(1)}, ${precision}) indicates that maxExpArray[${precision}] is wrong`); }); } + + for (let n = 1; n <= 255; n++) { + let val1 = web3.toBigNumber(2).toPower(n); + let val2 = web3.toBigNumber(2).toPower(n).plus(1); + let val3 = web3.toBigNumber(2).toPower(n+1).minus(1); + + it('Verify function floorLog2 legal input', async () => { + let retVal1 = await formula.testFloorLog2.call(val1); + let retVal2 = await formula.testFloorLog2.call(val2); + let retVal3 = await formula.testFloorLog2.call(val3); + assert(retVal1.equals(web3.toBigNumber(n)), `Result of function floorLog2(${val1}) is wrong`); + assert(retVal2.equals(web3.toBigNumber(n)), `Result of function floorLog2(${val2}) is wrong`); + assert(retVal3.equals(web3.toBigNumber(n)), `Result of function floorLog2(${val3}) is wrong`); + }); + } });
Update the BancorFormula JS test.
diff --git a/rendersheet.js b/rendersheet.js index <HASH>..<HASH> 100644 --- a/rendersheet.js +++ b/rendersheet.js @@ -204,9 +204,14 @@ class RenderSheet const current = this.textures[key]; if (current.texture) { - current.texture.destroy(); + current.texture = new PIXI.Texture(this.baseTextures[current.canvas], new PIXI.Rectangle(current.x, current.y, current.width, current.height)); + } + else + { + current.texture.baseTexture = this.baseTextures[current.canvas]; + current.texture.frame = new PIXI.Rectangle(current.x, current.y, current.width, current.height); + current.texture.update(); } - current.texture = new PIXI.Texture(this.baseTextures[current.canvas], new PIXI.Rectangle(current.x, current.y, current.width, current.height)); } } @@ -342,6 +347,7 @@ class RenderSheet { if (packers[j].add(block, j)) { + block.texture = j; packed = true; break; } @@ -357,6 +363,10 @@ class RenderSheet } return; } + else + { + block.texture = j; + } } }
Fixing an issue with canvas index not added to texture
diff --git a/isort/isort.py b/isort/isort.py index <HASH>..<HASH> 100644 --- a/isort/isort.py +++ b/isort/isort.py @@ -209,7 +209,14 @@ class SortImports(object): if module_name_to_check in self.config[config_key]: return placement - for prefix in PYTHONPATH: + paths = PYTHONPATH + virtual_env = os.environ.get('VIRTUAL_ENV', None) + if virtual_env: + paths = list(paths) + for version in ((2, 6), (2, 7), (3, 0), (3, 1), (3, 2), (3, 3), (3, 4)): + paths.append("{0}/lib/python{1}.{2}/site-packages".format(virtual_env, version[0], version[1])) + + for prefix in paths: module_path = "/".join((prefix, moduleName.replace(".", "/"))) package_path = "/".join((prefix, moduleName.split(".")[0])) if (os.path.exists(module_path + ".py") or os.path.exists(module_path + ".so") or
Smarter virtualenv behaviour inspired by feedback from @spookylukey
diff --git a/blimpy/waterfall.py b/blimpy/waterfall.py index <HASH>..<HASH> 100755 --- a/blimpy/waterfall.py +++ b/blimpy/waterfall.py @@ -110,7 +110,7 @@ class Waterfall(Filterbank): t_start (int): start integration ID t_stop (int): stop integration ID load_data (bool): load data. If set to False, only header will be read. - max_load (float): maximum data to load in GB. Default: 1GB. + max_load (float): maximum data to load in GB. Default: 1GB. e.g. 0.1 is 100 MB header_dict (dict): Create blimpy from header dictionary + data array data_array (np.array): Create blimpy from header dict + data array @@ -576,9 +576,10 @@ def cmd_tool(args=None): parser.add_argument('-l', action='store', default=None, dest='max_load', type=float, help='Maximum data limit to load. Default:1GB') - if args is None: - args = sys.argv - parse_args = parser.parse_args(args) +# if args is None: +# args = sys.argv +# parse_args = parser.parse_args(args) + parse_args = parser.parse_args() # Open blimpy data filename = parse_args.filename
Pushing back on commit 1d<I>d<I>fb1e<I>d0cac<I>fb<I>aea<I>ca since it causes command line “watutil” to break. Need new solution.
diff --git a/lib/plugins/stats.js b/lib/plugins/stats.js index <HASH>..<HASH> 100644 --- a/lib/plugins/stats.js +++ b/lib/plugins/stats.js @@ -61,7 +61,14 @@ module.exports = function(options){ // requests if (options.requests) { - server.on('request', function(req, res){ + // force cluster's callback first + if (Array.isArray(server._events.request)) { + server._events.request.unshift(request); + } else { + server._events.request = [request, server._events.request]; + } + + function request(req, res){ var data = { remoteAddress: req.socket.remoteAddress , headers: req.headers @@ -79,7 +86,7 @@ module.exports = function(options){ res.end(str, encoding); master.call('reportStats', 'request complete', data); } - }); + }; } // master stats } else {
force cluster's request callback first to proxy end() for sync req/res cycle'
diff --git a/core/vocabulary/src/test/java/org/trellisldp/vocabulary/AbstractVocabularyTest.java b/core/vocabulary/src/test/java/org/trellisldp/vocabulary/AbstractVocabularyTest.java index <HASH>..<HASH> 100644 --- a/core/vocabulary/src/test/java/org/trellisldp/vocabulary/AbstractVocabularyTest.java +++ b/core/vocabulary/src/test/java/org/trellisldp/vocabulary/AbstractVocabularyTest.java @@ -76,7 +76,7 @@ public abstract class AbstractVocabularyTest { assertTrue(subjects.contains(namespace() + field), "Field definition is not in published ontology! " + field); } else if (!subjects.contains(namespace() + field)) { - LOGGER.warn("Field definition is not in published ontology! {}", field); + LOGGER.debug("Field definition is not in published ontology! {}", field); } }); } @@ -93,7 +93,7 @@ public abstract class AbstractVocabularyTest { .filterKeep(Objects::nonNull) .filterKeep(uri -> uri.startsWith(namespace())).filterDrop(namespace()::equals) .filterDrop(subjects::contains).forEachRemaining(uri -> { - LOGGER.warn("{} not defined in {} class", uri, vocabulary().getName()); + LOGGER.debug("{} not defined in {} class", uri, vocabulary().getName()); }); }
Turn down console warnings Related to #<I>
diff --git a/test/tests/signature.js b/test/tests/signature.js index <HASH>..<HASH> 100644 --- a/test/tests/signature.js +++ b/test/tests/signature.js @@ -41,7 +41,7 @@ describe("Signature", function() { assert.equal(when.offset(), -now.getTimezoneOffset()); }); - it("can get a default signature when no user name is set", function(done) { + it("can get a default signature when no user name is set", function() { var savedUserName; var savedUserEmail; @@ -75,11 +75,9 @@ describe("Signature", function() { assert.equal(sig.email(), "unknown@example.com"); }) .then(cleanUp) - .then(done) .catch(function(e) { - cleanUp() + return cleanUp() .then(function() { - done(e); return Promise.reject(e); }); });
Fix asynchronous testing of signatures The previous implementation mixed promises and callbacks in a way that was incompatible with mocha. This patch removes the callback and uses promises only.
diff --git a/spec/filters/bugs/hash.rb b/spec/filters/bugs/hash.rb index <HASH>..<HASH> 100644 --- a/spec/filters/bugs/hash.rb +++ b/spec/filters/bugs/hash.rb @@ -86,7 +86,6 @@ opal_filter "Hash" do fails "Hash#initialize_copy does not transfer default values" fails "Hash#initialize_copy calls to_hash on hash subclasses" fails "Hash#initialize_copy tries to convert the passed argument to a hash using #to_hash" - fails "Hash#initialize_copy tries to convert the passed argument to a hash using #to_hash" fails "Hash#initialize_copy replaces the contents of self with other" fails "Hash#inspect handles hashes with recursive values"
Move another frozen hash spec to unsupported
diff --git a/cheroot/workers/threadpool.py b/cheroot/workers/threadpool.py index <HASH>..<HASH> 100644 --- a/cheroot/workers/threadpool.py +++ b/cheroot/workers/threadpool.py @@ -320,7 +320,7 @@ class ThreadPool: return ( thread for thread in threads - if thread is not threading.currentThread() + if thread is not threading.current_thread() ) @property
Use `current_thread()` to address Python <I> `DeprecationWarning` PR #<I>
diff --git a/src/js/panels.js b/src/js/panels.js index <HASH>..<HASH> 100644 --- a/src/js/panels.js +++ b/src/js/panels.js @@ -38,8 +38,14 @@ var Panels = { remove: function(id) { var panels = this.panels; for (var i = panels.length - 1; i >= 0; i--) { - if (panels[i].id === id) { + if (panels[i].id === id){ + var panelToRemove = panels[i]; panels.splice(i, 1); + //if removed panel was default, set first panel as new default, if exists + if (panelToRemove.default && panels.length){ + panels[0].default = true; + } + return; //should be no more panels with the same id } } }
set first panel as default, if default is removed
diff --git a/src/components/metadata/MetaObject.js b/src/components/metadata/MetaObject.js index <HASH>..<HASH> 100644 --- a/src/components/metadata/MetaObject.js +++ b/src/components/metadata/MetaObject.js @@ -34,7 +34,7 @@ export class MetaObject extends Component { {items} <a onClick={() => addField(namePrefix)} className="add-field-object" title="Add new key/value pair"> - New key/value pair + New key/value pair under <strong>{fieldKey}</strong> </a> </div> );
improve accessibility for deep nested objects
diff --git a/common-core-open/src/main/java/com/bbn/bue/common/files/FileUtils.java b/common-core-open/src/main/java/com/bbn/bue/common/files/FileUtils.java index <HASH>..<HASH> 100755 --- a/common-core-open/src/main/java/com/bbn/bue/common/files/FileUtils.java +++ b/common-core-open/src/main/java/com/bbn/bue/common/files/FileUtils.java @@ -75,6 +75,18 @@ public final class FileUtils { } /** + * Create the parent directories of the given file, if needed. + */ + public static void ensureParentDirectoryExists(File f) throws IOException { + final File parent = f.getParentFile(); + if (parent != null) { + if (!parent.isDirectory() && !parent.mkdirs()) { + throw new IOException("Could not create parent directories for " + f.getAbsolutePath()); + } + } + } + + /** * Takes a file with filenames listed one per line and returns a list of the corresponding File * objects. Ignores blank lines and lines with a "#" in the first column position. Treats the * file as UTF-8 encoded.
Utility method to ensure the parent directories of a file exist
diff --git a/parallel.js b/parallel.js index <HASH>..<HASH> 100644 --- a/parallel.js +++ b/parallel.js @@ -18,7 +18,7 @@ function parallel (options) { last = null if (toCall.length === 0) { - done() + done.call(that) released(last) } else { holder._callback = done diff --git a/test.js b/test.js index <HASH>..<HASH> 100644 --- a/test.js +++ b/test.js @@ -199,3 +199,14 @@ test('call the callback with the given this with no results', function (t) { } } }) + +test('call the callback with the given this with no data', function (t) { + t.plan(1) + + var instance = parallel() + var obj = {} + + instance(obj, [], 42, function done () { + t.equal(obj, this, 'this matches') + }) +})
Call the final callback with the given this even if there is nothing to call.
diff --git a/templates/js/routes/index.js b/templates/js/routes/index.js index <HASH>..<HASH> 100644 --- a/templates/js/routes/index.js +++ b/templates/js/routes/index.js @@ -2,7 +2,7 @@ var express = require('express'); var router = express.Router(); /* GET home page. */ -router.get('/', function(req, res) { +router.get('/', function(req, res, next) { res.render('index', { title: 'Express' }); }); diff --git a/templates/js/routes/users.js b/templates/js/routes/users.js index <HASH>..<HASH> 100644 --- a/templates/js/routes/users.js +++ b/templates/js/routes/users.js @@ -2,7 +2,7 @@ var express = require('express'); var router = express.Router(); /* GET users listing. */ -router.get('/', function(req, res) { +router.get('/', function(req, res, next) { res.send('respond with a resource'); });
gen: include next argument in route handlers closes #<I> closes #<I>
diff --git a/peerconn.go b/peerconn.go index <HASH>..<HASH> 100644 --- a/peerconn.go +++ b/peerconn.go @@ -869,7 +869,7 @@ func (cn *PeerConn) wroteBytes(n int64) { cn.allStats(add(n, func(cs *ConnStats) *Count { return &cs.BytesWritten })) } -func (cn *PeerConn) readBytes(n int64) { +func (cn *Peer) readBytes(n int64) { cn.allStats(add(n, func(cs *ConnStats) *Count { return &cs.BytesRead })) } diff --git a/webseed-peer.go b/webseed-peer.go index <HASH>..<HASH> 100644 --- a/webseed-peer.go +++ b/webseed-peer.go @@ -126,6 +126,7 @@ func (ws *webseedPeer) requestResultHandler(r Request, webseedRequest webseed.Re // sure if we can divine which errors indicate cancellation on our end without hitting the // network though. ws.peer.doChunkReadStats(int64(len(result.Bytes))) + ws.peer.readBytes(int64(len(result.Bytes))) ws.peer.t.cl.lock() defer ws.peer.t.cl.unlock() if result.Err != nil {
Record webseed request result bytes against client stats Should fix the issue where webseeds cause ><I>% useful data readings.
diff --git a/src/api.js b/src/api.js index <HASH>..<HASH> 100644 --- a/src/api.js +++ b/src/api.js @@ -30,6 +30,28 @@ exports = module.exports = { return fs.getData(source); }) .then(function (data) { + var group, i; + var count = 0; + var shouldBeDisplayed = function (item) { + return (config.display.access.indexOf(item.access[0]) !== -1) && !(!config.display.alias && item.alias); + }; + + // Adding a `display` key to each item + for (group in data) { + for (i = 0; i < data[group].length; i++) { + data[group][i].display = shouldBeDisplayed(data[group][i]); + + if (data[group][i].display === true) { + count++; + } + } + } + + config.dataCount = count; + + return data; + }) + .then(function (data) { logger.log('Folder `' + source + '` successfully parsed.'); config.data = data;
Moved some logic away from templates, back in the JS side
diff --git a/pysnmp/cache.py b/pysnmp/cache.py index <HASH>..<HASH> 100644 --- a/pysnmp/cache.py +++ b/pysnmp/cache.py @@ -21,7 +21,6 @@ class Cache: if self.__size >= self.__maxSize: keys = self.__usage.keys() keys.sort(lambda x,y,d=self.__usage: cmp(d[x],d[y])) - print keys[:self.__chopSize] for _k in keys[:self.__chopSize]: del self.__cache[_k] del self.__usage[_k]
stray debug printout removed
diff --git a/src/Traits/TButtonRenderer.php b/src/Traits/TButtonRenderer.php index <HASH>..<HASH> 100644 --- a/src/Traits/TButtonRenderer.php +++ b/src/Traits/TButtonRenderer.php @@ -33,10 +33,15 @@ trait TButtonRenderer * @return mixed * @throws DataGridColumnRendererException */ - public function useRenderer(?Row $row = null) + public function useRenderer($row = null) { $renderer = $this->getRenderer(); - $args = $row ? [$row->getItem()] : []; + + if ($row instanceof Row) { + $args = [$row->getItem()]; + } else { + $args = []; + } if (!$renderer) { throw new DataGridColumnRendererException;
Fixed TButtonRenderer to support php < <I>
diff --git a/Provider/AdminMenuProvider.php b/Provider/AdminMenuProvider.php index <HASH>..<HASH> 100755 --- a/Provider/AdminMenuProvider.php +++ b/Provider/AdminMenuProvider.php @@ -100,12 +100,8 @@ class AdminMenuProvider { $file = $this->kernel->getCacheDir() . '/' . self::CACHE_FILENAME; $content = sprintf('<?php return %s;', var_export($menu, true)); - $tmpFile = tempnam(dirname($file), basename($file)); - if (false !== @file_put_contents($tmpFile, $content) && @rename($tmpFile, $file)) { - @chmod($file, 0666 & ~umask()); - - return; - } + $fs = new Filesystem(); + $fs->dumpFile($file, $content); } /** @@ -124,5 +120,4 @@ class AdminMenuProvider return $children; } - }
Changed cache dump method in admin menu provider (cherry picked from commit 9b<I>e<I>ac<I>fe<I>d1bfee<I>a7a7f<I>c<I>)
diff --git a/tests/Pheasant/Tests/EnumeratorTest.php b/tests/Pheasant/Tests/EnumeratorTest.php index <HASH>..<HASH> 100644 --- a/tests/Pheasant/Tests/EnumeratorTest.php +++ b/tests/Pheasant/Tests/EnumeratorTest.php @@ -11,7 +11,7 @@ class EnumeratorTest extends \Pheasant\Tests\MysqlTestCase public function testEnumerating() { - $dir = __DIR__.'/examples'; + $dir = __DIR__.'/Examples'; $files = array_map(function($f) { return substr(basename($f),0,-4); }, glob($dir.'/*.php'));
Fix bug with incorrect case in path, damn you HFS
diff --git a/sregistry/version.py b/sregistry/version.py index <HASH>..<HASH> 100644 --- a/sregistry/version.py +++ b/sregistry/version.py @@ -19,7 +19,7 @@ along with this program. If not, see <https://www.gnu.org/licenses/>. ''' -__version__ = "0.0.7" +__version__ = "0.0.61" AUTHOR = 'Vanessa Sochat' AUTHOR_EMAIL = 'vsochat@stanford.edu' NAME = 'sregistry'
don't more version up so quickly
diff --git a/resweb/views.py b/resweb/views.py index <HASH>..<HASH> 100644 --- a/resweb/views.py +++ b/resweb/views.py @@ -222,12 +222,17 @@ class Failed(ResWeb): import simplejson as json jobs = [] for job in failure.all(self.resq, self._start, self._start + 20): + backtrace = job['backtrace'] + + if isinstance(backtrace, list): + backtrace = '\n'.join(backtrace) + item = job item['failed_at'] = str(datetime.datetime.fromtimestamp(float(job['failed_at']))) item['worker_url'] = '/workers/%s/' % job['worker'] item['payload_args'] = str(job['payload']['args']) item['payload_class'] = job['payload']['class'] - item['traceback'] = job['backtrace'] + item['traceback'] = backtrace jobs.append(item) return jobs
Become compatible with resque-web without breaking backwards compatibility.
diff --git a/Tests/AppKernel.php b/Tests/AppKernel.php index <HASH>..<HASH> 100644 --- a/Tests/AppKernel.php +++ b/Tests/AppKernel.php @@ -37,6 +37,14 @@ final class AppKernel extends Kernel /** * {@inheritdoc} */ + public function __construct(string $environment, bool $debug) + { + parent::__construct($environment, false); + } + + /** + * {@inheritdoc} + */ public function registerBundles() { $bundles = [
JWELoaderFactory and JWSLoaderfactory added
diff --git a/src/main/groovy/util/slurpersupport/NodeChildren.java b/src/main/groovy/util/slurpersupport/NodeChildren.java index <HASH>..<HASH> 100644 --- a/src/main/groovy/util/slurpersupport/NodeChildren.java +++ b/src/main/groovy/util/slurpersupport/NodeChildren.java @@ -17,6 +17,7 @@ package groovy.util.slurpersupport; +import groovy.lang.Buildable; import groovy.lang.Closure; import groovy.lang.GroovyObject; import groovy.lang.GroovyRuntimeException; @@ -248,7 +249,13 @@ class NodeChildren extends GPathResult { final Iterator iter = nodeIterator(); while (iter.hasNext()) { - ((Node)iter.next()).build(builder, this.namespaceMap, this.namespaceTagHints); + final Object next = iter.next(); + + if (next instanceof Buildable) { + ((Buildable)next).build(builder); + } else { + ((Node)next).build(builder, this.namespaceMap, this.namespaceTagHints); + } } }
Fix problem when the result of a GPath filter operation is used in a builder git-svn-id: <URL>
diff --git a/indra/preassembler/__init__.py b/indra/preassembler/__init__.py index <HASH>..<HASH> 100644 --- a/indra/preassembler/__init__.py +++ b/indra/preassembler/__init__.py @@ -310,10 +310,11 @@ def check_sequence(stmt): return failures def check_agent_mod(agent, mods=None, mod_sites=None): + failures = [] # If no UniProt ID is found, we don't report a failure up_id = agent.db_refs.get('UP') if up_id is None: - return True + return failures # If the UniProt ID is a list then choose the first one. if not isinstance(up_id, basestring): @@ -327,7 +328,6 @@ def check_agent_mod(agent, mods=None, mod_sites=None): check_mods = agent.mods check_mod_sites = agent.mod_sites - failures = [] for m, mp in zip(check_mods, check_mod_sites): if mp is None: continue
Fix bug in sequence checking when no UniProt ID is given
diff --git a/lib/helpers/form_column_helpers.rb b/lib/helpers/form_column_helpers.rb index <HASH>..<HASH> 100644 --- a/lib/helpers/form_column_helpers.rb +++ b/lib/helpers/form_column_helpers.rb @@ -65,8 +65,8 @@ module ActiveScaffold value = associated.to_label end - input_name = "#{options[:name]}[id]" # "record[#{column.name}][id]" - input_id = input_name.gsub("[", "_").gsub("]", "") # "record_#{column.name}_id" + input_name = "#{options[:name]}" + input_id = input_name.gsub("[", "_").gsub("]", "") id_tag = hidden_field_tag(input_name, value_id, {:id => input_id}) companion_name = "record[#{column.name}_companion]" @@ -183,7 +183,7 @@ module ActiveScaffold if column.singular_association? record_select_field( - "#{options[:name]}[id]", + "#{options[:name]}", @record.send(column.name) || column.association.klass.new, {:controller => remote_controller, :params => params}.merge(column.options) )
Make active_scaffold_input_singular_association_with_auto_complete and active_scaffold_input_record_select both compliant with the new singular association naming convention - no [id] This keeps update_record_from_params, from trying to update the associations. git-svn-id: <URL>
diff --git a/src/watcher.js b/src/watcher.js index <HASH>..<HASH> 100644 --- a/src/watcher.js +++ b/src/watcher.js @@ -3,6 +3,7 @@ var chokidar = require('chokidar'); var eslint = require('eslint'); var chalk = require('chalk'); var _ = require('lodash'); +var path = require('path'); var success = require('./formatters/helpers/success'); var formatter = require('./formatters/simple-detail'); @@ -33,9 +34,9 @@ function lintFile(path, config) { logger.log(formatter(results)); } -function isWatchableExtension(path){ +function isWatchableExtension(filePath){ return _.some(cli.options.extensions, function (ext){ - return path.indexOf(ext) > -1; + return path.extname(filePath) === ext; }); }
Comparing the extension of the file using path.extname
diff --git a/app/models/esr_record.rb b/app/models/esr_record.rb index <HASH>..<HASH> 100644 --- a/app/models/esr_record.rb +++ b/app/models/esr_record.rb @@ -95,6 +95,8 @@ class EsrRecord < ActiveRecord::Base end def assign_invoice + # Prepare remarks to not be null + self.remarks ||= '' if Invoice.exists?(invoice_id) self.invoice_id = invoice_id self.remarks += "Referenz #{reference}"
Prepare esr record remarks to not be null.
diff --git a/vm.go b/vm.go index <HASH>..<HASH> 100644 --- a/vm.go +++ b/vm.go @@ -102,18 +102,14 @@ func (l *State) equalObjects(t1, t2 value) bool { case *userData: if t1 == t2 { return true - } else if t2, ok := t2.(*userData); ok && t2 != nil { + } else if t2, ok := t2.(*userData); ok { tm = l.equalTagMethod(t1.metaTable, t2.metaTable, tmEq) - } else if !ok || t2 == nil { - return false } case *table: if t1 == t2 { return true - } else if t2, ok := t2.(*table); ok && t2 != nil { + } else if t2, ok := t2.(*table); ok { tm = l.equalTagMethod(t1.metaTable, t2.metaTable, tmEq) - } else if !ok || t2 == nil { - return false } default: return t1 == t2
Simplify type check on (*State).equalObjects Removes excess `return false`. This also removes the ok check since we only really care if t2 is a table or userdata. If t2 is also a nil pointer to a table/UD, then the Lua state is somehow far worse off than anticipated anyway and a panic may be more valuable when accessing t2.metaTable.
diff --git a/test/history_test.js b/test/history_test.js index <HASH>..<HASH> 100644 --- a/test/history_test.js +++ b/test/history_test.js @@ -553,8 +553,8 @@ describe('History', function() { return browser.visit('/history/referer'); }); - it('should be empty', function() { - browser.assert.text('title', ''); + it('should be missing', function() { + browser.assert.text('title', 'undefined'); }); });
FIXED don't send Referer header if no referrer
diff --git a/src/ol/control.js b/src/ol/control.js index <HASH>..<HASH> 100644 --- a/src/ol/control.js +++ b/src/ol/control.js @@ -5,6 +5,7 @@ export {default as Attribution} from './control/Attribution.js'; export {default as Control} from './control/Control.js'; export {default as FullScreen} from './control/FullScreen.js'; +export {default as MousePosition} from './control/MousePosition.js'; export {default as OverviewMap} from './control/OverviewMap.js'; export {default as Rotate} from './control/Rotate.js'; export {default as ScaleLine} from './control/ScaleLine.js';
Re-export MousePosition from ol/control
diff --git a/glim/facades.py b/glim/facades.py index <HASH>..<HASH> 100644 --- a/glim/facades.py +++ b/glim/facades.py @@ -13,4 +13,7 @@ class Router(Facade): pass class Database(Facade): + pass + +class Orm(Facade): pass \ No newline at end of file
add Orm class to facadeas
diff --git a/fbchat/models.py b/fbchat/models.py index <HASH>..<HASH> 100644 --- a/fbchat/models.py +++ b/fbchat/models.py @@ -131,6 +131,17 @@ class Group(Thread): self.approval_requests = approval_requests self.join_link = join_link + +class Room(Group): + # True is room is not discoverable + privacy_mode = None + + def __init__(self, uid, privacy_mode=None, **kwargs): + """Deprecated. Use :class:`Group` instead""" + super(Room, self).__init__(ThreadType.Room, uid, **kwargs) + self.privacy_mode = privacy_mode + + class Page(Thread): #: The page's custom url url = None @@ -518,6 +529,7 @@ class ThreadType(Enum): """Used to specify what type of Facebook thread is being used. See :ref:`intro_threads` for more info""" USER = 1 GROUP = 2 + ROOM = 2 PAGE = 3 class ThreadLocation(Enum):
Backwards compability for `Room`s
diff --git a/model/PathEventProxy.js b/model/PathEventProxy.js index <HASH>..<HASH> 100644 --- a/model/PathEventProxy.js +++ b/model/PathEventProxy.js @@ -94,7 +94,7 @@ NotifyByPathProxy.Prototype = function() { if (this._list[i].listener === listener) { var entry = this._list[i]; this._list.splice(i, 1); - var key = entry.concat(['listeners']); + var key = entry.path.concat(['listeners']); var listeners = this.listeners.get(key); deleteFromArray(listeners, entry); }
Fix regression in PathEventProxy.disconnect.
diff --git a/librosa/core/spectrum.py b/librosa/core/spectrum.py index <HASH>..<HASH> 100644 --- a/librosa/core/spectrum.py +++ b/librosa/core/spectrum.py @@ -999,7 +999,7 @@ def reassigned_spectrogram( ... 1e-6 * np.random.randn(2*sr) >>> freqs, times, mags = librosa.reassigned_spectrogram(y=y, sr=sr, ... n_fft=n_fft) - >>> mags_db = librosa.power_to_db(mags, ref=np.max) + >>> mags_db = librosa.amplitude_to_db(mags, ref=np.max) >>> fig, ax = plt.subplots(nrows=2, sharex=True, sharey=True) >>> img = librosa.display.specshow(mags_db, x_axis="s", y_axis="linear", sr=sr,
tiny fix (#<I>)
diff --git a/css-transform.js b/css-transform.js index <HASH>..<HASH> 100644 --- a/css-transform.js +++ b/css-transform.js @@ -195,7 +195,7 @@ var cssTransform = function(options, filename, callback) { return; } - var rules = css.parse(data).stylesheet.rules; + var rules = css.parse(data, { source: filename }).stylesheet.rules; _.each(rules, function(rule) { if (rule.type === 'import') { @@ -259,6 +259,7 @@ var cssTransform = function(options, filename, callback) { rules: [ rule ] } }); + cssStream.write(cssText + '\n'); } });
Specify the path to the file containing css
diff --git a/directions/base.py b/directions/base.py index <HASH>..<HASH> 100644 --- a/directions/base.py +++ b/directions/base.py @@ -122,7 +122,7 @@ class Route: self.coords = coords self.distance = distance self.duration = duration - self.props = kwargs.copy() + self.properties = kwargs.copy() if maneuvers is None: maneuvers = [] @@ -132,13 +132,13 @@ class Route: def __geo_interface__(self): geom = {'type': 'LineString', 'coordinates': self.coords} - props = self.props.copy() - props.update({'distance': self.distance, - 'duration': self.duration}) + properties = self.properties.copy() + properties.update({'distance': self.distance, + 'duration': self.duration}) f = {'type': 'Feature', 'geometry': geom, - 'properties': props} + 'properties': properties} return f @@ -161,7 +161,7 @@ class Maneuver: """ self.coords = coords - self.props = kwargs.copy() + self.properties = kwargs.copy() @property def __geo_interface__(self): @@ -170,6 +170,6 @@ class Maneuver: f = {'type': 'Feature', 'geometry': geom, - 'properties': self.props} + 'properties': self.properties} return f
Add properties to Route and Maneuver classes
diff --git a/src/extensions/jquery.cytoscapeweb.renderer.svg.js b/src/extensions/jquery.cytoscapeweb.renderer.svg.js index <HASH>..<HASH> 100644 --- a/src/extensions/jquery.cytoscapeweb.renderer.svg.js +++ b/src/extensions/jquery.cytoscapeweb.renderer.svg.js @@ -1304,6 +1304,14 @@ originY = mousedownEvent.pageY; } + var elements; + + if( element.selected() ){ + elements = self.selectedElements.add(element).filter(":grabbable"); + } else { + elements = element.collection(); + } + var justStartedDragging = true; var dragHandler = function(dragEvent){ @@ -1329,14 +1337,6 @@ originX = dragX; originY = dragY; - var elements; - - if( element.selected() ){ - elements = self.selectedElements.add(element); - } else { - elements = element.collection(); - } - elements.each(function(i, e){ e.element()._private.position.x += dx; e.element()._private.position.y += dy;
Ungrabbable nodes aren't moved when a grabbable node is grabbed and moved
diff --git a/scapy/layers/inet6.py b/scapy/layers/inet6.py index <HASH>..<HASH> 100644 --- a/scapy/layers/inet6.py +++ b/scapy/layers/inet6.py @@ -2706,7 +2706,7 @@ class MIP6MH_HoTI(_MobilityHeader): ByteEnumField("mhtype", 1, mhtypes), ByteField("res", None), XShortField("cksum", None), - StrFixedLenField("reserved", "\x00"*16, 16), + StrFixedLenField("reserved", "\x00"*2, 2), StrFixedLenField("cookie", "\x00"*8, 8), _PhantomAutoPadField("autopad", 1), # autopad activated by default _MobilityOptionsField("options", [], MIP6OptUnknown, 16,
Reserved is <I> bits (not bytes) --HG-- branch : Issue #<I>
diff --git a/raus.go b/raus.go index <HASH>..<HASH> 100644 --- a/raus.go +++ b/raus.go @@ -298,16 +298,15 @@ func (r *Raus) holdLock(c *redis.Client) error { return errors.Wrap(err, "PUBLISH failed") } - res, err := c.GetSet(r.lockKey(), r.uuid).Result() + pipe := c.TxPipeline() + getset := pipe.GetSet(r.lockKey(), r.uuid) + pipe.Expire(r.lockKey(), LockExpires) + _, err := pipe.Exec() if err != nil { - return errors.Wrap(err, "GETSET failed") + return errors.Wrap(err, "GETSET or EXPIRE failed") } - if res != r.uuid { - return fatalError{fmt.Errorf("unexpected uuid got: %s", res)} - } - - if err := c.Expire(r.lockKey(), LockExpires).Err(); err != nil { - return errors.Wrap(err, "EXPIRE failed") + if v := getset.Val(); v != r.uuid { + return fatalError{fmt.Errorf("unexpected uuid got: %s", v)} } return nil }
use multi/exec to holdLock() Ensure lock key's TTL is set.
diff --git a/lineage/individual.py b/lineage/individual.py index <HASH>..<HASH> 100644 --- a/lineage/individual.py +++ b/lineage/individual.py @@ -295,9 +295,18 @@ class Individual(object): """ try: - return pd.read_csv(file, skiprows=1, na_values='--', - names=['rsid', 'chrom', 'pos', 'genotype'], - index_col=0, dtype={'chrom': object}) + df = pd.read_csv(file, skiprows=1, na_values='--', + names=['rsid', 'chrom', 'pos', 'genotype'], + index_col=0, dtype={'chrom': object}) + + # remove incongruous data + df = df.drop(df.loc[df['chrom'] == '0'].index) + df = df.drop(df.loc[df.index == 'RSID'].index) # second header for concatenated data + + # if second header existed, pos dtype will be object (should be np.int64) + df['pos'] = df['pos'].astype(np.int64) + + return df except Exception as err: print(err) return None
Improve reading and parsing of FTDNA files
diff --git a/tests/CrEOF/Spatial/Tests/DBAL/Types/GeometryTypeTest.php b/tests/CrEOF/Spatial/Tests/DBAL/Types/GeometryTypeTest.php index <HASH>..<HASH> 100644 --- a/tests/CrEOF/Spatial/Tests/DBAL/Types/GeometryTypeTest.php +++ b/tests/CrEOF/Spatial/Tests/DBAL/Types/GeometryTypeTest.php @@ -102,6 +102,28 @@ class GeometryTypeTest extends OrmTest } /** + * @group srid + */ + public function testPointGeometryWithZeroSrid() + { + $entity = new GeometryEntity(); + $point = new Point(1, 1); + + $point->setSrid(0); + $entity->setGeometry($point); + $this->_em->persist($entity); + $this->_em->flush(); + + $id = $entity->getId(); + + $this->_em->clear(); + + $queryEntity = $this->_em->getRepository(self::GEOMETRY_ENTITY)->find($id); + + $this->assertEquals($entity, $queryEntity); + } + + /** * @group common */ public function testLineStringGeometry()
Added additional test for geometry with srid of 0.
diff --git a/src/naarad/utils.py b/src/naarad/utils.py index <HASH>..<HASH> 100644 --- a/src/naarad/utils.py +++ b/src/naarad/utils.py @@ -501,7 +501,7 @@ def get_standardized_timestamp(timestamp, ts_format): elif ts_format == 'epoch': ts = datetime.datetime.utcfromtimestamp(int(timestamp)).strftime('%Y-%m-%d %H:%M:%S.%f') elif ts_format == 'epoch_ms': - ts = datetime.datetime.utcfromtimestamp(int(timestamp) / 1000).strftime('%Y-%m-%d %H:%M:%S.%f') + ts = datetime.datetime.utcfromtimestamp(float(timestamp) / 1000).strftime('%Y-%m-%d %H:%M:%S.%f') elif ts_format in ('%H:%M:%S', '%H:%M:%S.%f'): date_today = str(datetime.date.today()) ts = datetime.datetime.strptime(date_today + ' ' + timestamp,'%Y-%m-%d ' + ts_format).strftime('%Y-%m-%d %H:%M:%S.%f')
Fix epoch ms to standardized timestamp conversion to avoid loss of ms resolution
diff --git a/src/chart/map/MapSeries.js b/src/chart/map/MapSeries.js index <HASH>..<HASH> 100644 --- a/src/chart/map/MapSeries.js +++ b/src/chart/map/MapSeries.js @@ -81,8 +81,7 @@ define(function (require) { var map = echarts.getMap(option.map); var geoJson = map && map.geoJson; - geoJson && option.data - && (option.data = fillData(option.data, geoJson)); + geoJson && (option.data = fillData((option.data || []), geoJson)); return option; },
Optimize in case when map has no data
diff --git a/src/feat/agencies/net/agency.py b/src/feat/agencies/net/agency.py index <HASH>..<HASH> 100644 --- a/src/feat/agencies/net/agency.py +++ b/src/feat/agencies/net/agency.py @@ -550,6 +550,11 @@ class Agency(agency.Agency): iterator = (x.show_connection_status() for x in connections) return t.render(iterator) + @manhole.expose() + def show_locked_db_documents(self): + return ("_document_locks: %r\n_pending_notifications: %r" % + (self._database.show_document_locks())) + ### Manhole inspection methods ### @manhole.expose() diff --git a/src/feat/agencies/net/database.py b/src/feat/agencies/net/database.py index <HASH>..<HASH> 100644 --- a/src/feat/agencies/net/database.py +++ b/src/feat/agencies/net/database.py @@ -142,6 +142,9 @@ class Database(common.ConnectionManager, log.LogProxy, ChangeListener): time.left(self.reconnector.getTime()) return "CouchDB", self.is_connected(), self.host, self.port, eta + def show_document_locks(self): + return dict(self._document_locks), dict(self._pending_notifications) + ### IDbConnectionFactory def get_connection(self):
Expose in manhole method to take a sneakpeak at the database locks.
diff --git a/rhodes/rhodes-framework/spec/spec_helper.rb b/rhodes/rhodes-framework/spec/spec_helper.rb index <HASH>..<HASH> 100644 --- a/rhodes/rhodes-framework/spec/spec_helper.rb +++ b/rhodes/rhodes-framework/spec/spec_helper.rb @@ -10,6 +10,7 @@ $:.unshift(File.join(File.dirname(__FILE__), '..')) # Use the rubygem for local testing require 'spec/stubs' +require 'sqlite3/database' require 'rho/rho' require 'rhom/rhom'
fixed loading of sqlite, specs still don't run though
diff --git a/zuul-core/src/main/java/com/netflix/zuul/netty/ssl/BaseSslContextFactory.java b/zuul-core/src/main/java/com/netflix/zuul/netty/ssl/BaseSslContextFactory.java index <HASH>..<HASH> 100644 --- a/zuul-core/src/main/java/com/netflix/zuul/netty/ssl/BaseSslContextFactory.java +++ b/zuul-core/src/main/java/com/netflix/zuul/netty/ssl/BaseSslContextFactory.java @@ -75,7 +75,10 @@ public class BaseSslContextFactory implements SslContextFactory { ArrayList<X509Certificate> trustedCerts = getTrustedX509Certificates(); SslProvider sslProvider = chooseSslProvider(); - LOG.warn("Using SslProvider of type - " + sslProvider.name() + " for certChainFile - " + serverSslConfig.getCertChainFile()); + LOG.debug( + "Using SslProvider of type {} for certChainFile {}", + sslProvider.name(), + serverSslConfig.getCertChainFile()); InputStream certChainInput = new FileInputStream(serverSslConfig.getCertChainFile()); InputStream keyInput = getKeyInputStream();
zuul-core: avoid warnspam on SSL connections
diff --git a/girder/utility/gridfs_assetstore_adapter.py b/girder/utility/gridfs_assetstore_adapter.py index <HASH>..<HASH> 100644 --- a/girder/utility/gridfs_assetstore_adapter.py +++ b/girder/utility/gridfs_assetstore_adapter.py @@ -247,7 +247,12 @@ class GridFsAssetstoreAdapter(AbstractAssetstoreAdapter): } matching = ModelImporter().model('file').find(q, limit=2, fields=[]) if matching.count(True) == 1: - self.chunkColl.remove({'uuid': file['chunkUuid']}) + try: + self.chunkColl.remove({'uuid': file['chunkUuid']}) + except pymongo.errors.AutoReconnect: + # we can't reach the database. Go ahead and return; a system + # check will be necessary to remove the abandoned file + pass def cancelUpload(self, upload): """
If the mongo database for a gridfs assetstore goes offline, let files appear to be deleted. A system check will eventually need to clean up these abandoned files, but this will allow the assetstore to be removed from the system when it is no longer reachable. This doesn't fix the problem when the assetstore hasn't been reachable since this instance of girder was started (but it had been reachable once and has had files put in it).
diff --git a/buildozer/__init__.py b/buildozer/__init__.py index <HASH>..<HASH> 100644 --- a/buildozer/__init__.py +++ b/buildozer/__init__.py @@ -461,6 +461,14 @@ class Buildozer(object): requirements = [x for x in requirements if onlyname(x) not in target_available_packages] + if requirements and hasattr(sys, 'real_prefix'): + e = self.error + e('virtualenv is needed to install pure-Python modules, but') + e('virtualenv does not support nesting, and you are running') + e('buildozer in one. Please run buildozer outside of a') + e('virtualenv instead.') + exit(1) + # did we already installed the libs ? if exists(self.applibs_dir) and \ self.state.get('cache.applibs', '') == requirements:
throw error early if running in venv
diff --git a/core/src/main/java/com/capitalone/dashboard/repository/ComponentRepository.java b/core/src/main/java/com/capitalone/dashboard/repository/ComponentRepository.java index <HASH>..<HASH> 100644 --- a/core/src/main/java/com/capitalone/dashboard/repository/ComponentRepository.java +++ b/core/src/main/java/com/capitalone/dashboard/repository/ComponentRepository.java @@ -19,6 +19,6 @@ public interface ComponentRepository extends CrudRepository<Component, ObjectId> @Query(value="{'collectorItems.Build._id': ?0}") List<Component> findByBuildCollectorItemId(ObjectId buildCollectorItemId); - @Query(value="{'collectorItems.Deploy._id': ?0}") + @Query(value="{'collectorItems.Deployment._id': ?0}") List<Component> findByDeployCollectorItemId(ObjectId deployCollectorItemId); }
Fixed query for finding component by deployment collector item id. The deploy key is Deployment not Deploy.
diff --git a/.github/build-packages.php b/.github/build-packages.php index <HASH>..<HASH> 100644 --- a/.github/build-packages.php +++ b/.github/build-packages.php @@ -49,8 +49,8 @@ foreach ($dirs as $k => $dir) { $packages[$package->name][$package->version] = $package; - $versions = file_get_contents('https://packagist.org/packages/'.$package->name.'.json'); - $versions = json_decode($versions)->package->versions; + $versions = file_get_contents('https://packagist.org/p/'.$package->name.'.json'); + $versions = json_decode($versions)->packages->{$package->name}; if ($package->version === str_replace('-dev', '.x-dev', $versions->{'dev-master'}->extra->{'branch-alias'}->{'dev-master'})) { unset($versions->{'dev-master'});
fix the Composer API being used
diff --git a/sharding-jdbc/src/test/java/io/shardingsphere/dbtest/env/EnvironmentPath.java b/sharding-jdbc/src/test/java/io/shardingsphere/dbtest/env/EnvironmentPath.java index <HASH>..<HASH> 100644 --- a/sharding-jdbc/src/test/java/io/shardingsphere/dbtest/env/EnvironmentPath.java +++ b/sharding-jdbc/src/test/java/io/shardingsphere/dbtest/env/EnvironmentPath.java @@ -39,7 +39,7 @@ public final class EnvironmentPath { private static final String SHARDING_RULE_RESOURCES_PATH = "asserts/env/%s/sharding-rule.yaml"; - private static final String AUTHORITY_RESOURCES_PATH = "asserts/env/%s/authority.yaml"; + private static final String AUTHORITY_RESOURCES_PATH = "asserts/env/%s/authority.xml"; /** * Get database environment resource File.
moidfy AUTHORITY_RESOURCES_PATH.
diff --git a/pkg/tsdb/cloudwatch/credentials.go b/pkg/tsdb/cloudwatch/credentials.go index <HASH>..<HASH> 100644 --- a/pkg/tsdb/cloudwatch/credentials.go +++ b/pkg/tsdb/cloudwatch/credentials.go @@ -60,8 +60,8 @@ func GetCredentials(dsInfo *DatasourceInfo) (*credentials.Credentials, error) { []credentials.Provider{ &credentials.EnvProvider{}, &credentials.SharedCredentialsProvider{Filename: "", Profile: dsInfo.Profile}, - remoteCredProvider(stsSess), webIdentityProvider(stsSess), + remoteCredProvider(stsSess), }) stsConfig := &aws.Config{ Region: aws.String(dsInfo.Region),
CloudWatch: Prefer webIdentity over EC2 role also when assuming a role (#<I>) Same as #<I> but for assumed roles. When using service accounts (webIdentity) on EKS in combination with assuming roles in other AWS accounts Grafana needs to retrieve the service account credentials first and then needs to assume the configured role.
diff --git a/django_distill/renderer.py b/django_distill/renderer.py index <HASH>..<HASH> 100644 --- a/django_distill/renderer.py +++ b/django_distill/renderer.py @@ -146,6 +146,9 @@ def render_to_dir(output_dir, urls_to_distill, stdout): stdout('Rendering page: {} -> {} ["{}", {} bytes] {}'.format(local_uri, full_path, mime, len(content), renamed)) try: + dirname = os.path.dirname(full_path) + if not os.path.isdir(dirname): + os.makedirs(dirname) with open(full_path, 'w') as f: f.write(content) except IsADirectoryError:
support distill_file path that includes dir.
diff --git a/bcbio/pipeline/run_info.py b/bcbio/pipeline/run_info.py index <HASH>..<HASH> 100644 --- a/bcbio/pipeline/run_info.py +++ b/bcbio/pipeline/run_info.py @@ -302,7 +302,7 @@ ALGORITHM_KEYS = set(["platform", "aligner", "bam_clean", "bam_sort", "coverage_depth_max", "min_allele_fraction", "remove_lcr", "joint_group_size", "archive", "tools_off", "tools_on", "assemble_transcripts", - "mixup_check", "priority_regions"] + + "mixup_check", "priority_regions", "expression_caller"] + # back compatibility ["coverage_depth"]) ALG_ALLOW_BOOLEANS = set(["merge_bamprep", "mark_duplicates", "remove_lcr",
Add expression_caller to list of allowed algorithm keys.