message stringlengths 13 484 | diff stringlengths 38 4.63k |
|---|---|
Update newsroom.py
Updated the URL for Newsroom download so it's more robust to future changes. | @@ -82,7 +82,7 @@ class Newsroom(nlp.GeneratorBasedBuilder):
VERSION = nlp.Version("1.0.0")
MANUAL_DOWNLOAD_INSTRUCTIONS = """\
- You should download the dataset from https://summari.es/download/
+ You should download the dataset from http://lil.nlp.cornell.edu/newsroom/
The webpage requires registration.
To unzip the ... |
[sync] catch attempts at deleting home folder early
this allows us to provide a better error message | @@ -2544,6 +2544,20 @@ class SyncEngine:
client = client or self.client
+ # We intercept any attempts to delete the home folder here instead of waiting
+ # for an error from the Dropbox API. This allows us to provide a better error
+ # message.
+
+ home_path = self._state.get("account", "home_path")
+
+ if event.dbx_pa... |
Support Quantization to variable number of bits
Summary: allow quantization using quant noise with variable number of bits | @@ -7,17 +7,19 @@ import torch
def emulate_int(w, bits, method, scale=None, zero_point=None):
- q = globals()[f"emulate_int{bits}_{method}"]
- return q(w, scale=scale, zero_point=zero_point)
+ q = globals()[f"emulate_int8_{method}"]
+ return q(w, scale=scale, zero_point=zero_point, bits=bits)
-def quantize(w, scale, ze... |
Document Postgres-backed instance
Summary: Includes a YAML snippet. Stacked on D1166
Test Plan: N/A.
Reviewers: #ft, alangenfeld, natekupp | @@ -18,3 +18,46 @@ Tools like the Dagster CLI or Dagit use the following behavior to select the cur
4. Use an ephemeral instance, which will hold information in memory and use a TemporaryDirectory for local artifacts
which is cleaned up on exit. This is useful for tests and is the default for direct python api invocati... |
Speed up BQM.add_variable and BQM.add_interaction
BQM.add_variable and .add_interaction used the LinearView and
QuadraticView respectively to add biases to the BQM. This was slow
relative to manipulating the underlying BQM._adj directly.
The down side is now there are two places where _adj is manipulated. | @@ -427,21 +427,22 @@ class BinaryQuadraticModel(abc.Sized, abc.Container, abc.Iterable):
if vartype is not None and vartype is not self.vartype:
if self.vartype is Vartype.SPIN and vartype is Vartype.BINARY:
# convert from binary to spin
- bias /= 2.
+ bias /= 2
self.offset += bias
elif self.vartype is Vartype.BINARY ... |
Fix ketos test progress bar regression
Fixes | @@ -773,13 +773,13 @@ def test(ctx, batch_size, model, evaluation_files, device, pad, workers,
error += c
except FileNotFoundError as e:
batches -= 1
- pred.update(total=batches)
+ progress.update(pred_task, total=batches)
logger.warning('{} {}. Skipping.'.format(e.strerror, e.filename))
except KrakenInputException as ... |
fixed tests for `format_board_bonus_challenge` step
updated `/backend/main/tests/test_transcript.json` | {
"get_solution": [
"def format_board(board):",
- " result = ' '",
- " for i in range(len(board)):",
- " result += str(i + 1)",
- " result += '\\n'",
- " for i in range(len(board)):",
- " result += str(i + 1)",
- " for char in board[i]:",
- " result += char",
- " if i != len(board) - 1:",
- " result += '\\n'",
- " retu... |
Add ansible timeout for ssh connection
And attempts of connection retries | @@ -20,6 +20,8 @@ RUN pip install ./kqueen
# Avoid Ssh issues with docker overlayfs and sockets
ENV ANSIBLE_SSH_CONTROL_PATH /dev/shm/cp%%h-%%p-%%r
+ENV ANSIBLE_SSH_RETRIES 3
+ENV ANSIBLE_TIMEOUT 25
ENV KQUEEN_KS_KUBESPRAY_PATH /code/kubespray
ENV KQUEEN_KS_ANSIBLE_CMD /usr/local/bin/ansible
ENV KQUEEN_KS_ANSIBLE_PLAYB... |
Check key in python for table join
* Check key in python for table join
fixes
* fix | @@ -1632,7 +1632,7 @@ class Table(ExprContainer):
@typecheck_method(right=table_type,
how=enumeration('inner', 'outer', 'left', 'right'))
- def join(self, right, how='inner') -> 'Table':
+ def join(self, right: 'Table', how='inner') -> 'Table':
"""Join two tables together.
Examples
@@ -1680,6 +1680,12 @@ class Table(Ex... |
typo
copy and paste issue | @@ -633,7 +633,7 @@ def compare(*args, **kw):
with this string in the message in the
:class:`AssertionError`.
- :param x_label: If provided, in the event of an :class:`AssertionError`
+ :param y_label: If provided, in the event of an :class:`AssertionError`
being raised, the object passed as the second positional
argum... |
langkit.parsers.NodeToParsersPass: switch to new-style objects
TN: | @@ -1451,7 +1451,7 @@ class Predicate(Parser):
# pretty printers for Langkit grammars.
-class NodeToParsersPass():
+class NodeToParsersPass(object):
"""
This pass computes the correspondence between AST node types and parsers.
The end goal is to have one and only one non-ambiguous rule to pretty-print
|
skip cache during tests
This object is deleted via couch API call, so the mechanism which
normally clears the cache is not called. Since tests frequently use
domain names like "test", conflicts can arise which wouldn't be an issue
with a 5 minute cache in the real world. | from decimal import Decimal
+from django.conf import settings
from django.db import models
from django.db.models.signals import post_delete, post_save
from django.dispatch import receiver
@@ -148,7 +149,7 @@ class CommtrackConfig(QuickCachedDocumentMixin, Document):
self.for_domain.clear(self.__class__, self.domain)
@c... |
bugfix: order of variables in quantified Z3 terms
This fix guarantees that variables are quantified in the right order. This
is important for queries otherwise the order of the columns in the answers
may be arbitrary.
The bug was mostly visible on Python 3 due to dictionnary implementation
details. | @@ -322,6 +322,7 @@ class Z3Context(object):
As it is used mainly for rules, the head is distinguished.
"""
variables = {} # type: Dict[str, z3.Const]
+ z3vars = []
def compile_expr(expr, translator):
"""Compiles an expression to Z3"""
@@ -331,6 +332,7 @@ class Z3Context(object):
return variables[name]
var = Z3OPT.Cons... |
Add GH code scanning with codeQL
* Create codeql-analysis.yml
* Update codeql-analysis.yml
set permissions
* Update stale.yml | @@ -4,6 +4,8 @@ on:
schedule:
- cron: "0 0 * * *"
+permissions: read-all
+
jobs:
stale:
|
Update noaa-s102.yaml
Adding bucket browser link | @@ -23,6 +23,8 @@ Resources:
ARN: arn:aws:s3:::noaa-s102-pds
Region: us-east-1
Type: S3 Bucket
+ Explore:
+ - '[Browse Bucket](https://noaa-s102-pds.s3.amazonaws.com/index.html)'
- Description: NOAA S-102 Bathymetric Surface New Object Notification
ARN: arn:aws:sns:us-east-1:123901341784:NewS102Object
Region: us-east-1... |
CompileCtx: enhance docstring a bit for symbol_literals
TN: | @@ -468,14 +468,15 @@ class CompileCtx(object):
pre-computed in each analysis context so that parsing and properties
evaluation does not need to perform symbol table lookups for them.
- Set set of such pre-computed symbols is stored in an array indexed by
- an enumeration type. This holds a mapping: symbol text -> enum... |
Turn off the rule RequireTestDocumentation in our repo
We need to do more tweaking to which rules we care about in our own
repo, but this at least gets the ball rolling and sets an example for
how to configure the rules. | @@ -15,6 +15,8 @@ tasks:
options:
path:
- cumulusci/robotframework
+ ignore:
+ - RequireTestDocumentation
robot_libdoc:
description: Generates html documentation for the Salesorce and CumulusCI libraries and resource files
class_path: cumulusci.tasks.robotframework.RobotLibDoc
|
Update _normTufoProps to normalize property names by checking/ripping off form names and trailing colons.
This allows for setTufoProps (and storm setprop operator) to accept full prop values and relative prop values when called using kwarg unpacking notation. | @@ -2207,6 +2207,14 @@ class Cortex(EventBus, DataModel, Runtime, Configable, s_ingest.IngestApi):
valu = inprops.get(name)
+ if name.startswith(form):
+ # Possibly a full prop - strip name off
+ name = name[len(form):]
+
+ if name.startswith(':'):
+ # Relative prop - strip and form
+ name = name[1:]
+
prop = form + ':... |
add missing default value for LRScheduler.step()
Summary:
see also other type errors in and
Pull Request resolved: | @@ -6,7 +6,7 @@ class _LRScheduler:
def state_dict(self) -> dict: ...
def load_state_dict(self, state_dict: dict) -> None: ...
def get_lr(self) -> float: ...
- def step(self, epoch: Optional[int]) -> None: ...
+ def step(self, epoch: Optional[int]=...) -> None: ...
class LambdaLR(_LRScheduler):
def __init__(self, optim... |
Update REQUEST-903.9003-NEXTCLOUD-EXCLUSION-RULES.conf
Using the example as put in the comments, I get errors: the ID is a duplicate and the rule isn't parsed.
I've chosen a new ID (not sure how this is normally done) and changed the configuration line to one that works for me. | # you put something like this in crs-setup.conf:
#
# SecRule REQUEST_FILENAME "@rx /(?:remote.php|index.php)/" \
-# "id:9003330,\
+# "id:9003600,\
# phase:1,\
# t:none,\
# nolog,\
# pass,\
-# tx.restricted_extensions='.bak/ .config/ .conf/'"
+# setvar:'tx.restricted_extensions=.bak/ .config/ .conf/'"
#
# Large uploads ... |
Add test for `--optimal` to `test_compare_sky`
modified: pypeit/tests/test_scripts.py | @@ -335,10 +335,15 @@ def test_compare_sky():
sky_file = os.path.join(resource_filename('pypeit', 'data/sky_spec/'),
'sky_kastb_600.fits')
- # Running in `test` mode
+ # Running in `test` mode for boxcar extraction
pargs = scripts.compare_sky.CompareSky.parse_args([spec_file, sky_file, '--test'])
scripts.compare_sky.Co... |
[commands] Lazily fetch members in discord.Member converters
This makes commands taking members mostly work transparently without
much effort from the user. | @@ -122,13 +122,49 @@ class MemberConverter(IDConverter):
.. versionchanged:: 1.5
Raise :exc:`.MemberNotFound` instead of generic :exc:`.BadArgument`
+
+ .. versionchanged:: 1.5.1
+ This converter now lazily fetches members from the gateway and HTTP APIs,
+ optionally caching the result if :attr:`.MemberCacheFlags.join... |
Update ant_env.py
Avoid falling into infinity | @@ -195,7 +195,7 @@ class AntClimbEnv(CameraRobotEnv):
alive = float(self.robot.alive_bonus(self.robot.body_rpy[0], self.robot.body_rpy[1])) # state[0] is body height above ground (z - z initial), body_rpy[1] is pitch
- done = self.nframe > 700 or alive < 0
+ done = self.nframe > 700 or alive < 0 or self.robot.body_xyz... |
horizontal scroll on translation page
ref | @@ -619,6 +619,10 @@ article {
margin: 20px 0 40px 0;
padding: 0;
position: static;
+
+ .selectbox-wrapper {
+ margin-bottom: 8px;
+ }
}
}
}
@@ -1044,6 +1048,9 @@ article {
table {
border: 1px solid #ddd;
width: 100%;
+ color: #666;
+ font-size: 12px;
+ font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', 'Consolas', 'source... |
Redirect for trailing slash, fix url decoding
* Request for `/problem/1234` turns to `/problem/1234/`
* Set path in proxy_pass instead of rewrite so URLs are not decoded
(e.g. `/problem/my%20path/file.css` no longer turns into
`/problem/my%2520path/file.css`) | @@ -39,12 +39,15 @@ server {
types { }
default_type application/octet-stream;
}
+
{% if (enable_shell_proxy|bool) -%}
+ location ~ /problem/(\d+)$ {
+ return 301 $scheme://{{ shell_hostname }}/problem/$1/;
+ }
location ~ /problem/(\d+)/?(.*) {
set $port $1;
set $path $2;
- rewrite ^.*$ /$path break;
- proxy_pass http:/... |
Update android_anubis.txt
Fixing typo and alphabetic order. | @@ -2531,15 +2531,14 @@ http://52.247.252.64
/inj/a8.phpy
/inj/a9.phpy
/inj/fafa.php
-/inj/in_axis.php
-/inj/fafa.php
/inj/grab1.php
/inj/grab2.php
/inj/grab3.php
/inj/grab4.php
/inj/grab5.php
+/inj/in_axis.php
/inj/xorx.php
-/inj/zebapy.php
+/inj/zebpay.php
/injclientup/fafa.php
/injectfull/
/kokojamba1212/
|
Add function to copy TIF metadata between images
And remove merge markers | @@ -99,6 +99,27 @@ def classify_fpaths(prefix, fpaths, id_to_files, file_type):
elif '-A1BS-' in fpath:
id_to_files[prefix]['swir'][file_type] = fpath
+
+def copy_tif_info(in_fpath, out_fpath):
+ """
+ Copy the TIF metadata from in_fpath and save it to the image at out_fpath.
+ :param in_fpath: Filepath for input image... |
Use integer format fo text trees if positions are integers
As we do for the SVG format. This is useful now that msprime.sim_ancestry defaults to integer breakpoints. | @@ -1490,17 +1490,17 @@ class TextTreeSequence:
self.ts = ts
time_label_format = "{:.2f}" if time_label_format is None else time_label_format
- position_label_format = (
- "{:.2f}" if position_label_format is None else position_label_format
- )
+ tick_labels = ts.breakpoints(as_array=True)
+ if position_label_format is... |
always use local influxdb for monitoring
HG--
branch : feature/microservices | ## Multiple URLs from which to read InfluxDB-formatted JSON
urls = [
- "http://{{influx_host}}:{{ influxdb_port }}/debug/vars"
+ "http://127.0.0.1:{{ influxdb_port }}/debug/vars"
]
|
Allows use of inline powershell for cmd.script args
Fixes | @@ -344,7 +344,7 @@ def _run(cmd,
# The last item in the list [-1] is the current method.
# The third item[2] in each tuple is the name of that method.
if stack[-2][2] == 'script':
- cmd = 'Powershell -NonInteractive -NoProfile -ExecutionPolicy Bypass -File ' + cmd
+ cmd = 'Powershell -NonInteractive -NoProfile -Execut... |
Update asr.sh
Make calculate_rtf.py work with espnet2 | @@ -1242,7 +1242,8 @@ if ! "${skip_eval}"; then
# 2. Submit decoding jobs
log "Decoding started... log: '${_logdir}/asr_inference.*.log'"
- # shellcheck disable=SC2046,SC2086
+ rm -f "${_logdir}/*.log"
+ # shellcheck disable=SC2086
${_cmd} --gpu "${_ngpu}" JOB=1:"${_nj}" "${_logdir}"/asr_inference.JOB.log \
${python} -... |
lnworker: also check expiring_htlcs in ChannelState.SHUTDOWN
otherwise the remote could intentionally send "shutdown" during an attack | @@ -971,7 +971,8 @@ class LNWallet(LNWorker):
util.trigger_callback('channel', self.wallet, chan)
return
- if chan.get_state() == ChannelState.OPEN and chan.should_be_closed_due_to_expiring_htlcs(self.network.get_local_height()):
+ if (chan.get_state() in (ChannelState.OPEN, ChannelState.SHUTDOWN)
+ and chan.should_be_... |
Updated "DE" zones.json
most of the sources are updated with the source from Fraunhofer ISE (https://energy-charts.info/charts/installed_power/chart.htm?l=de&c=DE&year=2020&interval=year&stacking=grouped)
The source is already mentioned in the DATA_SOURCES.md file.
And I'm already on the list of contributors :)
geother... | ]
],
"capacity": {
- "biomass": 8210,
+ "biomass": 8240,
"coal": 43490,
"gas": 29930,
- "geothermal": 42,
- "hydro": 4780,
+ "geothermal": 47,
+ "hydro": 4790,
"hydro storage": 9810,
"nuclear": 8114,
"oil": 4360,
- "solar": 51990,
+ "solar": 53580,
"unknown": 3700,
- "wind": 61880
+ "wind": 62380
},
"contributors": [
"... |
Code Style Updates
Updated the to conform with the line ends expected by the code style in
tests rather than PyCharm. | @@ -589,9 +589,8 @@ def dao_fetch_monthly_historical_usage_by_template_for_service(service_id, year)
for today_result in today_results:
add_to_stats = True
for stat in stats:
- if today_result.template_id == stat.template_id and \
- today_result.month == stat.month and \
- today_result.year == stat.year:
+ if today_res... |
Remove title
The title takes too much room on mobile screens | 
-# Jupyter Notebooks as Markdown Documents, Julia, Python or R Scripts
-
[](https://travis-ci.com/mwouts/jupytext)
[](https://... |
Importer: Manage KHR_materials_unit for 2.79
Using Light Path "Is camera Ray" | @@ -53,6 +53,7 @@ class BlenderPbr():
elif nodetype == "unlit":
if bpy.app.version < (2, 80, 0):
main_node = node_tree.nodes.new('ShaderNodeEmission')
+ main_node.location = 750, -300
else:
main_node = node_tree.nodes.new('ShaderNodeBackground')
main_node.location = 0, 0
@@ -290,4 +291,17 @@ class BlenderPbr():
node_tr... |
Update task.py
fixed a simple bug | @@ -57,7 +57,7 @@ class ArithmeticTask(task.Task):
b = np.random.randint(10**difficulty)
correct = False
problem = str(a) + ' + ' + str(b) + ' = '
- result = text_generation_fn(problem)
+ response = text_generation_fn(problem)
# Regex post-processing to capture expected output type.
result = re.findall(r'[-+]?\d+', res... |
Update test_compute_flow.py - properly label what's happening
Note: this text is generated here: So they need to be in line. I just updated that file. | @@ -300,7 +300,7 @@ def run_compute_test(
log_file = ocean_instance.compute.compute_job_result_logs(
dataset_and_userdata.asset, service, job_id, consumer_wallet, "algorithmLog"
)
- assert "Applying Gaussian processing." in str(log_file[0])
+ assert "Building Gaussian Process Regressor (GPR) model" in str(log_file[0])
... |
Role-spec NovaComputeStartupDelay
Make it role-specific for other compute roles, like HCI,
to work with it
Follow-up | @@ -100,6 +100,8 @@ parameters:
type: number
constraints:
- range: { min: 0, max: 600 }
+ tags:
+ - role_specific
EnableInstanceHA:
default: false
description: Whether to enable an Instance Ha configuration or not.
@@ -859,8 +861,13 @@ conditions:
not: {equals: [{get_param: AuthCloudName}, ""]}
compute_startup_delay:
a... |
Reduce the number of days an issue is stale by 25
As we ease into a more reasonable `daysUntilStale` value, this
updates the time an issue will be marked as stale to about 3 years
and 4 months. | # Probot Stale configuration file
# Number of days of inactivity before an issue becomes stale
-# 1250 is approximately 3 years and 5 months
-daysUntilStale: 1250
+# 1225 is approximately 3 years and 4 months
+daysUntilStale: 1225
# Number of days of inactivity before a stale issue is closed
daysUntilClose: 7
|
Simplify unnecessary nesting, casting and constant values in f-strings(simplify-fstring-formatting)
Replace unused for index with underscore(for-index-underscore) | @@ -114,7 +114,7 @@ class Optimizer(ABC):
length = int(self.population_size / self.cpu_cores)
progressbar = Progressbar(length)
- for i in range(length):
+ for _ in range(length):
people = []
with Manager() as manager:
dna_bucket = manager.list([])
@@ -138,7 +138,7 @@ class Optimizer(ABC):
for w in workers:
w.join()
if... |
FieldAccessExpr: switch to BasicExpr's requires_incref feature
TN: | @@ -2818,17 +2818,11 @@ class FieldAccessExpr(BasicExpr):
super(FieldAccessExpr, self).__init__(
'Fld', '{}.{}', result_type,
[NullCheckExpr(prefix_expr, result_var_name='Pfx'), field_name],
+ requires_incref=do_explicit_incref,
abstract_expr=abstract_expr,
)
self.prefix_expr = prefix_expr
self.field_name = field_name
... |
Change the downgrade of the execution_status enum
* Unfortunately postgres doesn't directly support removing enum values,
so we create a new type with the correct enum values and swap out the old one
* The previous approch required access to the pg_enum table which our user
(cloudify) doesn't have | @@ -7,6 +7,7 @@ Create Date: 2018-04-03 14:31:11.832546
"""
from alembic import op
import sqlalchemy as sa
+from sqlalchemy.dialects import postgresql
from manager_rest.storage.models_base import UTCDateTime
# revision identifiers, used by Alembic.
@@ -65,14 +66,30 @@ def downgrade():
set status='failed'
where status='... |
Update Arduino_Code.ino
Changing the while to if on the main loop. Since it's already on the main loop there is no need for a while. The while implementation uses a little bit more lines of code (assembly). | @@ -86,7 +86,7 @@ String get_DUCOID() {
// Infinite loop
void loop() {
// Wait for serial data
- while (Serial.available() > 0) {
+ if (Serial.available() > 0) {
memset(job, 0, job_maxsize);
// Read last block hash
lastblockhash = Serial.readStringUntil(',');
|
use subtraction instead of or
If we use or, we will get minions that are in the ret list, but not connected
to the master in cases where the syndic is used. | @@ -738,7 +738,7 @@ class LocalClient(object):
ret[mid] = (data if full_return
else data.get('ret', {}))
- for failed in list(set(pub_data['minions']) ^ set(ret)):
+ for failed in list(set(pub_data['minions']) - set(ret)):
ret[failed] = False
return ret
finally:
|
Update readsettings.py
switch exception order | @@ -939,10 +939,10 @@ class ReadSettings:
fp = open(cfgfile, "w")
config.write(fp)
fp.close()
- except IOError:
- self.log.exception("Error writing to autoProcess.ini.")
except PermissionError:
self.log.exception("Error writing to autoProcess.ini due to permissions.")
+ except IOError:
+ self.log.exception("Error writi... |
Fix more Python 3 issues in run_sk_stress_test
I only discovered these when running with Python 3.9 (they passed with Python 3.8). | @@ -326,9 +326,9 @@ class StressTesterRunner(object):
return not self.compat_runner_failed
with open(results_path, 'r') as results_file:
- results = json.load(results_file, encoding='utf-8')
+ results = json.load(results_file)
with open(xfails_path, 'r') as xfails_file:
- xfails = json.load(xfails_file, encoding='utf-8... |
fix: Avoid ConfigParser squashing
When adding values to a ConfigParser, everything gets squashed into a
string. Avoid this by preserving the Python object as a whole. | @@ -87,8 +87,10 @@ def extract_formats(config_handle):
return formats
-def load_dynamic_config(configurations, config_dir=getcwd()):
+def load_dynamic_config(config_dir=getcwd()):
"""Load and parse dynamic config"""
+ dynamic_configurations = {}
+
# Create full path of config
config_file = '{path}/config.py'.format(pat... |
Add __gt__ and __lt__ overrides for TagBase.
Fixes an incompatibility with django-modelcluster and, by extension, Wagtail.
Currently untested, just committing the change to 'save' it. | @@ -27,6 +27,12 @@ class TagBase(models.Model):
def __str__(self):
return self.name
+ def __gt__(self, other):
+ return self.name > other.name
+
+ def __lt__(self, other):
+ return self.name < other.name
+
class Meta:
abstract = True
|
fix silent failure on Windows builds
Summary:
Closes
Remove backticks that are being interpreted by the shell. Add -e option to bash script to avoid future such failures
Pull Request resolved: | -#!/bin/bash
+#!/bin/bash -e
COMPACT_JOB_NAME=pytorch-win-ws2016-cuda9-cudnn7-py3-test
source "$(dirname "${BASH_SOURCE[0]}")/common.sh"
@@ -75,7 +75,7 @@ set PYTHONPATH=%TMP_DIR_WIN%\\build;%PYTHONPATH%
if NOT "%BUILD_ENVIRONMENT%"=="" (
cd %TMP_DIR_WIN%\\build
python %TMP_DIR_WIN%\\ci_scripts\\download_image.py %TMP_... |
Changing upgrade database engine button label
The button was not showing the current version on databaseinfra.engine_patch | <a href="{{ database.get_upgrade_retry_url }}" class="btn btn-warning" title="Retry upgrade" onclick="return confirm('Are you sure?')">Retry upgrade {{ database.infra.engine_name }} {{ database.infra.plan.engine.version}} to {{ database.infra.plan.engine_equivalent_plan.engine.version }}</a>
<p><a href="{% url 'admin:m... |
updater: remove magic number
Remove the magic number, a whence value of 2 for file.seek(), and instead
use the io.SEEK_END constant from the io module. | @@ -128,6 +128,7 @@ import time
import fnmatch
import copy
import warnings
+import io
import tuf
import tuf.download
@@ -1245,9 +1246,7 @@ class Updater(object):
None.
"""
- # seek to the end of the file; that is offset 0 from the end of the file,
- # represented by a whence value of 2
- file_object.seek(0, 2)
+ file_o... |
remove a "is"
When I translated in Chinese, I found a needless "is" | @@ -657,7 +657,7 @@ SitemapSpider
.. attribute:: sitemap_follow
- A list of regexes of sitemap that should be followed. This is is only
+ A list of regexes of sitemap that should be followed. This is only
for sites that use `Sitemap index files`_ that point to other sitemap
files.
|
Prepare 2.11.0rc6.
[ci skip-rust] | # 2.11.x Release Series
+## 2.11.0rc6 (Apr 30, 2022)
+
+### User API Changes
+
+* Upgrade Pex to 2.1.84. (Cherry-picks of #15200, #15281 & #15288) ([#15289](https://github.com/pantsbuild/pants/pull/15289))
+
+### Bug fixes
+
+* Memoize equality for `CoarsenedTarget(s)` to avoid exponential runtime in `check`. (Cherry-p... |
Prepare 2.6.1rc0.
[ci skip-rust] | # 2.6.x Stable Releases
+## 2.6.1rc0 (Aug 06, 2021)
+
+### New Features
+
+* Add `skip_tests` field to `python_tests` to facilitate incremental migrations (Cherry-pick of #12510) ([#12511](https://github.com/pantsbuild/pants/pull/12511))
+
+* Adds support for Poetry group dependencies (Cherry-pick of #12492) ([#12497](... |
improve plugin name
to differ from the new 'Versions Loaded in Scene' plugin | @@ -10,7 +10,7 @@ class CollectSceneVersion(pyblish.api.ContextPlugin):
"""
order = pyblish.api.CollectorOrder
- label = 'Collect Version'
+ label = 'Collect Scene Version'
hosts = [
"aftereffects",
"blender",
|
options: add link to help page
Ref | {% set active_page = 'options' %}
{% block content %}
- <h2>{{ _('fava: options') }}</h2>
+ <h2>{{ _('Fava options') }} <a href="{{ url_for('help_page', page_slug='options') }}">({{ _('help') }})</a></h2>
<table class="options sortable">
<thead>
<tr>
{% endfor %}
</tbody>
</table>
- <h2>{{ _('beancount: options') }}</h... |
Fix regexes in yaml-validate.py with python 3.8
In Python 3.8, the re module no longer escapes various
characters (such as ; or /), as opposed to python 3.6.
Update various regexes in yaml-validate.py to match
patterns as expected for all python versions.
Closes-Bug: | @@ -1034,7 +1034,7 @@ def validate_service_hiera_interpol(f, tpl):
# name. The only exception is allow anything under
# str_replace['params'] ('str_replace;params' in the str notation).
# We need to escape because of '$' char may be in templated params.
- query = re.compile(r'\\;str(\\)?_replace\\;params\\;\S*?net',
+ ... |
Lock graph_task before writing leaf_streams.
Summary:
Pull Request resolved:
Fixes
Test Plan: Imported from OSS | @@ -562,6 +562,7 @@ void Engine::evaluate_function(
// Records leaf stream (if applicable)
// See note "Streaming backwards"
if (opt_parent_stream) {
+ std::lock_guard<std::mutex> lock(graph_task->mutex_);
graph_task->leaf_streams.emplace(*opt_parent_stream);
}
return;
|
Use datetime type for timestamps columns
This aligns the created_at and updated_at columns to have the same column type as deleted_at | @@ -337,9 +337,9 @@ class Blueprint:
Returns:
self
"""
- self.timestamp("created_at", nullable=True, now=True)
+ self.datetime("created_at", nullable=True, now=True)
- self.timestamp("updated_at", nullable=True, now=True)
+ self.datetime("updated_at", nullable=True, now=True)
return self
|
always add nginx headers
HG--
branch : feature/microservices | @@ -116,8 +116,8 @@ server {
ssl_certificate_key {{ nginx_ssl_key_path }};
add_header Strict-Transport-Security "max-age=63072000; includeSubDomains";
add_header X-Content-Type-Options nosniff;
- add_header X-Backend-Server $upstream_addr;
- add_header X-Front-Server $hostname;
+ add_header X-Backend-Server $upstream_a... |
`prettytable`: Fix stubtest errors
Fixes A partial revert of | from _typeshed import Incomplete
from html.parser import HTMLParser
from typing import Any
-from typing_extensions import Literal, TypedDict
FRAME: int
ALL: int
@@ -17,8 +16,6 @@ SINGLE_BORDER: int
DOUBLE_BORDER: int
BASE_ALIGN_VALUE: str
-class _EmptyDictionary(TypedDict): ...
-
class PrettyTable:
encoding: Any
def __... |
Cleaning the exceptions trackback in linux_lvm.py
pvcreate and pvremove from linux_lvm execution module raises a
trackback when they should fail graciously.
Initial work to remove the trackbacks and substitute then with
clean failures. | @@ -10,7 +10,6 @@ import os.path
# Import salt libs
import salt.utils.path
-from salt.exceptions import CommandExecutionError
from salt.ext import six
# Set up logger
@@ -251,13 +250,11 @@ def pvcreate(devices, override=True, force=True, **kwargs):
for device in devices:
if not os.path.exists(device):
- raise CommandEx... |
Add key_filename parameter to SSHChannel
This forwards along the ssh key_filename to Paramiko, allowing clients to pass along their keyfile if they don't want to use user name password or rely on ~/.ssh being in its usual spot. | @@ -26,7 +26,7 @@ class SSHChannel(Channel, RepresentationMixin):
'''
- def __init__(self, hostname, username=None, password=None, script_dir=None, envs=None, gssapi_auth=False, skip_auth=False, port=22):
+ def __init__(self, hostname, username=None, password=None, script_dir=None, envs=None, gssapi_auth=False, skip_au... |
BUG: md5 tests failing on bitbucket pipelines, skip on linux for now
[CHANGED] this is due to platform specific handling of line-endings is my bet.
A problem with scitrack (I'm the dev on that project), not cogent3. | @@ -103,6 +103,9 @@ class DataStoreBaseTests:
got = {l: s for l, s in MinimalFastaParser(data)}
self.assertEqual(got, expect)
+ # todo not really bnroken, but something to do with line-feeds I
+ # suspect. This means scitrack needs a more platform robust approach...
+ @unittest.skipIf(sys.platform.lower() != 'darwin', ... |
Update test_fetchers_facade_data.py
Fix box definitions to find data from all sources and modes | @@ -159,7 +159,7 @@ class Test_Facade:
dsh = fetcher.plot(ptype='qc_altimetry', embed='slide')
assert isinstance(dsh(0), IPython.display.Image)
- # Test invalid plot
+ # Test invalid plot name
with pytest.raises(ValueError):
fetcher.plot(ptype='invalid_cat', with_seaborn=ws)
@@ -182,8 +182,8 @@ class Test_DataFetching:... |
Request a test experiment
Request an experiment to test the recent changes. | # Please add new experiment requests towards the top of this file.
#
+
+- experiment: 2023-01-27-test-request
+ description: "Test if the new system can run experiments by online request."
+ fuzzers:
+ - aflplusplus
+ - centipede
+ - honggfuzz
+ - libfuzzer
+
- experiment: 2023-01-25-libafl
description: "libafl grammar... |
fix bug in output format for pyav
* fix bug in output format for pyav
* add read from memory with constructor overload
* Revert "add read from memory with constructor overload"
This reverts commit
* run ufmt | @@ -273,15 +273,17 @@ def read_video(
raise RuntimeError(f"File not found: {filename}")
if get_video_backend() != "pyav":
- return _video_opt._read_video(filename, start_pts, end_pts, pts_unit)
-
+ vframes, aframes, info = _video_opt._read_video(filename, start_pts, end_pts, pts_unit)
+ else:
_check_av_available()
if e... |
[DesignRuleCheck] Less is more for M* layers
1) Use Scanline.dIndex instead of layer['direction']
2) Report errors in array instead of logging
(Logging needs to be implemented globally) | -import logging
-
class DesignRuleCheck():
def __init__(self, canvas):
self.canvas = canvas
+ self.errors = []
+
+ @property
+ def num_errors(self):
+ return len(self.errors)
def run(self):
'''
@@ -12,7 +15,6 @@ def run(self):
(aka removeDuplicates has been run)
'''
- self.num_errors = 0
for (layer, vv) in self.canvas.... |
use WorkflowsClient.show_invocation
in InvocationsClient.wait_for_invocations.
It might be deprecated in future versions
but for now it is supported by all versions of Galaxy | @@ -262,16 +262,12 @@ class InvocationClient(Client):
after this timeout, an InvocationNotScheduledException
is raised.
"""
- galaxy_version = os.environ.get('GALAXY_VERSION', None)
- is_newer = galaxy_version == 'dev' or galaxy_version >= 'release_19.09'
- show_invocation = self.gi.invocations.show_invocation if is_ne... |
[README] Merge Pull Request Correct typo
Replaced 'interpretor' with 'interpreter'. | @@ -179,4 +179,4 @@ Use py2app on OS X and pyinstaller on Windows. For reference setup.py files, loo
# VirtualEnv issues
-Under virtualenv on OS X, a window created with pywebview has issues with keyboard focus and Cmd+Tab. This behaviour is caused by the Python interpretor that comes with virtualenv. To solve this iss... |
Doc update for make_image_classifier regarding pip packages:
now available from tf-hub-nightly (starting at 0.6.0.dev201908230004),
recomend tf-nightly-[gpu-]2.0-preview, due to performance issues
with tensorflow-gpu=2.0.0.beta1. | @@ -17,24 +17,28 @@ which demonstrates the key techniques of this program in your browser.
## Installation
-This tool requires TensorFlow 2.0 (or its public beta1) and
-tensorflow_hub 0.6.0 or better (yet to be released as of August 2019).
+This tool requires pre-release versions of the tensorflow and tensorflow_hub
+l... |
Update requirement from Py3.5+ to Py3.6+
Since we make use of f-strings. | @@ -41,7 +41,7 @@ Documentation: <https://openml.github.io/automlbenchmark/>
## Installation
### Pre-requisites
To run the benchmarks, you will need:
-* Python 3.5+.
+* Python 3.6+.
* PIP3: ensure you have a recent version. If necessary, upgrade your pip using `pip3 install --upgrade pip`.
* The Python libraries listed... |
swarming: downgrade ensure_active_slice errors to warnings
TEST=None | @@ -932,7 +932,8 @@ def _ensure_active_slice(request, try_number, task_slice_index):
to_runs = [r for r in to_runs if r.queue_number]
if to_runs:
if len(to_runs) != 1:
- logging.error('_ensure_active_slice: %s != 1 TaskToRuns', len(to_runs))
+ logging.warning('_ensure_active_slice: %s != 1 TaskToRuns',
+ len(to_runs))
... |
Fix a typo in the simulated OLT adapter that was preventing it from
being enabled. | @@ -336,7 +336,7 @@ class SimulatedOltAdapter(object):
yield asleep(0.05)
try:
log.info("Setting p")
- p = PmsConfig(
+ p = PmConfigs(
default_freq=150,
grouped=False,
freq_override=False)
|
pin cryptography package
pin cryptography package | altair>=4.0.0,<5
Click>=7.1.2
colorama>=0.4.3
-cryptography>=3.2
+cryptography>=3.2,<37.0.0
importlib-metadata>=1.7.0 # (included in Python 3.8 by default.)
Ipython>=7.16.3
jinja2>=2.10,<3.1.0 # contextfilter has been renamed
|
Move import fcntl inside if statement.
Fixed | @@ -20,7 +20,6 @@ import vaex.dataset
import vaex.file
from vaex.expression import Expression
import struct
-import fcntl
logger = logging.getLogger("vaex.file")
@@ -45,6 +44,7 @@ if no_mmap:
from cachetools import LRUCache
import threading
+ import fcntl
GB = 1024**3
def getsizeof(ar):
return ar.nbytes
|
added TX quaternary hospitalization
Clicking on the "Hospitals - Statewide" tab of the "other link". | @@ -510,6 +510,19 @@ quaternary:
page.done();
message: click button for PR recoveries ("Convalecientes")
+ TX:
+ renderSettings:
+ viewport:
+ width: 2000
+ overseerScript: >
+ page.manualWait();
+ await page.waitForDelay(20000);
+ await page.evaluate(() => { document.evaluate("//div[text()='Hospitals - Statewide']", d... |
Mariner: skip serial_console_enabled test
The issue with this test in 1.0 has been closed as 'wont fix'
Serial console still works, just the message isn't always logged. | @@ -753,6 +753,11 @@ class AzureImageStandard(TestSuite):
CpuArchitecture.X64: "ttyS0",
CpuArchitecture.ARM64: "ttyAMA0",
}
+ if isinstance(node.os, CBLMariner):
+ if node.os.information.version < "2.0.0":
+ raise SkippedException(
+ "CBLMariner 1.0 has a known 'wont fix' issue with this test"
+ )
lscpu = node.tools[Ls... |
[FIX] Enable additional edit summary for syntax correction
set the right edit summary
either the summary that the bot corrects the syntax of a <references /> tag
or the edit summary that the bot adds the <references /> tag
Also improve doc. | @@ -498,7 +498,6 @@ class NoReferencesBot(Bot):
self.generator = pagegenerators.PreloadingGenerator(generator)
self.site = pywikibot.Site()
- self.comment = i18n.twtranslate(self.site, 'noreferences-add-tag')
self.refR = _ref_regex
self.referencesR = _references_regex
@@ -544,11 +543,17 @@ class NoReferencesBot(Bot):
A... |
Added a few unit tests
Added a couple unit tests related to cmd2.Cmd.default_to_shell
Added a unit test related to cmd2.Cmd._surround_ansi_escapes() | @@ -699,7 +699,6 @@ class HookFailureApp(cmd2.Cmd):
"""Simulate precmd hook failure."""
return True, statement
-
@pytest.fixture
def hook_failure():
app = HookFailureApp()
@@ -714,3 +713,50 @@ def test_precmd_hook_success(base_app):
def test_precmd_hook_failure(hook_failure):
out = hook_failure.onecmd_plus_hooks('help'... |
Fixes list_lgst_circuits function so works when prepStrs[0] has empty line labels.
Automatically sets the default ('*',) line labels when prepStrs[0] has None
or empty line labels (can happen using old-style circuits). | @@ -471,6 +471,7 @@ def list_lgst_circuits(prepStrs, effectStrs, opLabelSrc):
else: opLabels = list(map(tolabel, opLabelSrc))
line_labels = prepStrs[0].line_labels if len(prepStrs) > 0 else 'auto'
+ if line_labels is None or len(line_labels) == 0: line_labels = ('*',)
singleOps = [_cir.Circuit((gl,), line_labels=line_l... |
Automatically update any measures on deploy
Closes | @@ -168,6 +168,33 @@ def run_migrations():
warn("Refusing to run migrations in staging environment")
+@task
+def build_measures(environment=None, measures=None):
+ env.app = environments[environment]
+ env.environment = environment
+ env.path = "/webapps/%s" % env.app
+
+ with cd(env.path):
+ with prefix('source .venv/... |
Fix - do not trigger during automatic testing
Skip if automatic testing and no batch file. Eventually we might want to automatically test webpublisher functionality too. | @@ -38,10 +38,15 @@ class CollectColorCodedInstances(pyblish.api.ContextPlugin):
def process(self, context):
self.log.info("CollectColorCodedInstances")
- self.log.debug("mapping:: {}".format(self.color_code_mapping))
+ batch_dir = os.environ.get("OPENPYPE_PUBLISH_DATA")
+ if (os.environ.get("IS_TEST") and
+ (not batch... |
[runtime_env] Fix failing `wheel_urls` release test
This PR updates the release tests wheel_urls to make it compatible with the internal API change in PR Previously the release test was breaking with
File "/home/ray/anaconda3/lib/python3.7/site-packages/ray/_private/utils.py", line 1266, in get_wheel_filename
assert py... | @@ -21,6 +21,7 @@ import time
import requests
import pprint
+import ray._private.runtime_env.constants as ray_constants
from ray._private.utils import get_master_wheel_url, get_release_wheel_url
@@ -40,7 +41,7 @@ if __name__ == "__main__":
retry = set()
for sys_platform in ["darwin", "linux", "win32"]:
- for py_version... |
templates: Use help link widget in invite user modal.
Updates the help center link in the invite user modal to use the
help_link_widget. | </div>
<div class="input-group">
<label for="invite_as">{{t "User(s) join as" }}
- <a href="/help/roles-and-permissions" target="_blank" rel="noopener noreferrer">
- <i class="fa fa-question-circle-o" aria-hidden="true"></i>
- </a>
+ {{> help_link_widget link="/help/roles-and-permissions" }}
</label>
<div>
<select id="... |
Add --extend option to cci project init to easily configure extensions
of other CumulusCI Github repositories | @@ -317,8 +317,9 @@ cli.add_command(service)
@click.command(name='init',
help="Initialize a new project for use with the cumulusci toolbelt",
)
+@click.option('--extend', help="If set to the url of another Github repository configured for CumulusCI, creates this project as an extension which depends on the other Github... |
Handle null Genotypes
resolves | @@ -11,8 +11,11 @@ import scala.collection.mutable
object GenotypeSuite {
def readWriteEqual(nAlleles: Int, g: Genotype): Boolean = {
- val isLinearScale = g._isLinearScale
- val gb = new GenotypeBuilder(nAlleles, isLinearScale)
+ val gb = if (g == null) {
+ new GenotypeBuilder(nAlleles, false)
+ } else {
+ new Genotyp... |
fix: update failing test
with the new thread-safety, we must check the
individual values of `_pending_calls` | @@ -38,9 +38,9 @@ def test_flush_mid_execution(accounts, tester):
with brownie.multicall:
tester.getTuple(addr)
- assert len(brownie.multicall._pending_calls) == 1
+ assert len([x for v in brownie.multicall._pending_calls.values() for x in v]) == 1
brownie.multicall.flush()
- assert len(brownie.multicall._pending_calls... |
Upnext is incompatible with watched status sync
It needs many changes to make it compatible, it will be done in the future | @@ -93,6 +93,14 @@ def play(videoid):
event_data = _get_event_data(videoid)
event_data['videoid'] = videoid.to_dict()
event_data['is_played_by_library'] = g.IS_SKIN_CALL
+ # Todo: UpNext addon is incompatible with netflix watched status sync feature
+ # Problems:
+ # - Need to modify the cache (to update the watched st... |
Svg elements copy preserves dims
width and height were dropped during a copy. | @@ -5996,6 +5996,8 @@ class SVGText(GraphicObject, Transformable):
self.text = s.text
self.x = s.x
self.y = s.y
+ self.width = s.width
+ self.height = s.height
self.dx = s.dx
self.dy = s.dy
self.anchor = s.anchor
@@ -6096,8 +6098,8 @@ class SVGText(GraphicObject, Transformable):
width = self.width
height = self.height
... |
readme MR update for ssdlite
Reviewers: mark.kurtz, jfinks, tuan, kevinaer, dhuang
Subscribers: #core | @@ -15,7 +15,9 @@ neuralmagicML-python
scripts - Functional scripts for working with the Python API
onnx - Functional scripts for working with ONNX models
pytorch - Functional scripts for working with PyTorch models
+ server - Scripts to run the Sparsify server
tensorflow - Functional scripts for working with TensorFlo... |
Fixes a bug in Estimate serialization.
Resets to None several non-serialized elements that otherwise wouldn't
be present in the object, causing errors it they were accessed. | @@ -875,6 +875,10 @@ class Estimate(object):
state_dict['models'] = state_dict['gatesets']
del state_dict['gatesets']
+ # reset MDC objective function and store objects
+ state_dict['_final_mdc_store'] = None
+ state_dict['_final_objfn'] = None
+
self.__dict__.update(state_dict)
for crf in self.confidence_region_factor... |
cast int
Just realized the round was rounding to a float and wouldn't work
I guess they changed that on python3 | @@ -830,7 +830,7 @@ def _ecg_findpeaks_rodrigues(signal, sampling_rate=1000):
- Sadhukhan, D., & Mitra, M. (2012). R-peak detection algorithm for ECG using double difference and RR interval processing. Procedia Technology, 4, 873-877.
"""
- N = np.round(3 * sampling_rate/128)
+ N = int(np.round(3 * sampling_rate/128))
... |
Update 15-schema_update_17.sql
Added `IF NOT EXISTS` in script where I found note from carter. | @@ -3,8 +3,8 @@ ALTER TABLE "augur_data"."repo"
ALTER COLUMN "forked_from" TYPE varchar USING "forked_from"::varchar;
ALTER TABLE "augur_data"."repo"
- ADD COLUMN "repo_archived" int4,
- ADD COLUMN "repo_archived_date_collected" timestamptz(0),
+ ADD COLUMN IF NOT EXISTS "repo_archived" int4,
+ ADD COLUMN IF NOT EXISTS... |
docs: CONTRIBUTING: Fix placement of -e flag
Fixes: | @@ -123,7 +123,7 @@ this we use the `--prefix=~/.local` flag.
```console
$ git clone https://github.com/intel/dffml
$ cd dffml
-$ python3.7 -m pip install -e --prefix=~/.local .[dev]
+$ python3.7 -m pip install --prefix=~/.local -e .[dev]
```
> `[dev]` tells `pip` to install the dependencies you'll need to do developme... |
add check to tests
This ensures that not only the variables are in the list, but they
are the only variables in that list | @@ -73,12 +73,14 @@ def test_dependence_map():
assert x in dependence_map.buckets[0].variables
assert y in dependence_map.buckets[0].variables
assert z in dependence_map.buckets[0].variables
+ assert len(set(dependence_map.buckets[0].variables)) == 3
assert conditions[0] in dependence_map.buckets[0].conditions
assert c... |
Upgrade to Mesos 1.0.1
This contains important bugfixes, especially to in which
the scheduler can crash when a lot of tasks are updated at once. | @@ -28,7 +28,7 @@ dependencies = ' '.join(['libffi-dev', # For client side encryption for 'azure'
'wget',
'curl',
'openssh-server',
- 'mesos=1.0.0-2.0.89.ubuntu1404',
+ 'mesos=1.0.1-2.0.93.ubuntu1404',
'rsync',
'screen'])
|
Fix sorting of authors/speakers in widget
Which was broken for n > 9. | * along with Indico; if not, see <http://www.gnu.org/licenses/>.
*/
-/* global showFormErrors:false */
+/* global showFormErrors:false strnatcmp:false */
(function(global) {
'use strict';
$coauthorList.empty();
$otherList.empty();
- var sortedPeople = _.sortBy(people, function(person) {
- return [person.displayOrder, p... |
Update wildcards.py
Calling out that some shells require quotes around wildcarded expressions. | @@ -30,6 +30,10 @@ _DETAILED_HELP_TEXT = ("""
will copy all objects that start with gs://bucket/data/abc followed by any
number of characters within that subdirectory.
+ Note: Some shells require that wildcarded expressions be surrounded with
+ single quotes (on Linux) or double quotes (on Windows). For example:
+
+ gs... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.