diff stringlengths 65 26.7k | message stringlengths 7 9.92k |
|---|---|
diff --git a/test/feidee_utils/mixins/type_test.rb b/test/feidee_utils/mixins/type_test.rb
index <HASH>..<HASH> 100644
--- a/test/feidee_utils/mixins/type_test.rb
+++ b/test/feidee_utils/mixins/type_test.rb
@@ -1,4 +1,4 @@
-require "feidee_utils/mixins/parent_and_path"
+require "feidee_utils/mixins/type"
require 'minitest/autorun'
class FeideeUtils::Mixins::TypeTest < MiniTest::Test | Fix a wrong copy-paste in mixins/type test. |
diff --git a/karma.conf.js b/karma.conf.js
index <HASH>..<HASH> 100644
--- a/karma.conf.js
+++ b/karma.conf.js
@@ -58,7 +58,7 @@ module.exports = function(config) {
customLaunchers.SL_Safari8 = createCustomLauncher('safari', 8);
customLaunchers.SL_Safari9 = createCustomLauncher('safari', 9);
}
-/*
+
// Opera
if (runAll || process.env.SAUCE_OPERA) {
// customLaunchers.SL_Opera11 = createCustomLauncher('opera', 11, 'Windows XP');
@@ -78,7 +78,7 @@ module.exports = function(config) {
if (runAll || process.env.SAUCE_EDGE) {
customLaunchers.SL_Edge = createCustomLauncher('microsoftedge', null, 'Windows 10');
}
-
+/*
// IOS
if (runAll || process.env.SAUCE_IOS) {
// customLaunchers.SL_IOS7 = createCustomLauncher('iphone', '7.1', 'OS X 10.10'); | Adding IE and Edge to Saucelabs |
diff --git a/pronto/ontology.py b/pronto/ontology.py
index <HASH>..<HASH> 100644
--- a/pronto/ontology.py
+++ b/pronto/ontology.py
@@ -128,11 +128,14 @@ class Ontology(object):
def obo(self):
"""Returns the ontology serialized in obo format.
"""
+ meta = self._obo_meta().decode('utf-8')
+ meta = [meta] if meta else []
try:
- return "\n\n".join( self._obo_meta() + [t.obo for t in self if t.id.startswith(self.meta['namespace'][0])])
+ return "\n\n".join( meta + [t.obo.decode('utf-8') for t in self if t.id.startswith(self.meta['namespace'][0])])
except KeyError:
- return "\n\n".join(self._obo_meta() + [t.obo for t in self])
-
+ return "\n\n".join( meta + [t.obo.decode('utf-8') for t in self])
+
+ @output_bytes
def _obo_meta(self):
"""Generates the obo metadata header
@@ -167,7 +170,7 @@ class Ontology(object):
)
- return [obo_meta] if obo_meta else []
+ return obo_meta
def reference(self):
"""Make relationships point to classes of ontology instead of ontology id | Attempt fixing obo export with utf-8 chars in Py2 |
diff --git a/control/Controller.php b/control/Controller.php
index <HASH>..<HASH> 100644
--- a/control/Controller.php
+++ b/control/Controller.php
@@ -173,6 +173,8 @@ class Controller extends RequestHandler implements TemplateGlobalProvider {
* If $Action isn't given, it will use "index" as a default.
*/
protected function handleAction($request, $action) {
+ $this->extend('beforeCallActionHandler', $request, $action);
+
foreach($request->latestParams() as $k => $v) {
if($v || !isset($this->urlParams[$k])) $this->urlParams[$k] = $v;
} | Update Controller to allow extension in handleAction()
Controller's parent class (RequestHandler) has two extensions in its handleAction() method that are obscured by Controller's implementation. |
diff --git a/js/forum/src/main.js b/js/forum/src/main.js
index <HASH>..<HASH> 100644
--- a/js/forum/src/main.js
+++ b/js/forum/src/main.js
@@ -7,7 +7,7 @@ import SignUpModal from 'flarum/components/SignUpModal';
// import LogInModal from 'flarum/components/LogInModal';
app.initializers.add('sijad-recaptcha', () => {
- const isAvail = () => typeof grecaptcha !== 'undefined';
+ const isAvail = () => typeof grecaptcha !== 'undefined' && typeof grecaptcha.render === 'function';
const recaptchaValue = m.prop();
const recaptchaID = m.prop(); | Fix "grecaptcha.render is not a function"
This is very similar to <URL> |
diff --git a/src/actions/update.js b/src/actions/update.js
index <HASH>..<HASH> 100644
--- a/src/actions/update.js
+++ b/src/actions/update.js
@@ -9,7 +9,7 @@ const registerDependencyIOS = require('../ios/registerNativeModule');
const getProjectDependencies = () => {
const pjson = require(path.join(process.cwd(), './package.json'));
- return Object.keys(pjson.dependencies);
+ return Object.keys(pjson.dependencies).filter(name => name !== 'react-native');
};
/** | Blacklist react-native from dependencies |
diff --git a/driver/src/test/java/org/neo4j/driver/util/cc/ClusterMemberRoleDiscoveryFactory.java b/driver/src/test/java/org/neo4j/driver/util/cc/ClusterMemberRoleDiscoveryFactory.java
index <HASH>..<HASH> 100644
--- a/driver/src/test/java/org/neo4j/driver/util/cc/ClusterMemberRoleDiscoveryFactory.java
+++ b/driver/src/test/java/org/neo4j/driver/util/cc/ClusterMemberRoleDiscoveryFactory.java
@@ -74,7 +74,7 @@ public class ClusterMemberRoleDiscoveryFactory
@Override
public Map<BoltServerAddress,ClusterMemberRole> findClusterOverview( Driver driver )
{
- try ( Session session = driver.session( builder().withDefaultAccessMode( AccessMode.READ ).build() ) )
+ try ( Session session = driver.session( builder().withDefaultAccessMode( AccessMode.WRITE ).build() ) )
{
StatementResult result = session.run( "CALL dbms.cluster.overview()" );
Map<BoltServerAddress,ClusterMemberRole> overview = new HashMap<>(); | <I> server only have overview procedure on core members |
diff --git a/authomatic/providers/openid.py b/authomatic/providers/openid.py
index <HASH>..<HASH> 100644
--- a/authomatic/providers/openid.py
+++ b/authomatic/providers/openid.py
@@ -95,7 +95,7 @@ class SessionWrapper(object):
val = self.session.get(key)
if val and val.startswith(self.prefix):
split = val.split(self.prefix)[1]
- unpickled = pickle.loads(split)
+ unpickled = pickle.loads(str(split))
return unpickled
else: | Fixed a bug when openid session wrapper could not unpickle value
in python <I>. |
diff --git a/lib/metc/cli.rb b/lib/metc/cli.rb
index <HASH>..<HASH> 100644
--- a/lib/metc/cli.rb
+++ b/lib/metc/cli.rb
@@ -33,20 +33,20 @@ module Metc
if File.exists?("site.sqlite3")
puts "Warning: All index data will be lost!".red
- reply = agree("database already exists, overwrite?".red) {
+ reply = agree("Database already exists, overwrite?".red) {
|q| q.default = "n" }
if reply
FileUtils.cp( f, Dir.pwd )
- puts "database re-initialized".green
+ puts "Database re-initialized".green
else
- puts "database not initialized".red
+ puts "Database not initialized".red
end
else
FileUtils.cp( f, Dir.pwd )
- puts "database initialized".green
+ puts "Database initialized".green
end
@@ -57,7 +57,14 @@ module Metc
config = File.join( File.dirname(__FILE__), "../../config/config.ru" )
- FileUtils.cp( config, Dir.pwd )
+ if File.exists?("config.ru")
+ puts "Environment has already been staged, no action taken.".yellow
+ else
+
+ FileUtils.cp( config, Dir.pwd )
+ puts "Run 'rackup' to start testing.".green
+
+ end
end | don't overwrite staging files. |
diff --git a/samples/helloworld/helloworld.go b/samples/helloworld/helloworld.go
index <HASH>..<HASH> 100644
--- a/samples/helloworld/helloworld.go
+++ b/samples/helloworld/helloworld.go
@@ -46,10 +46,12 @@ func Draw(gc draw2d.GraphicContext, text string) {
gc.Save()
gc.SetFillColor(color.NRGBA{0xFF, 0x33, 0x33, 0xFF})
+ gc.SetStrokeColor(color.NRGBA{0xFF, 0x33, 0x33, 0xFF})
gc.Translate(145, 85)
gc.StrokeStringAt(text, -50, 0)
gc.Rotate(math.Pi / 4)
gc.SetFillColor(color.NRGBA{0x33, 0x33, 0xFF, 0xFF})
+ gc.SetStrokeColor(color.NRGBA{0x33, 0x33, 0xFF, 0xFF})
gc.StrokeString(text)
gc.Restore()
} | fix colors for stroke font in helloworld |
diff --git a/client/my-sites/checkout/composite-checkout/contact-validation.js b/client/my-sites/checkout/composite-checkout/contact-validation.js
index <HASH>..<HASH> 100644
--- a/client/my-sites/checkout/composite-checkout/contact-validation.js
+++ b/client/my-sites/checkout/composite-checkout/contact-validation.js
@@ -45,18 +45,18 @@ export default function createContactValidationCallback( {
'There was an error validating your contact information. Please contact support.'
)
);
- resolve( false );
- return;
}
- if ( data.messages ) {
+ if ( data && data.messages ) {
showErrorMessage(
translate(
'We could not validate your contact information. Please review and update all the highlighted fields.'
)
);
}
- applyDomainContactValidationResults( { ...data.messages } );
- resolve( ! ( data.success && areRequiredFieldsNotEmpty( decoratedContactDetails ) ) );
+ applyDomainContactValidationResults( data?.messages ?? {} );
+ resolve(
+ ! ( data && data.success && areRequiredFieldsNotEmpty( decoratedContactDetails ) )
+ );
} );
} );
}; | Composite checkout: Do not validate contact details if the endpoint call fails (#<I>)
Adjust the logic in the contact validation callback in composite checkout to ensure that if the request to the endpoint fails, we do not allow checkout to proceed. |
diff --git a/lib/mongodb_fulltext_search/mixins.rb b/lib/mongodb_fulltext_search/mixins.rb
index <HASH>..<HASH> 100644
--- a/lib/mongodb_fulltext_search/mixins.rb
+++ b/lib/mongodb_fulltext_search/mixins.rb
@@ -9,6 +9,16 @@ module MongodbFulltextSearch::Mixins
module ClassMethods
+ def create_indexes
+ if MongodbFulltextSearch.mongoid?
+ fulltext_search_options.values.each do |options|
+ if options[:model].respond_to? :create_indexes
+ options[:model].send :create_indexes
+ end
+ end
+ end
+ end
+
def fulltext_search_in(*args)
options = args.last.is_a?(Hash) ? args.pop : {} | Added feature to support manual index creation via Mongoid |
diff --git a/Generator/PHPFunction.php b/Generator/PHPFunction.php
index <HASH>..<HASH> 100644
--- a/Generator/PHPFunction.php
+++ b/Generator/PHPFunction.php
@@ -71,16 +71,6 @@ class PHPFunction extends BaseGenerator {
}
/**
- * Return a unique ID for this component.
- *
- * @return
- * The unique ID
- */
- public function getUniqueID() {
- return implode(':', [$this->type, $this->name]);
- }
-
- /**
* Return this component's parent in the component tree.
*/
function containingComponent() { | Removed unneeded override of getUniqueID(). |
diff --git a/mackup/main.py b/mackup/main.py
index <HASH>..<HASH> 100644
--- a/mackup/main.py
+++ b/mackup/main.py
@@ -58,10 +58,16 @@ def main():
app_db.get_files(MACKUP_APP_NAME))
mackup_app.restore()
+ # Initialize again the apps db, as the Mackup config might have changed
+ # it
+ mckp = Mackup()
+ app_db = ApplicationsDatabase()
+
# Restore the rest of the app configs, using the restored Mackup config
app_names = mckp.get_apps_to_backup()
# Mackup has already been done
app_names.remove(MACKUP_APP_NAME)
+
for app_name in app_names:
app = ApplicationProfile(mckp, app_db.get_files(app_name))
app.restore() | Initialize again the apps db, as the Mackup config might have changed it |
diff --git a/salt/states/file.py b/salt/states/file.py
index <HASH>..<HASH> 100644
--- a/salt/states/file.py
+++ b/salt/states/file.py
@@ -2060,8 +2060,15 @@ def directory(name,
return _error(
ret, 'Specified file {0} is not an absolute path'.format(name))
+ # checkng if bad symlink and force is applied
+ bad_link = False
+ log.debug(allow_symlink)
+ if os.path.islink(name) and force:
+ if not os.path.exists(os.readlink(name)):
+ bad_link = True
+
# Check for existing file or symlink
- if os.path.isfile(name) or (not allow_symlink and os.path.islink(name)):
+ if os.path.isfile(name) or (not allow_symlink and os.path.islink(name)) or bad_link:
# Was a backupname specified
if backupname is not None:
# Make a backup first | Added fix for issue <I> |
diff --git a/src/main/java/com/assertthat/selenium_shutterbug/core/Snapshot.java b/src/main/java/com/assertthat/selenium_shutterbug/core/Snapshot.java
index <HASH>..<HASH> 100644
--- a/src/main/java/com/assertthat/selenium_shutterbug/core/Snapshot.java
+++ b/src/main/java/com/assertthat/selenium_shutterbug/core/Snapshot.java
@@ -224,7 +224,6 @@ public abstract class Snapshot<T extends Snapshot> {
if (title != null && !title.isEmpty()) {
image = ImageProcessor.addTitle(image, title, Color.red, new Font("Serif", Font.BOLD, 20));
}
- driver.switchTo().defaultContent();
FileUtil.writeImage(image, EXTENSION, screenshotFile);
} | Do not switch to default content after frame screenshot. Leave it to the user |
diff --git a/jaraco/windows/filesystem.py b/jaraco/windows/filesystem.py
index <HASH>..<HASH> 100644
--- a/jaraco/windows/filesystem.py
+++ b/jaraco/windows/filesystem.py
@@ -63,11 +63,13 @@ CreateFile.restype = HANDLE
FILE_SHARE_READ = 1
FILE_SHARE_WRITE = 2
FILE_SHARE_DELETE = 4
+FILE_FLAG_OPEN_REPARSE_POINT = 0x00200000
FILE_FLAG_BACKUP_SEMANTICS = 0x2000000
NULL = 0
OPEN_EXISTING = 3
FILE_ATTRIBUTE_NORMAL = 0x80
GENERIC_READ = 0x80000000
+FILE_READ_ATTRIBUTES = 0x80
INVALID_HANDLE_VALUE = HANDLE(-1).value
CloseHandle = windll.kernel32.CloseHandle
@@ -199,7 +201,7 @@ def GetFinalPath(path):
FILE_SHARE_READ|FILE_SHARE_WRITE|FILE_SHARE_DELETE, # share mode
LPSECURITY_ATTRIBUTES(), # NULL pointer
OPEN_EXISTING,
- FILE_ATTRIBUTE_NORMAL|FILE_FLAG_BACKUP_SEMANTICS,
+ FILE_FLAG_OPEN_REPARSE_POINT|FILE_FLAG_BACKUP_SEMANTICS,
NULL,
) | Started working toward a symlink target that will work in all cases |
diff --git a/src/saml2/client.py b/src/saml2/client.py
index <HASH>..<HASH> 100644
--- a/src/saml2/client.py
+++ b/src/saml2/client.py
@@ -280,6 +280,7 @@ class Saml2Client(Base):
except KeyError:
session_indexes = None
+ sign = sign if sign is not None else self.logout_requests_signed
sign_post = False if binding == BINDING_HTTP_REDIRECT else sign
sign_redirect = False if binding == BINDING_HTTP_POST and sign else sign
diff --git a/src/saml2/entity.py b/src/saml2/entity.py
index <HASH>..<HASH> 100644
--- a/src/saml2/entity.py
+++ b/src/saml2/entity.py
@@ -241,7 +241,11 @@ class Entity(HTTPBase):
:return: A dictionary
"""
- # XXX sig-allowed should be configurable
+ # XXX SIG_ALLOWED_ALG should be configurable
+ # XXX should_sign stems from authn_requests_signed and sign_response
+ # XXX based on the type of the entity
+ # XXX but should also take into account the type of message (Authn/Logout/etc)
+ # XXX should_sign should be split and the exact config options should be checked
sign = sign if sign is not None else self.should_sign
sign_alg = sigalg or self.signing_algorithm
if sign_alg not in [long_name for short_name, long_name in SIG_ALLOWED_ALG]: | Sign logout requests according to logout_requests_signed config option |
diff --git a/test/model_test.js b/test/model_test.js
index <HASH>..<HASH> 100644
--- a/test/model_test.js
+++ b/test/model_test.js
@@ -276,9 +276,9 @@ describe('Seraph Model', function() {
food.save({name:"Pinnekjøtt"}, function(err, meat) {
assert(!err);
beer.read(meat.id, function(err, nothing) {
- assert(err);
+ assert(!nothing);
food.read(beer.id, function(err, nothing) {
- assert(err);
+ assert(!nothing);
done();
});
}); | Changed expected result from failing read call |
diff --git a/bench/graph_viewer/base/js/plot-benchmarks.js b/bench/graph_viewer/base/js/plot-benchmarks.js
index <HASH>..<HASH> 100644
--- a/bench/graph_viewer/base/js/plot-benchmarks.js
+++ b/bench/graph_viewer/base/js/plot-benchmarks.js
@@ -45,7 +45,7 @@ $(document).ready(function() {
plot_bm.options = {
series: {
- shadowSize: 6,
+ shadowSize: 0,
},
grid: {
clickable: true,
@@ -558,4 +558,4 @@ plot_bm.assign_overview_actions = function() {
yaxis:{}
}));
});
-};
\ No newline at end of file
+}; | Turn off shadows in graph viewer. |
diff --git a/samples/DatePickerSample.js b/samples/DatePickerSample.js
index <HASH>..<HASH> 100644
--- a/samples/DatePickerSample.js
+++ b/samples/DatePickerSample.js
@@ -10,7 +10,7 @@ enyo.kind({
{kind: "FittableColumns", style: "padding: 10px", components:[
{components: [
{content:$L("Choose Locale:"), classes:"onyx-sample-divider"},
- {kind: "onyx.PickerDecorator", style:"padding:10px;", onSelect: "pickerHandler", components: [
+ {kind: "onyx.PickerDecorator", style:"padding:10px;", onSelect: "localeChanged", components: [
{content: "Pick One...", style: "width: 200px"},
{kind: "onyx.Picker", name: "localePicker", components: [
{content: "en-US", active:true},
@@ -71,12 +71,12 @@ enyo.kind({
],
rendered: function() {
this.inherited(arguments);
- this.pickerHandler();
+ this.localeChanged();
},
initComponents: function() {
this.inherited(arguments);
},
- pickerHandler: function(){
+ localeChanged: function(){
this.formatDate();
return true;
}, | ENYO-<I>: Updated name of change handler.
Enyo-DCO-<I>- |
diff --git a/treeinterpreter/treeinterpreter.py b/treeinterpreter/treeinterpreter.py
index <HASH>..<HASH> 100644
--- a/treeinterpreter/treeinterpreter.py
+++ b/treeinterpreter/treeinterpreter.py
@@ -91,8 +91,10 @@ def _predict_tree(model, X, joint_contribution=False):
return direct_prediction, biases, contributions
else:
-
- for row, leaf in enumerate(leaves):
+ unique_leaves = np.unique(leaves)
+ unique_contributions = {}
+
+ for row, leaf in enumerate(unique_leaves):
for path in paths:
if leaf == path[-1]:
break
@@ -103,8 +105,11 @@ def _predict_tree(model, X, joint_contribution=False):
contrib = values_list[path[i+1]] - \
values_list[path[i]]
contribs[feature_index[path[i]]] += contrib
- contributions.append(contribs)
-
+ unique_contributions[leaf] = contribs
+
+ for row, leaf in enumerate(leaves):
+ contributions.append(unique_contributions[leaf])
+
return direct_prediction, biases, np.array(contributions) | improve the efficiency of tree leaf contribution calculation |
diff --git a/access_error.go b/access_error.go
index <HASH>..<HASH> 100644
--- a/access_error.go
+++ b/access_error.go
@@ -28,7 +28,7 @@ func writeJsonError(rw http.ResponseWriter, err error) {
rw.Header().Set("Content-Type", "application/json;charset=UTF-8")
rfcerr := ErrorToRFC6749Error(err)
- js, err := json.Marshal(err)
+ js, err := json.Marshal(rfcerr)
if err != nil {
http.Error(rw, fmt.Sprintf(`{"error": "%s"}`, err.Error()), http.StatusInternalServerError)
return | Makes use of rfcerr in access error endpoint writer explicit |
diff --git a/lib/rjr/dispatcher.rb b/lib/rjr/dispatcher.rb
index <HASH>..<HASH> 100644
--- a/lib/rjr/dispatcher.rb
+++ b/lib/rjr/dispatcher.rb
@@ -74,21 +74,12 @@ class Dispatcher
@@handlers[method] = handler
end
- # register a callback to the specified method.
- # a callback is the same as a handler except it takes an additional argument
- # specifying the node callback instance to use to send data back to client
- def self.add_callback(method, &handler)
- @@callbacks ||= {}
- @@callbacks[method] = handler
- end
-
# Helper to handle request messages
def self.dispatch_request(args = {})
method = args[:method]
@@handlers ||= {}
- @@callbacks ||= {}
- handler = @@handlers[method] || @@callbacks[method]
+ handler = @@handlers[method]
if !handler.nil?
begin | remove callbacks as distinction from handlers is no longer necessary |
diff --git a/java/backend-services/capabilities-directory/src/main/java/io/joynr/capabilities/GlobalDiscoveryEntryPersisted.java b/java/backend-services/capabilities-directory/src/main/java/io/joynr/capabilities/GlobalDiscoveryEntryPersisted.java
index <HASH>..<HASH> 100644
--- a/java/backend-services/capabilities-directory/src/main/java/io/joynr/capabilities/GlobalDiscoveryEntryPersisted.java
+++ b/java/backend-services/capabilities-directory/src/main/java/io/joynr/capabilities/GlobalDiscoveryEntryPersisted.java
@@ -178,6 +178,17 @@ public class GlobalDiscoveryEntryPersisted extends GlobalDiscoveryEntry {
this.clusterControllerId = clusterControllerId;
}
+ /**
+ * Stringifies the class
+ *
+ * @return stringified class content
+ */
+ @Override
+ public String toString() {
+ return "GlobalDiscoveryEntryPersisted [" + super.toString() + ", " + "providerQosPersisted="
+ + providerQosPersisted + ", clusterControllerId=" + clusterControllerId + ", gbid=" + gbid + "]";
+ }
+
@Override
public int hashCode() {
final int prime = 31; | [JEE] Add toString method to GlobalDiscoveryEntryPersisted |
diff --git a/lib/falkorlib/version.rb b/lib/falkorlib/version.rb
index <HASH>..<HASH> 100644
--- a/lib/falkorlib/version.rb
+++ b/lib/falkorlib/version.rb
@@ -19,7 +19,7 @@ module FalkorLib #:nodoc:
# MAJOR: Defines the major version
# MINOR: Defines the minor version
# PATCH: Defines the patch version
- MAJOR, MINOR, PATCH = 0, 3, 10
+ MAJOR, MINOR, PATCH = 0, 3, 11
module_function | bump to version '<I>' |
diff --git a/printf.go b/printf.go
index <HASH>..<HASH> 100644
--- a/printf.go
+++ b/printf.go
@@ -45,11 +45,12 @@ var (
)
var (
- force bool
+ force *bool
)
func ForceColor(c bool) {
- force = c
+ tf := c
+ force = &tf
}
func strip(s string) string {
@@ -87,7 +88,10 @@ func CanColorize(out io.Writer) bool {
}
func ShouldColorize(out io.Writer) bool {
- return force || CanColorize(out)
+ if force != nil {
+ return *force
+ }
+ return CanColorize(out)
}
func Printf(format string, a ...interface{}) (int, error) { | Allow ForceColor() to force color off
Previously, it just forced it on, and there was no way to unambiguously
remove colorization. |
diff --git a/src/Repository/Storage/QueryableStorageInterface.php b/src/Repository/Storage/QueryableStorageInterface.php
index <HASH>..<HASH> 100644
--- a/src/Repository/Storage/QueryableStorageInterface.php
+++ b/src/Repository/Storage/QueryableStorageInterface.php
@@ -7,7 +7,7 @@ use Systream\Repository\Model\ModelInterface;
use Systream\Repository\ModelList\ModelListInterface;
use Systream\Repository\Storage\Query\QueryInterface;
-interface QueryableStorageInterface
+interface QueryableStorageInterface extends StorageInterface
{
/**
* @param QueryInterface $query | Queryable storage interface extends Storage interface |
diff --git a/src/de/mrapp/android/preference/PreferenceActivity.java b/src/de/mrapp/android/preference/PreferenceActivity.java
index <HASH>..<HASH> 100644
--- a/src/de/mrapp/android/preference/PreferenceActivity.java
+++ b/src/de/mrapp/android/preference/PreferenceActivity.java
@@ -23,6 +23,7 @@ import android.app.Activity;
import android.app.Fragment;
import android.app.FragmentTransaction;
import android.os.Bundle;
+import android.view.KeyEvent;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
@@ -266,6 +267,17 @@ public abstract class PreferenceActivity extends Activity implements
}
@Override
+ public final boolean onKeyDown(final int keyCode, final KeyEvent event) {
+ if (keyCode == KeyEvent.KEYCODE_BACK && !isSplitScreen()
+ && currentlyShownFragment != null) {
+ showPreferenceHeaders();
+ return true;
+ }
+
+ return super.onKeyDown(keyCode, event);
+ }
+
+ @Override
protected final void onCreate(final Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.preference_activity); | The behavior of the device's back button is now overridden. |
diff --git a/src/Graviton/ProxyBundle/Definition/ApiDefinition.php b/src/Graviton/ProxyBundle/Definition/ApiDefinition.php
index <HASH>..<HASH> 100644
--- a/src/Graviton/ProxyBundle/Definition/ApiDefinition.php
+++ b/src/Graviton/ProxyBundle/Definition/ApiDefinition.php
@@ -129,7 +129,7 @@ class ApiDefinition
*
* @param boolean $withHost url with hostname
* @param string $prefix add a prefix to the url (blub/endpoint/url)
- * @param string $host
+ * @param string $host Host to be used instead of the host defined in the swagger json
*
* @return array
*/ | Added missing descriptoin in docblock |
diff --git a/src/AwsS3V3/AwsS3V3Adapter.php b/src/AwsS3V3/AwsS3V3Adapter.php
index <HASH>..<HASH> 100644
--- a/src/AwsS3V3/AwsS3V3Adapter.php
+++ b/src/AwsS3V3/AwsS3V3Adapter.php
@@ -44,6 +44,7 @@ class AwsS3V3Adapter implements FilesystemAdapter
'ContentEncoding',
'ContentLength',
'ContentType',
+ 'ContentMD5',
'Expires',
'GrantFullControl',
'GrantRead', | Adding `ContentMD5` option to `AVAILABLE_OPTIONS` array
his proposed change is adding `ContentMD5` option to `AVAILABLE_OPTIONS` array. Without this option in the array it is impossible to upload file on file lock enabled S3. |
diff --git a/lib/cld3.rb b/lib/cld3.rb
index <HASH>..<HASH> 100644
--- a/lib/cld3.rb
+++ b/lib/cld3.rb
@@ -76,7 +76,7 @@ module CLD3
# The arguments are two Numeric objects.
def initialize(min_num_bytes = MIN_NUM_BYTES_TO_CONSIDER, max_num_bytes = MAX_NUM_BYTES_TO_CONSIDER)
- raise ArgumentError if max_num_bytes <= 0 || min_num_bytes < 0 || min_num_bytes >= max_num_bytes
+ raise ArgumentError if min_num_bytes < 0 || min_num_bytes >= max_num_bytes
@cc = Unstable::NNetLanguageIdentifier::Pointer.new(Unstable.new_NNetLanguageIdentifier(min_num_bytes, max_num_bytes))
end | Accept 0 as min_num_bytes |
diff --git a/gflex/base.py b/gflex/base.py
index <HASH>..<HASH> 100644
--- a/gflex/base.py
+++ b/gflex/base.py
@@ -687,7 +687,13 @@ class Flexure(Utility, Plotting):
# Finalize
def finalize(self):
- # Just print a line to stdout
+ # Can include an option for this later, but for the moment, this will
+ # clear the coefficient array so it doens't cause problems for model runs
+ # searching for the proper rigidity
+ try:
+ del self.coeff_matrix
+ except:
+ pass
if self.Quiet==False:
print "" | Clear coeff_matrix during finalize() to allow Te to change between runs |
diff --git a/sources/scalac/transformer/ExplicitOuterClasses.java b/sources/scalac/transformer/ExplicitOuterClasses.java
index <HASH>..<HASH> 100644
--- a/sources/scalac/transformer/ExplicitOuterClasses.java
+++ b/sources/scalac/transformer/ExplicitOuterClasses.java
@@ -153,6 +153,9 @@ public class ExplicitOuterClasses extends Transformer {
}
case Ident(Name name): {
+ if (! name.isTermName())
+ return super.transform(tree);
+
// Follow "outer" links to fetch data in outer classes.
Symbol sym = tree.symbol();
Symbol owner = sym.classOwner(); | - bug fix: do not use outer links to access typ...
- bug fix: do not use outer links to access type parameters of outer
classes |
diff --git a/zappa/zappa.py b/zappa/zappa.py
index <HASH>..<HASH> 100644
--- a/zappa/zappa.py
+++ b/zappa/zappa.py
@@ -344,7 +344,8 @@ class Zappa(object):
return None
return venv
- def contains_python_files_or_subdirs(self, filename, dirs, files):
+ @staticmethod
+ def contains_python_files_or_subdirs(dirs, files):
return len(dirs) > 0 or len([filename for filename in files if filename.endswith('.py') or filename.endswith('.pyc')]) > 0
def create_lambda_zip( self,
@@ -541,7 +542,7 @@ class Zappa(object):
with open(os.path.join(root, filename), 'rb') as f:
zipf.writestr(zipi, f.read(), compression_method)
- if '__init__.py' not in files and self.contains_python_files_or_subdirs(filename, dirs, files):
+ if '__init__.py' not in files and self.contains_python_files_or_subdirs(dirs, files):
tmp_init = os.path.join(temp_project_path, '__init__.py')
open(tmp_init, 'a').close()
os.chmod(tmp_init, 0o755) | Small cleanup: static method and removed unused var |
diff --git a/src/Tasks/Engines/DoormanRunner.php b/src/Tasks/Engines/DoormanRunner.php
index <HASH>..<HASH> 100644
--- a/src/Tasks/Engines/DoormanRunner.php
+++ b/src/Tasks/Engines/DoormanRunner.php
@@ -103,6 +103,11 @@ class DoormanRunner extends BaseRunner implements TaskRunnerEngine
$manager->setLogPath($logPath);
}
+ $phpBinary = Environment::getEnv('SS_DOORMAN_PHPBINARY');
+ if ($phpBinary && is_executable($phpBinary)) {
+ $manager->setBinary($phpBinary);
+ }
+
// Assign default rules
$defaultRules = $this->getDefaultRules(); | feat: Allow ProcessManager PHP binary to be configurable via environment variable using Doorman. |
diff --git a/airflow/cli/commands/webserver_command.py b/airflow/cli/commands/webserver_command.py
index <HASH>..<HASH> 100644
--- a/airflow/cli/commands/webserver_command.py
+++ b/airflow/cli/commands/webserver_command.py
@@ -260,7 +260,8 @@ class GunicornMonitor(LoggingMixin):
new_worker_count = min(
self.num_workers_expected - num_workers_running, self.worker_refresh_batch_size
)
- self.log.debug(
+ # log at info since we are trying fix an error logged just above
+ self.log.info(
'[%d / %d] Spawning %d workers',
num_ready_workers_running,
num_workers_running, | Change log level from debug to info when spawning new gunicorn workers (#<I>) |
diff --git a/lib/cli/commands/apps.rb b/lib/cli/commands/apps.rb
index <HASH>..<HASH> 100644
--- a/lib/cli/commands/apps.rb
+++ b/lib/cli/commands/apps.rb
@@ -559,6 +559,8 @@ module VMC::Cli::Command
else
FileUtils.mkdir(explode_dir)
files = Dir.glob('{*,.[^\.]*}')
+ # Do not process .git files
+ files.delete('.git') if files
FileUtils.cp_r(files, explode_dir)
end | Do not process .git directories |
diff --git a/lib/processors/index.js b/lib/processors/index.js
index <HASH>..<HASH> 100644
--- a/lib/processors/index.js
+++ b/lib/processors/index.js
@@ -4,8 +4,8 @@ var path = require('path'),
jade = require('jade'),
coffee = require(root + '/public/js/vendor/coffee-script').CoffeeScript,
markdown = require(root + '/public/js/vendor/markdown'),
- less = require('less'),
- stylus = require('stylus');
+ less = require('less');
+ //stylus = require('stylus');
module.exports = {
@@ -54,6 +54,10 @@ module.exports = {
stylus: function (source) {
var css = '';
+ return source;
+/*
+
+ // disabled due to huge infinite loop bug... ::sigh::
try {
stylus(source).render(function (err, result) {
if (err) {
@@ -67,5 +71,6 @@ module.exports = {
} catch (e) {}
return css;
+*/
}
}; | Removed stylus support from the server |
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -105,11 +105,14 @@ if not ISRELEASED:
# partial clone, manually construct version string
# this is the format before we started using git-describe
# to get an ordering on dev version strings.
- rev = "v%s.dev-%s" % (VERSION, rev)
+ rev = "v%s+dev.%s" % (VERSION, rev)
# Strip leading v from tags format "vx.y.z" to get th version string
FULLVERSION = rev.lstrip('v')
+ # make sure we respect PEP 440
+ FULLVERSION = FULLVERSION.replace("-", "+dev", 1).replace("-", ".")
+
else:
FULLVERSION += QUALIFIER | Respect PEP <I> (#<I>)
* Respect PEP <I>
Change unreleased version numbers as to respect PEP <I>. Rather than
`<I>-9-g<I>a1a<I>` we will have `<I>+dev9.g<I>a1a<I>`. This means
automated setuptools requirements can be respected. Closes #<I>.
* The fallback version string should also respect PEP <I> |
diff --git a/lib/hesabu/version.rb b/lib/hesabu/version.rb
index <HASH>..<HASH> 100644
--- a/lib/hesabu/version.rb
+++ b/lib/hesabu/version.rb
@@ -1,3 +1,3 @@
module Hesabu
- VERSION = "0.1.3".freeze
+ VERSION = "0.1.4".freeze
end | Bump hesabu to <I> |
diff --git a/src/index.js b/src/index.js
index <HASH>..<HASH> 100644
--- a/src/index.js
+++ b/src/index.js
@@ -1,4 +1,4 @@
-import { withTranslation, Trans } from 'react-i18next'
+import { withTranslation, useTranslation, Trans } from 'react-i18next'
import hoistNonReactStatics from 'hoist-non-react-statics'
import createConfig from './config/create-config'
@@ -27,9 +27,12 @@ export default class NextI18Next {
withTranslation(namespace, options)(Component), Component)
const nextI18NextInternals = { config: this.config, i18n: this.i18n }
- this.Trans = Trans
this.Link = withInternals(Link, nextI18NextInternals)
this.Router = wrapRouter(nextI18NextInternals)
+
+ /* Directly export `react-i18next` methods */
+ this.Trans = Trans
+ this.useTranslation = useTranslation
}
} | feat: Add useTranslation (#<I>) |
diff --git a/lib/pragmatic_tokenizer/tokenizer.rb b/lib/pragmatic_tokenizer/tokenizer.rb
index <HASH>..<HASH> 100644
--- a/lib/pragmatic_tokenizer/tokenizer.rb
+++ b/lib/pragmatic_tokenizer/tokenizer.rb
@@ -138,7 +138,7 @@ module PragmaticTokenizer
process_numbers!
remove_short_tokens! if minimum_length > 0
process_punctuation!
- remove_stop_words!(stop_words) if remove_stop_words
+ remove_stop_words! if remove_stop_words
remove_emoji! if remove_emoji
remove_emails! if remove_emails
mentions! if mentions
@@ -237,11 +237,11 @@ module PragmaticTokenizer
end
end
- def remove_stop_words!(stop_words)
+ def remove_stop_words!
if downcase
- @tokens -= stop_words
+ @tokens -= @stop_words
else
- @tokens.delete_if { |t| stop_words.include?(Unicode.downcase(t)) }
+ @tokens.delete_if { |t| @stop_words.include?(Unicode.downcase(t)) }
end
end | no need to pass stop words to method |
diff --git a/lib/cinch/user.rb b/lib/cinch/user.rb
index <HASH>..<HASH> 100644
--- a/lib/cinch/user.rb
+++ b/lib/cinch/user.rb
@@ -354,7 +354,7 @@ module Cinch
when String
self.to_s == other
when Bot
- self.nick == other.config.nick
+ self.nick == other.nick
else
false
end | when comparing a User with a Bot, use the bot's current nick, not the configured one |
diff --git a/modules/LocationUtils.js b/modules/LocationUtils.js
index <HASH>..<HASH> 100644
--- a/modules/LocationUtils.js
+++ b/modules/LocationUtils.js
@@ -1,4 +1,5 @@
import invariant from 'invariant'
+import warning from 'warning'
import { parsePath } from './PathUtils'
import { POP } from './Actions'
@@ -8,6 +9,11 @@ export const createQuery = (props) =>
export const createLocation = (input = '/', action = POP, key = null) => {
const object = typeof input === 'string' ? parsePath(input) : input
+ warning(
+ !object.path,
+ 'Location descriptor objects should have a `pathname`, not a `path`.'
+ )
+
const pathname = object.pathname || '/'
const search = object.search || ''
const hash = object.hash || '' | Warn on location descriptor objects with `path` |
diff --git a/autopep8.py b/autopep8.py
index <HASH>..<HASH> 100644
--- a/autopep8.py
+++ b/autopep8.py
@@ -13,7 +13,7 @@ import tokenize
from optparse import OptionParser
from subprocess import Popen, PIPE
-__version__ = '0.1'
+__version__ = '0.1.1'
pep8bin = 'pep8'
@@ -28,9 +28,13 @@ class FixPEP8(object):
[fixed method list]
- e231
+ - e261
+ - e262
- e302
- e303
- e401
+ - e701
+ - e702
- w291
- w293
- w391
@@ -167,6 +171,12 @@ class FixPEP8(object):
self.indent_word * indent_level + target[c:].lstrip()
self.source[result['line'] - 1] = fixed_source
+ def fix_e702(self, result):
+ target = self.source[result['line'] - 1]
+ f = target.split(";")
+ fixed = "".join(f)
+ self.source[result['line'] - 1] = fixed
+
def fix_w291(self, result):
fixed_line = self.source[result['line'] - 1].strip()
self.source[result['line'] - 1] = "%s%s" % (fixed_line, self.newline) | featured: e<I> fixed method. (and added doc) |
diff --git a/src/article/shared/EditorPanel.js b/src/article/shared/EditorPanel.js
index <HASH>..<HASH> 100644
--- a/src/article/shared/EditorPanel.js
+++ b/src/article/shared/EditorPanel.js
@@ -106,8 +106,8 @@ export default class EditorPanel extends Component {
appState.propagateUpdates()
}
- _scrollElementIntoView (el) {
- this._getContentPanel().scrollElementIntoView(el, 'onlyIfNotVisible')
+ _scrollElementIntoView (el, force) {
+ this._getContentPanel().scrollElementIntoView(el, !force)
}
_getContentPanel () { | Let EditorPanel scrollIntoView when forced. |
diff --git a/wdtk-datamodel/src/main/java/org/wikidata/wdtk/datamodel/implementation/StatementImpl.java b/wdtk-datamodel/src/main/java/org/wikidata/wdtk/datamodel/implementation/StatementImpl.java
index <HASH>..<HASH> 100644
--- a/wdtk-datamodel/src/main/java/org/wikidata/wdtk/datamodel/implementation/StatementImpl.java
+++ b/wdtk-datamodel/src/main/java/org/wikidata/wdtk/datamodel/implementation/StatementImpl.java
@@ -20,6 +20,7 @@ package org.wikidata.wdtk.datamodel.implementation;
* #L%
*/
+import java.util.Collections;
import java.util.List;
import org.apache.commons.lang3.Validate;
@@ -85,7 +86,7 @@ public class StatementImpl implements Statement {
@Override
public List<? extends Snak> getQualifiers() {
- return qualifiers;
+ return Collections.unmodifiableList(qualifiers);
}
@Override
@@ -95,7 +96,9 @@ public class StatementImpl implements Statement {
@Override
public List<List<? extends Snak>> getReferences() {
- return references;
+ // TODO This still allows inner lists of Snaks to be modified. Do
+ // we have to protect against this?
+ return Collections.unmodifiableList(references);
}
/* | Return only unmodifiable collections |
diff --git a/lib/compiler.js b/lib/compiler.js
index <HASH>..<HASH> 100644
--- a/lib/compiler.js
+++ b/lib/compiler.js
@@ -191,7 +191,8 @@ Compiler.prototype = {
if (filter.isASTFilter) {
this.buf.push(fn(filter.block, this, filter.attrs));
} else {
- this.buffer(fn(utils.text(filter.block.nodes.join('')), filter.attrs));
+ var text = filter.block.nodes.join('');
+ this.buffer(utils.text(fn(text, filter.attrs)));
}
},
diff --git a/test/filters.test.js b/test/filters.test.js
index <HASH>..<HASH> 100644
--- a/test/filters.test.js
+++ b/test/filters.test.js
@@ -83,6 +83,9 @@ module.exports = {
assert.equal(
'<script type="text/javascript">\n' + js + '\n</script>',
render(':coffeescript\n square = (x) ->\n x * x'));
+
+ assert.equal('<script type="text/javascript">\n(function() {\n alert(\'test\');\n}).call(this);\n</script>'
+ , render(":coffeescript\n alert 'test'"));
},
'test parse tree': function(assert){ | Fixed single-quote filter escape bug. Closes #<I>
escape quotes _after_ passing to filter |
diff --git a/schedule/src/main/java/org/openbase/jul/schedule/TimeoutSplitter.java b/schedule/src/main/java/org/openbase/jul/schedule/TimeoutSplitter.java
index <HASH>..<HASH> 100644
--- a/schedule/src/main/java/org/openbase/jul/schedule/TimeoutSplitter.java
+++ b/schedule/src/main/java/org/openbase/jul/schedule/TimeoutSplitter.java
@@ -71,7 +71,7 @@ public class TimeoutSplitter {
*/
public long getTime() throws TimeoutException {
final long time = timeout - (System.currentTimeMillis() - timestamp);
- if (time < 0) {
+ if (time <= 0) {
throw new TimeoutException();
}
return time; | Fix TimeoutSplitter by making sure zero is never returned during timeout computation and a TimeoutException is thrown instead. |
diff --git a/src/extensions/default/CSSPseudoSelectorHints/main.js b/src/extensions/default/CSSPseudoSelectorHints/main.js
index <HASH>..<HASH> 100644
--- a/src/extensions/default/CSSPseudoSelectorHints/main.js
+++ b/src/extensions/default/CSSPseudoSelectorHints/main.js
@@ -42,7 +42,7 @@ define(function (require, exports, module) {
// Magic code to get around CM's 'pseudo' identification logic
// As per CSS3 spec :
- // -> ':' identifies pseudo slectors
+ // -> ':' identifies pseudo selectors
// -> '::' identifies pseudo elements
// We should strictly check for single or double occurance of ':' by slicing
// the line text till the token start position | slectors -> selectors (#<I>) |
diff --git a/interfaces/python/infomap.py b/interfaces/python/infomap.py
index <HASH>..<HASH> 100644
--- a/interfaces/python/infomap.py
+++ b/interfaces/python/infomap.py
@@ -118,7 +118,7 @@ def _construct_args(
DeprecationWarning,
)
- if not include_self_links:
+ if include_self_links is not None and not include_self_links:
args += " --no-self-links"
if no_self_links: | fix(python): no_self_links was always set unless include_self_links=True |
diff --git a/src/Composer/Package/Archiver/PharArchiver.php b/src/Composer/Package/Archiver/PharArchiver.php
index <HASH>..<HASH> 100644
--- a/src/Composer/Package/Archiver/PharArchiver.php
+++ b/src/Composer/Package/Archiver/PharArchiver.php
@@ -22,7 +22,7 @@ use Composer\Package\PackageInterface;
*/
class PharArchiver implements ArchiverInterface
{
- static protected $formats = array(
+ protected static $formats = array(
'zip' => \Phar::ZIP,
'tar' => \Phar::TAR,
); | Follow PSR-2 for method modifier ordering |
diff --git a/src/FieldsBuilder.php b/src/FieldsBuilder.php
index <HASH>..<HASH> 100644
--- a/src/FieldsBuilder.php
+++ b/src/FieldsBuilder.php
@@ -525,6 +525,11 @@ class FieldsBuilder extends ParentDelegationBuilder implements NamedBuilder
return $this->getFieldManager()->getField($name);
}
+ public function fieldExists($name)
+ {
+ return $this->getFieldManager()->fieldNameExists($name);
+ }
+
/**
* Modify an already defined field
* @param string $name Name of the field | Expose a fieldExists method to FieldsBuilder |
diff --git a/intranet/static/js/eighth/schedule.js b/intranet/static/js/eighth/schedule.js
index <HASH>..<HASH> 100644
--- a/intranet/static/js/eighth/schedule.js
+++ b/intranet/static/js/eighth/schedule.js
@@ -162,4 +162,15 @@ $(function() {
});
}
});
+ $(".schedule-form input[type='submit']").click(function(e) {
+ var activities = "";
+ $("tr.form-row:not(.hidden)").each(function(i,el) {
+ if (!$("td[data-field='sponsors'] .selectize-input", el).hasClass('has-items')) {
+ activities += "\n " + $(".block-name a", this).html().trim();
+ }
+ });
+ if (activities !== "" && !confirm("Are you sure you want to add the following activities without a sponsor?\n" + activities)) {
+ e.preventDefault();
+ }
+ });
}); | Add warning when an activity is scheduled without a sponsor |
diff --git a/cassiopeia-diskstore/cassiopeia_diskstore/staticdata.py b/cassiopeia-diskstore/cassiopeia_diskstore/staticdata.py
index <HASH>..<HASH> 100644
--- a/cassiopeia-diskstore/cassiopeia_diskstore/staticdata.py
+++ b/cassiopeia-diskstore/cassiopeia_diskstore/staticdata.py
@@ -472,9 +472,9 @@ class StaticDataDiskService(SimpleKVDiskService):
return dto
if "id" in query:
- rune = find_matching_attribute(runes["data"].values(), "runeId", str(query["id"]))
+ rune = find_matching_attribute(runes["data"], "runeId", str(query["id"]))
elif "name" in query:
- rune = find_matching_attribute(runes["data"].values(), "runeName", query["name"])
+ rune = find_matching_attribute(runes["data"], "runeName", query["name"])
else:
raise ValueError("Impossible!")
if rune is None:
@@ -509,4 +509,3 @@ class StaticDataDiskService(SimpleKVDiskService):
version=item["version"],
locale=item["locale"])
self._put(key, item)
- | runes data is list rather than dict |
diff --git a/tests/bootstrap.php b/tests/bootstrap.php
index <HASH>..<HASH> 100644
--- a/tests/bootstrap.php
+++ b/tests/bootstrap.php
@@ -5,7 +5,7 @@ require_once __DIR__ . '/../src/loader.php';
// Add PEAR to include path for Travis CI
if(!class_exists('PEAR_RunTest'))
- set_include_path(get_include_path() . PATH_SEPARATOR . realpath(__DIR__ . '(../lib/pear-core'));
+ set_include_path(get_include_path() . PATH_SEPARATOR . realpath(__DIR__ . '/../lib/pear-core'));
// Test helper objects autoloader | [Travis CI] fix my stupidness |
diff --git a/hazelcast/src/main/java/com/hazelcast/internal/networking/nonblocking/NonBlockingIOThread.java b/hazelcast/src/main/java/com/hazelcast/internal/networking/nonblocking/NonBlockingIOThread.java
index <HASH>..<HASH> 100644
--- a/hazelcast/src/main/java/com/hazelcast/internal/networking/nonblocking/NonBlockingIOThread.java
+++ b/hazelcast/src/main/java/com/hazelcast/internal/networking/nonblocking/NonBlockingIOThread.java
@@ -127,7 +127,8 @@ public class NonBlockingIOThread extends Thread implements OperationHostileThrea
private static Selector newSelector(ILogger logger) {
try {
Selector selector = Selector.open();
- if (Boolean.getBoolean("tcp.optimizedselector")) {
+ boolean optimize = Boolean.parseBoolean(System.getProperty("hazelcast.io.optimizeselector", "true"));
+ if (optimize) {
optimize(selector, logger);
}
return selector; | Enabled optimized selector by default.
Various other projects like Netty, Agrona do this be default as well.
There is a switch to disable it, and if something fails while trying
to modify, it will fallback on the non optimized version anyway. |
diff --git a/core/formatter.js b/core/formatter.js
index <HASH>..<HASH> 100644
--- a/core/formatter.js
+++ b/core/formatter.js
@@ -35,23 +35,30 @@ var formatter = function(results, format) {
}
function formatPlain() {
- var res = '',
- obj = results.metrics,
- key;
+ var colors = require('ansicolors'),
+ res = '',
+ metrics = results.metrics;
// header
res += 'phantomas metrics for <' + results.url + '>:\n\n';
// metrics
- for (key in obj) {
- res += '* ' + key + ': ' + obj[key]+ '\n';
- }
+ Object.keys(metrics).forEach(function(metric) {
+ res += '* ' + metric + ': ' + metrics[metric]+ '\n';
+ });
res += '\n';
// notices
results.notices.forEach(function(msg) {
- res += '> ' + msg + "\n";
+ msg = msg.
+ // color labels
+ replace(/^[^ <][^:<]+:/, colors.brightGreen).
+ // color URLs
+ replace(/<[^>]+>/, colors.brightBlue);
+
+ // add a notice
+ res += msg + "\n";
});
return res.trim();
@@ -62,4 +69,3 @@ var formatter = function(results, format) {
};
exports.formatter = formatter;
- | Improve logging:
* color URLs and notices labels |
diff --git a/cwltool/job.py b/cwltool/job.py
index <HASH>..<HASH> 100644
--- a/cwltool/job.py
+++ b/cwltool/job.py
@@ -105,8 +105,8 @@ class CommandLineJob(object):
with open(createtmp, "w") as f:
f.write(vol.resolved.encode("utf-8"))
runtime.append(u"--volume=%s:%s:ro" % (createtmp, vol.target))
- runtime.append(u"--volume=%s:%s:rw" % (os.path.abspath(self.outdir), "/var/spool/cwl"))
- runtime.append(u"--volume=%s:%s:rw" % (os.path.abspath(self.tmpdir), "/tmp"))
+ runtime.append(u"--volume=%s:%s:rw" % (os.path.realpath(self.outdir), "/var/spool/cwl"))
+ runtime.append(u"--volume=%s:%s:rw" % (os.path.realpath(self.tmpdir), "/tmp"))
runtime.append(u"--workdir=%s" % ("/var/spool/cwl"))
runtime.append("--read-only=true")
if (kwargs.get("enable_net", None) is None and | abspath -> realpath for volume paths |
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -79,8 +79,8 @@ extra_objects = glob.glob(os.path.join(cfitsio_build_dir,'*.o'))
extra_objects += glob.glob(os.path.join(cfitsio_zlib_dir,'*.o'))
if platform.system()=='Darwin':
- extra_compile_args=['-arch','i386','-arch','x86_64']
- extra_link_args=['-arch','i386','-arch','x86_64']
+ extra_compile_args=['-arch','x86_64']
+ extra_link_args=['-arch','x86_64']
else:
extra_compile_args=[]
extra_link_args=[] | removed -iarch in setup.py |
diff --git a/core-bundle/src/Resources/contao/config/config.php b/core-bundle/src/Resources/contao/config/config.php
index <HASH>..<HASH> 100644
--- a/core-bundle/src/Resources/contao/config/config.php
+++ b/core-bundle/src/Resources/contao/config/config.php
@@ -371,10 +371,6 @@ $GLOBALS['TL_CROP'] = array
*/
$GLOBALS['TL_CRON'] = array
(
- 'monthly' => array
- (
- 'purgeImageCache' => array('Automator', 'purgeImageCache')
- ),
'weekly' => array
(
'generateSitemap' => array('Automator', 'generateSitemap'), | [Core] Do not purge the image cache automatically. |
diff --git a/tweepy/api.py b/tweepy/api.py
index <HASH>..<HASH> 100644
--- a/tweepy/api.py
+++ b/tweepy/api.py
@@ -1423,12 +1423,11 @@ class API(object):
# image must be gif, jpeg, png, webp
if not file_type:
- if f is None:
- file_type = imghdr.what(filename) or mimetypes.guess_type(filename)[0]
- else:
- file_type = imghdr.what(filename, h=f.read()) or mimetypes.guess_type(filename)[0]
- f.seek(0) # Reset to beginning of file
-
+ h = None
+ if f is not None:
+ h = f.read(32)
+ f.seek(0)
+ file_type = imghdr.what(filename, h=h) or mimetypes.guess_type(filename)[0]
if file_type is None:
raise TweepError('Could not determine file type')
if file_type in ['gif', 'jpeg', 'png', 'webp']: | Resolving media_upload conflicts |
diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100755
--- a/setup.py
+++ b/setup.py
@@ -17,7 +17,6 @@ setuptools.setup(
classifiers=[
"Development Status :: 2 - Pre-Alpha"
],
- include_package_data=True,
test_suite="nion.swift.test",
entry_points={
'console_scripts': [ | Ensure all resource files are included in sdist.
Removed include_package_data since it is used to either include what is
in the manifest or _everything_ in under version control, but seemingly
only CVS or Subversion, not Git.
Once removed, the package_data tag properly adds the stylesheet to the
sdist. |
diff --git a/spec/client_pool_spec.rb b/spec/client_pool_spec.rb
index <HASH>..<HASH> 100644
--- a/spec/client_pool_spec.rb
+++ b/spec/client_pool_spec.rb
@@ -261,6 +261,7 @@ describe ZK::Pool do
describe 'disconnected client' do
before do
+ pending
flexmock(@cnx1) do |m|
m.should_receive(:connected?).and_return(false)
end | w<I>t! the on_connected race was *the* bug (sheesh) |
diff --git a/src/common/event_util.js b/src/common/event_util.js
index <HASH>..<HASH> 100644
--- a/src/common/event_util.js
+++ b/src/common/event_util.js
@@ -33,6 +33,10 @@ sre.EventUtil.KeyCode = {
ENTER: 13,
ESC: 27,
SPACE: 32,
+ PAGE_UP: 33, // also NUM_NORTH_EAST
+ PAGE_DOWN: 34, // also NUM_SOUTH_EAST
+ END: 35, // also NUM_SOUTH_WEST
+ HOME: 36, // also NUM_NORTH_WEST
LEFT: 37,
UP: 38,
RIGHT: 39, | Adds some additional keycodes. |
diff --git a/javascript/node/selenium-webdriver/testing/index.js b/javascript/node/selenium-webdriver/testing/index.js
index <HASH>..<HASH> 100644
--- a/javascript/node/selenium-webdriver/testing/index.js
+++ b/javascript/node/selenium-webdriver/testing/index.js
@@ -41,16 +41,14 @@
* The provided wrappers leverage the {@link webdriver.promise.ControlFlow}
* to simplify writing asynchronous tests:
*
- * var By = require('selenium-webdriver').By,
- * until = require('selenium-webdriver').until,
- * firefox = require('selenium-webdriver/firefox'),
- * test = require('selenium-webdriver/testing');
+ * var {Builder, By, until} = require('selenium-webdriver');
+ * var test = require('selenium-webdriver/testing');
*
* test.describe('Google Search', function() {
* var driver;
*
* test.before(function() {
- * driver = new firefox.Driver();
+ * driver = new Builder().forBrowser('firefox').build();
* });
*
* test.after(function() { | [js] Update example in selenium-webdriver/testing documentation
The firefox.Driver constructor was changed in <I> to not do any work.
Users should always use the Builder class to create new driver
instances.
Fixes #<I> |
diff --git a/packages/react/src/components/DatePicker/DatePicker.js b/packages/react/src/components/DatePicker/DatePicker.js
index <HASH>..<HASH> 100644
--- a/packages/react/src/components/DatePicker/DatePicker.js
+++ b/packages/react/src/components/DatePicker/DatePicker.js
@@ -383,6 +383,13 @@ export default class DatePicker extends Component {
}
}
+ componentDidUpdate({ dateFormat: prevDateFormat }) {
+ const { dateFormat } = this.props;
+ if (this.cal && prevDateFormat !== dateFormat) {
+ this.cal.set({ dateFormat });
+ }
+ }
+
componentWillUnmount() {
if (this.cal) {
this.cal.destroy(); | fix(date-picker): support changing date format (#<I>)
This change allows change in `dateFormat` prop after initialization
reflected correctly to the underlying Flatpickr. |
diff --git a/nerve/report.go b/nerve/report.go
index <HASH>..<HASH> 100644
--- a/nerve/report.go
+++ b/nerve/report.go
@@ -86,8 +86,11 @@ func toReport(status error, s *Service) Report {
func (r *Report) String() string {
var buffer bytes.Buffer
-
- buffer.WriteString(fmt.Sprint(r.Available))
+ if r.Available == nil {
+ buffer.WriteString(fmt.Sprint(true))
+ } else {
+ buffer.WriteString(fmt.Sprint(*r.Available))
+ }
buffer.WriteString(" ")
buffer.WriteString(r.Name)
buffer.WriteString(" ") | Check available nil pointer in String |
diff --git a/pytds/__init__.py b/pytds/__init__.py
index <HASH>..<HASH> 100644
--- a/pytds/__init__.py
+++ b/pytds/__init__.py
@@ -286,6 +286,11 @@ class Connection(object):
last_error = LoginError("Cannot connect to server '{0}': {1}".format(host, e), e)
else:
sock.setsockopt(socket.SOL_TCP, socket.TCP_NODELAY, 1)
+
+ # default keep alive should be 30 seconds according to spec:
+ # https://msdn.microsoft.com/en-us/library/dd341108.aspx
+ sock.setsockopt(socket.SOL_SOCKET, socket.SO_KEEPALIVE, 30)
+
sock.settimeout(retry_time)
conn = _TdsSocket(self._use_tz)
try: | set TCP keep-alive to <I> seconds according to spec
should fix #<I> |
diff --git a/src/Database/Type/DateTimeType.php b/src/Database/Type/DateTimeType.php
index <HASH>..<HASH> 100644
--- a/src/Database/Type/DateTimeType.php
+++ b/src/Database/Type/DateTimeType.php
@@ -245,7 +245,7 @@ class DateTimeType extends BaseType
/**
* @inheritDoc
*/
- public function manyToPHP(array $values, array $fields, DriverInterface $driver)
+ public function manyToPHP(array $values, array $fields, DriverInterface $driver): array
{
foreach ($fields as $field) {
if (!isset($values[$field])) { | Add missing return type to manyToPHP |
diff --git a/lib/commander/runner.rb b/lib/commander/runner.rb
index <HASH>..<HASH> 100644
--- a/lib/commander/runner.rb
+++ b/lib/commander/runner.rb
@@ -211,9 +211,7 @@ module Commander
def require_program *keys
keys.each do |key|
- if program(key).nil? or program(key).empty?
- raise CommandError, "Program #{key} required (use #program method)"
- end
+ raise CommandError, "program #{key} required" if program(key).nil? or program(key).empty?
end
end | Refactored #require_program |
diff --git a/cassandra/io/libevreactor.py b/cassandra/io/libevreactor.py
index <HASH>..<HASH> 100644
--- a/cassandra/io/libevreactor.py
+++ b/cassandra/io/libevreactor.py
@@ -102,10 +102,10 @@ class LibevLoop(object):
def _run_loop(self):
while True:
- end_condition = self._loop.start()
+ self._loop.start()
# there are still active watchers, no deadlock
with self._lock:
- if not self._shutdown and (end_condition or self._live_conns):
+ if not self._shutdown and self._live_conns:
log.debug("Restarting event loop")
continue
else: | there is no return from libev Loop_start
This is leftover from when the class was copied over
from asyncore. |
diff --git a/lib/beaker-answers/version.rb b/lib/beaker-answers/version.rb
index <HASH>..<HASH> 100644
--- a/lib/beaker-answers/version.rb
+++ b/lib/beaker-answers/version.rb
@@ -1,5 +1,5 @@
module BeakerAnswers
module Version
- STRING = '0.26.3'
+ STRING = '0.27.0'
end
end | (GEM) update beaker-answers version to <I> |
diff --git a/src/Sylius/Bundle/CoreBundle/Installer/Provider/DatabaseSetupCommandsProvider.php b/src/Sylius/Bundle/CoreBundle/Installer/Provider/DatabaseSetupCommandsProvider.php
index <HASH>..<HASH> 100644
--- a/src/Sylius/Bundle/CoreBundle/Installer/Provider/DatabaseSetupCommandsProvider.php
+++ b/src/Sylius/Bundle/CoreBundle/Installer/Provider/DatabaseSetupCommandsProvider.php
@@ -45,12 +45,10 @@ final class DatabaseSetupCommandsProvider implements DatabaseSetupCommandsProvid
return [
'doctrine:database:create',
'doctrine:migrations:migrate' => ['--no-interaction' => true],
- 'cache:clear',
];
}
return array_merge($this->getRequiredCommands($input, $output, $questionHelper), [
- 'cache:clear',
'doctrine:migrations:version' => [
'--add' => true,
'--all' => true, | Fix installation errors by removing cache clearing during the process |
diff --git a/lib/oxcelix/workbook.rb b/lib/oxcelix/workbook.rb
index <HASH>..<HASH> 100644
--- a/lib/oxcelix/workbook.rb
+++ b/lib/oxcelix/workbook.rb
@@ -1,3 +1,4 @@
+require "tmpdir"
# The namespace for all classes and modules included on Oxcelix.
module Oxcelix
# Helper methods for the Workbook class
@@ -48,7 +49,7 @@ module Oxcelix
# * adding comments to the cells
# * Converting each sheet to a Matrix object
def initialize(filename=nil, options={})
- @destination = Dir.pwd+'/tmp'
+ @destination = Dir.mktmpdir
@sheets=[]
@sheetbase={}
@sharedstrings=[]
@@ -95,7 +96,7 @@ module Oxcelix
def parse(filename, options={})
thrs = []
thrcount = 0
-
+
@sheets.each do |x|
thrs[thrcount] = Thread.new
{ | Excel file now gets unzipped in the system Temp directory |
diff --git a/tools/mpy-tool.py b/tools/mpy-tool.py
index <HASH>..<HASH> 100755
--- a/tools/mpy-tool.py
+++ b/tools/mpy-tool.py
@@ -532,6 +532,7 @@ class RawCodeNative(RawCode):
if config.native_arch in (
MP_NATIVE_ARCH_X86,
MP_NATIVE_ARCH_X64,
+ MP_NATIVE_ARCH_ARMV6,
MP_NATIVE_ARCH_XTENSA,
MP_NATIVE_ARCH_XTENSAWIN,
): | tools/mpy-tool.py: Support relocating ARMv6 arch. |
diff --git a/pypsa/io.py b/pypsa/io.py
index <HASH>..<HASH> 100644
--- a/pypsa/io.py
+++ b/pypsa/io.py
@@ -618,6 +618,7 @@ def _import_from_importer(network, importer, basename, skip_time=False):
snapshot_levels = set(["period", "timestep", "snapshot"]).intersection(df.columns)
if snapshot_levels:
df.set_index(sorted(snapshot_levels), inplace=True)
+ network.set_snapshots(df.index)
cols = ['objective', 'generators', 'stores']
if not df.columns.intersection(cols).empty: | io: revert removal of needed line |
diff --git a/vendor/assets/javascripts/bs-breadcrumbs.js b/vendor/assets/javascripts/bs-breadcrumbs.js
index <HASH>..<HASH> 100644
--- a/vendor/assets/javascripts/bs-breadcrumbs.js
+++ b/vendor/assets/javascripts/bs-breadcrumbs.js
@@ -52,9 +52,11 @@ THIS COMPPONENT IS CUSTOMIZED!
displayName = _this.get('nameDictionary')["" + _this.dictionaryNamePrefix + "." + routeName];
displayIcon = null;
} else {
- displayName = route.handler.routeName.split('.').pop();
- displayName = displayName[0].toUpperCase() + displayName.slice(1).toLowerCase();
- displayIcon = null;
+ if (route.handler.breadcrumbs != false) {
+ displayName = route.handler.routeName.split('.').pop();
+ displayName = displayName[0].toUpperCase() + displayName.slice(1).toLowerCase();
+ displayIcon = null;
+ }
}
crumb = Ember.Object.create({
route: route.handler.routeName,
@@ -68,7 +70,10 @@ THIS COMPPONENT IS CUSTOMIZED!
name: route.handler.context.get('name')
});
}
- return _this.get('content').pushObject(crumb);
+ if(displayName){
+ return _this.get('content').pushObject(crumb);
+ }
+ return;
});
return this.get('content.lastObject').set('active', true);
} | Add support to hide breadcrumbs in bs-breadcrumbs |
diff --git a/middleman-core/lib/middleman-core/application.rb b/middleman-core/lib/middleman-core/application.rb
index <HASH>..<HASH> 100644
--- a/middleman-core/lib/middleman-core/application.rb
+++ b/middleman-core/lib/middleman-core/application.rb
@@ -98,11 +98,11 @@ module Middleman
# Middleman mode. Defaults to :server, set to :build by the build process
# @return [String]
- define_setting :mode, ((ENV['MM_ENV'] && ENV['MM_ENV'].to_sym) || :server), 'Middleman mode. Defaults to :server'
+ define_setting :mode, :server, 'Middleman mode. Defaults to :server'
# Middleman environment. Defaults to :development
# @return [String]
- define_setting :environment, :development, 'Middleman environment. Defaults to :development'
+ define_setting :environment, ((ENV['MM_ENV'] && ENV['MM_ENV'].to_sym) || :development), 'Middleman environment. Defaults to :development'
# Which file should be used for directory indexes
# @return [String] | Don't set mode AND environment with the same ENV |
diff --git a/src/Console/BaseCommand.php b/src/Console/BaseCommand.php
index <HASH>..<HASH> 100644
--- a/src/Console/BaseCommand.php
+++ b/src/Console/BaseCommand.php
@@ -221,10 +221,7 @@ abstract class BaseCommand implements CommandInterface
* @param \Cake\Console\ConsoleIo $io The console io
* @return int|null The exit code or null for success
*/
- public function execute(Arguments $args, ConsoleIo $io): ?int
- {
- return null;
- }
+ abstract public function execute(Arguments $args, ConsoleIo $io): ?int;
/**
* Halt the the current process with a StopException. | Add an abstract method to indicate what is expected of implementations. |
diff --git a/openxc/src/com/openxc/interfaces/VehicleInterfaceFactory.java b/openxc/src/com/openxc/interfaces/VehicleInterfaceFactory.java
index <HASH>..<HASH> 100644
--- a/openxc/src/com/openxc/interfaces/VehicleInterfaceFactory.java
+++ b/openxc/src/com/openxc/interfaces/VehicleInterfaceFactory.java
@@ -5,9 +5,26 @@ import java.lang.reflect.InvocationTargetException;
import android.content.Context;
import android.util.Log;
+/**
+ * A factory that uses reflection to create instance of VehicleInterface
+ * implementations.
+ */
public class VehicleInterfaceFactory {
private static final String TAG = "VehicleInterfaceFactory";
+ /**
+ * Obtain the Class object for a given VehicleInterface class name.
+ *
+ * The class must be in the classpath of the process' context, or an
+ * exception will be thrown.
+ *
+ * @param interfaceName the canonical name of class implementing
+ * {@link VehicleInterface}
+ * @return the Class object, if found.
+ * @throws VehicleInterfaceException if the named class could not be found
+ * or loaded.
+ *
+ */
public static Class<? extends VehicleInterface> findClass(
String interfaceName) throws VehicleInterfaceException {
Log.d(TAG, "Looking up class for name " + interfaceName); | Document a method in VehicleInterfaceFactory. |
diff --git a/app/classes/timthumb.php b/app/classes/timthumb.php
index <HASH>..<HASH> 100644
--- a/app/classes/timthumb.php
+++ b/app/classes/timthumb.php
@@ -41,6 +41,15 @@ if (empty($matches[1]) || empty($matches[2]) || empty($matches[4])) {
die("Malformed thumbnail URL. Should look like '/thumbs/320x240c/filename.jpg'.");
}
+/**
+ * Bolt specific: Set BOLT_PROJECT_ROOT_DIR, and Bolt-specific settings..
+ */
+if (substr(__DIR__, -20) == DIRECTORY_SEPARATOR.'bolt-public'.DIRECTORY_SEPARATOR.'classes') { // installed bolt with composer
+ require_once __DIR__ . '/../../../vendor/bolt/bolt/app/bootstrap.php';
+} else {
+ require_once __DIR__ . '/../bootstrap.php';
+}
+
// Let's get on with the rest..
$yamlparser = new Symfony\Component\Yaml\Parser();
$config['general'] = $yamlparser->parse(file_get_contents(BOLT_CONFIG_DIR .'/config.yml') . "\n"); | Fix thumbnail issue introduced in pull #<I> |
diff --git a/lib/enum_ish/definer/active_record.rb b/lib/enum_ish/definer/active_record.rb
index <HASH>..<HASH> 100644
--- a/lib/enum_ish/definer/active_record.rb
+++ b/lib/enum_ish/definer/active_record.rb
@@ -27,7 +27,7 @@ module EnumIsh
enum.mapping.invert[read_attribute(enum.name)]
end
define_method "#{enum.name}=" do |value|
- write_attribute(enum.name, enum.mapping[value])
+ write_attribute(enum.name, enum.mapping[value] || value)
end
end
end | Fix accessor mapping for activerecord |
diff --git a/indra/preassembler/grounding_mapper/mapper.py b/indra/preassembler/grounding_mapper/mapper.py
index <HASH>..<HASH> 100644
--- a/indra/preassembler/grounding_mapper/mapper.py
+++ b/indra/preassembler/grounding_mapper/mapper.py
@@ -1,6 +1,6 @@
__all__ = ['GroundingMapper', 'load_grounding_map', 'default_grounding_map',
'default_agent_map', 'default_ignores', 'default_misgrounding_map',
- 'default_mapper']
+ 'default_mapper', 'gm']
import os
import csv
import json
@@ -567,6 +567,7 @@ def _load_default_ignores():
default_grounding_map = _load_default_grounding_map()
+gm = default_grounding_map # For backwards compatibility, redundant
default_misgrounding_map = _load_default_misgrounding_map()
default_agent_map = _load_default_agent_map()
default_ignores = _load_default_ignores() | Add gm (redundant) for backwards compatibility |
diff --git a/Flame/Rest/Security/Cors.php b/Flame/Rest/Security/Cors.php
index <HASH>..<HASH> 100644
--- a/Flame/Rest/Security/Cors.php
+++ b/Flame/Rest/Security/Cors.php
@@ -79,7 +79,15 @@ class Cors extends Object implements ICors
if (isset($this->config['headers'])) {
if ($this->config['headers'] === '*') {
$headers = array('origin', 'content-type', 'authorization');
- $this->config['headers'] = array_merge($headers, array_keys((array) $this->httpRequest->getHeaders()));
+ /*
+ * Because OPTIONS requests aren't contain declared headers but send list of
+ * headers in Access-Control-Request-Headers header
+ */
+ $expectedHeaders = $this->httpRequest->getHeader("Access-Control-Request-Headers", []);
+ if (!empty($expectedHeaders)) {
+ $expectedHeaders = array_map('trim', explode(",", $expectedHeaders));
+ }
+ $this->config['headers'] = array_merge($headers, array_keys((array) $this->httpRequest->getHeaders()), $expectedHeaders);
}
if (is_array($this->config['headers'])) { | Fixed 'all headers' for OPTIONS requests |
diff --git a/pkg/cmd/cli/cli.go b/pkg/cmd/cli/cli.go
index <HASH>..<HASH> 100644
--- a/pkg/cmd/cli/cli.go
+++ b/pkg/cmd/cli/cli.go
@@ -292,7 +292,7 @@ func CommandFor(basename string) *cobra.Command {
case "kubectl":
cmd = NewCmdKubectl(basename, out)
default:
- cmd = NewCommandCLI(basename, basename, in, out, errout)
+ cmd = NewCommandCLI("oc", "oc", in, out, errout)
}
if cmd.UsageFunc() == nil { | don't use baseCmdName when printing client version
This patch addresses an issue where the client name will be printed as
what the "base / root" command was when invoking the "version" cmd. |
diff --git a/glue/statedb.py b/glue/statedb.py
index <HASH>..<HASH> 100644
--- a/glue/statedb.py
+++ b/glue/statedb.py
@@ -70,6 +70,23 @@ class StateSegmentDatabaseLFNExistsException(exceptions.Exception):
+class StateSegmentDatabaseSegnumException(exceptions.Exception):
+ """
+ Exceptions raised by the classes and methods in this module
+ will be instances of this class.
+ """
+ def __init__(self, args=None):
+ """
+ Create an instance of this class exception.
+
+ @param args:
+
+ @return: Instance of class StateSegmentDatabaseSegnumException
+ """
+ self.args = args
+
+
+
class StateSegmentDatabase:
"""
Class that represents an instance of a state segment database
@@ -292,6 +309,11 @@ class StateSegmentDatabase:
Publish a state segment for a state vector in the database
"""
+ # check that we are in science mode if the user has given a segnum
+ if segnum and val != 65535:
+ msg = "segnum can only be specified if val is 65535"
+ raise StateSegmentDatabaseSegnumException, msg
+
# check that we have an lfn registered
if not self.lfn_id:
msg = "No LFN registered to publish state information" | added a science mode check on segnum |
diff --git a/mod/quiz/report/overview/report.php b/mod/quiz/report/overview/report.php
index <HASH>..<HASH> 100644
--- a/mod/quiz/report/overview/report.php
+++ b/mod/quiz/report/overview/report.php
@@ -207,7 +207,7 @@ class quiz_report extends quiz_default_report {
$table->add_data($row);
}
- echo '<script type="text/javascript" src="'.$CFG->wwwroot.'/mod/quiz/report/overview/utility.js" />';
+ echo '<script type="text/javascript" src="'.$CFG->wwwroot.'/mod/quiz/report/overview/utility.js"></script>';
echo '<form id="attemptsform" method="post" action="report.php" onsubmit="var menu = document.getElementById(\'actionmenu\'); return confirm_if(menu.options[menu.selectedIndex].value == \'delete\', \''.$strreallydel.'\');">';
echo '<input type="hidden" name="id" value="'.$cm->id.'" />'; | IE doesn't display anything after a script include tag that closes with />.
Please close all your script tags like <script></script> or else.
Disgusting. |
diff --git a/value/src/org/immutables/value/Value.java b/value/src/org/immutables/value/Value.java
index <HASH>..<HASH> 100644
--- a/value/src/org/immutables/value/Value.java
+++ b/value/src/org/immutables/value/Value.java
@@ -201,9 +201,15 @@ public @interface Value {
@Target(ElementType.TYPE)
public @interface Transformer {}
+/*
+ @Beta
+ @Documented
+ @Retention(RetentionPolicy.SOURCE)
+ @Target(ElementType.METHOD)
+ public @interface Builder {}
+*/
/*
* Generate visitor for a set of nested classes.
-
@Beta
@Documented
@Retention(RetentionPolicy.SOURCE)
@@ -302,8 +308,8 @@ public @interface Value {
* Generated accessor methods have annotation copied from original accessor method. However
* {@code org.immutables.*} and {@code java.lang.*} are not copied. This allow some frameworks to
* work with immutable types as they can with beans, using getters and annotations on them.
- * @deprecated consider using styles, such as {@link Style#} May be undeprecated if it will be
- * usefull.
+ * @deprecated consider using styles, such as {@link BeanStyle.Accessors}. May be undeprecated if
+ * found to be useful.
*/
@Deprecated
@Documented | deprecate @Value.Getters. may be undeprecated in future if found useful |
diff --git a/lib/v1/gremlin/Gremlin.js b/lib/v1/gremlin/Gremlin.js
index <HASH>..<HASH> 100644
--- a/lib/v1/gremlin/Gremlin.js
+++ b/lib/v1/gremlin/Gremlin.js
@@ -37,7 +37,7 @@ class Gremlin {
Morphism() {
const path = new Path(['M', []]);
- path._query = this._query;
+ // path._query = this._query;
return path;
} | Path object should not know _query function. |
diff --git a/Twig/EasyAdminTwigExtension.php b/Twig/EasyAdminTwigExtension.php
index <HASH>..<HASH> 100644
--- a/Twig/EasyAdminTwigExtension.php
+++ b/Twig/EasyAdminTwigExtension.php
@@ -93,7 +93,7 @@ class EasyAdminTwigExtension extends \Twig_Extension
* property doesn't exist or its value is not accessible. This ensures that
* the function never generates a warning or error message when calling it.
*
- * @param string $view The vie in which the item is being rendered
+ * @param string $view The view in which the item is being rendered
* @param string $entityName The name of the entity associated with the item
* @param object $item The item which is being rendered
* @param array $fieldMetadata The metadata of the actual field being rendered
@@ -120,6 +120,11 @@ class EasyAdminTwigExtension extends \Twig_Extension
'view' => $view,
);
+ // if the template path doesn't start with '@EasyAdmin/' it's a custom template; use it
+ if ('@EasyAdmin/' !== substr($fieldMetadata['template'], 0, 11)) {
+ return $twig->render($fieldMetadata['template'], $templateParameters);
+ }
+
if (null === $value) {
return $twig->render($entityConfiguration['templates']['label_null'], $templateParameters);
} | Make sure that custom field templates are always used, regardless of the property type |
diff --git a/lib/irt.rb b/lib/irt.rb
index <HASH>..<HASH> 100644
--- a/lib/irt.rb
+++ b/lib/irt.rb
@@ -1,5 +1,6 @@
-# allows standard rails 3 console to run without loading irt
-unless defined?(Rails::Console) && !ENV['IRT_COMMAND']
+# allows to skip irb overriding, so you can use the regular irb/rails console
+# even if irt is required in the Gemfile
+if ENV['IRT_COMMAND']
at_exit{ Dye.print_reset_colors } | fix condition to allow irb/rails console with irt required in the Gemfile |
diff --git a/lib/loader.js b/lib/loader.js
index <HASH>..<HASH> 100644
--- a/lib/loader.js
+++ b/lib/loader.js
@@ -21,7 +21,7 @@ module.exports = function (source) {
return source;
}
- // The following part renders the template with lodash as aminimalistic loader
+ // The following part renders the template with lodash as a minimalistic loader
//
const template = _.template(source, _.defaults(options, { interpolate: /<%=([\s\S]+?)%>/g, variable: 'data' }));
// Require !!lodash - using !! will disable all loaders (e.g. babel) | Fix tiny typo
Hey noticed a tiny typo in the comment.
"as aminimalistic loader" => "as a minimalistic loader" |
diff --git a/cmd/fs-v1-multipart.go b/cmd/fs-v1-multipart.go
index <HASH>..<HASH> 100644
--- a/cmd/fs-v1-multipart.go
+++ b/cmd/fs-v1-multipart.go
@@ -713,6 +713,11 @@ func (fs *FSObjects) AbortMultipartUpload(ctx context.Context, bucket, object, u
}
fs.appendFileMapMu.Lock()
+ // Remove file in tmp folder
+ file := fs.appendFileMap[uploadID]
+ if file != nil {
+ fsRemoveFile(ctx, file.filePath)
+ }
delete(fs.appendFileMap, uploadID)
fs.appendFileMapMu.Unlock()
@@ -725,10 +730,14 @@ func (fs *FSObjects) AbortMultipartUpload(ctx context.Context, bucket, object, u
}
return toObjectErr(err, bucket, object)
}
+
// Ignore the error returned as Windows fails to remove directory if a file in it
// is Open()ed by the backgroundAppend()
fsRemoveAll(ctx, uploadIDDir)
+ // It is safe to ignore any directory not empty error (in case there were multiple uploadIDs on the same object)
+ fsRemoveDir(ctx, fs.getMultipartSHADir(bucket, object))
+
return nil
} | Remove tmp file and multipart folder in FS mode. (#<I>)
Fixes #<I> |
diff --git a/src/main/java/com/stripe/model/Subscription.java b/src/main/java/com/stripe/model/Subscription.java
index <HASH>..<HASH> 100644
--- a/src/main/java/com/stripe/model/Subscription.java
+++ b/src/main/java/com/stripe/model/Subscription.java
@@ -22,6 +22,7 @@ public class Subscription extends ApiResource implements MetadataStore<Subscript
String billing;
Long billingCycleAnchor;
BillingThresholds billingThresholds;
+ Long cancelAt;
Boolean cancelAtPeriodEnd;
Long canceledAt;
Long created; | Add support for `cancel_at` on `Subscription` |
diff --git a/sieve/rules/actions.py b/sieve/rules/actions.py
index <HASH>..<HASH> 100644
--- a/sieve/rules/actions.py
+++ b/sieve/rules/actions.py
@@ -5,18 +5,6 @@ class SieveActions(object):
self.actions = []
self.implicit_keep = implicit_keep
- def __str__(self):
- return self.actions.__str__
-
- def __len__(self):
- return self.actions.__len__()
-
- def __getitem__(self, key):
- return self.actions.__getitem__(key)
-
- def __iter__(self):
- return self.actions.__iter__()
-
def append(self, action, action_args=None):
self.actions.append((action, action_args))
return self
@@ -24,3 +12,6 @@ class SieveActions(object):
def cancel_implicit_keep(self):
self.implicit_keep = False
return self
+
+ def __getattr__(self, name):
+ return getattr(self.actions, name) | make SieveActions delegate to a list instead of impersonate one |
diff --git a/seqcluster/libs/tool.py b/seqcluster/libs/tool.py
index <HASH>..<HASH> 100644
--- a/seqcluster/libs/tool.py
+++ b/seqcluster/libs/tool.py
@@ -311,7 +311,8 @@ def _add_complete_cluster(idx, meta, clusters):
locilen_sorted = sorted(clus.iteritems(), key=operator.itemgetter(1), reverse=True)
maxidl = locilen_sorted[0][0]
c = cluster(idx)
- # c.add_id_member(clusters.idmembers, maxidl)
+ for idc in meta:
+ c.add_id_member(clusters[idc].idmembers.keys(), maxidl)
c.id = idx
c.toomany = len(meta)
return c | add all sequences to long clusters |
diff --git a/test/UriHelperTest.php b/test/UriHelperTest.php
index <HASH>..<HASH> 100644
--- a/test/UriHelperTest.php
+++ b/test/UriHelperTest.php
@@ -6,7 +6,6 @@
namespace PhlyTest\Expressive\Mustache;
-use ArrayObject;
use Phly\Expressive\Mustache\UriHelper;
use PHPUnit_Framework_TestCase as TestCase;
use Zend\Expressive\Helper\UrlHelper; | Removed unneeded dependency from UriHelperTest |
diff --git a/tests/TestCase/View/ViewTest.php b/tests/TestCase/View/ViewTest.php
index <HASH>..<HASH> 100644
--- a/tests/TestCase/View/ViewTest.php
+++ b/tests/TestCase/View/ViewTest.php
@@ -1885,7 +1885,7 @@ TEXT;
$View->element('test_element');
}
$end = memory_get_usage();
- $this->assertLessThanOrEqual($start + 5000, $end);
+ $this->assertLessThanOrEqual($start + 15000, $end);
}
/** | PHPdbg uses a little bit more memory |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.