message
stringlengths
13
484
diff
stringlengths
38
4.63k
Fix mujoco_py error in Dockerfile.ci The Dockerfile.ci build broke because mujoco_py could not find the LD_LIBRARY_PATH variable with mjpro150/bin in it. This change exports LD_LIBRARY_PATH manually for the mujoco_py build so avoid the error.
@@ -96,7 +96,7 @@ RUN ["/bin/bash", "-c", "source activate garage && pip uninstall -y Box2D Box2D- # THAT WE DON'T PUBLISH THE KEY ARG MJKEY RUN echo "${MJKEY}" > /root/.mujoco/mjkey.txt -RUN ["/bin/bash", "-c", "source activate garage && python -c 'import mujoco_py'"] +RUN ["/bin/bash", "-c", "export LD_LIBRARY_PATH=$...
Mock a ConnectionState object to fix wait=True errors in webhooks. Fixes
@@ -100,10 +100,6 @@ class WebhookAdapter: """ raise NotImplementedError() - def store_user(self, data): - # mocks a ConnectionState for appropriate use for Message - return BaseUser(state=self.webhook._state, data=data) - async def _wrap_coroutine_and_cleanup(self, coro, cleanup): try: return await coro @@ -301,6 +297...
Harmony to Deadline - fix if backslash is used in path Settings '64\bin' was mangled to '6in'
@@ -26,7 +26,7 @@ class HarmonyPrelaunchHook(PreLaunchHook): ( "import avalon.harmony;" "avalon.harmony.launch(\"{}\")" - ).format(harmony_executable) + ).format(harmony_executable.replace("\\", "/")) ] # Append as whole list as these areguments should not be separated
makefile: Ensure wheel is installed when setting up virtual env. Add "$(PYTHON) -m pip install wheel".
@@ -47,4 +47,4 @@ venv: $(ZT_VENV)/bin/activate $(ZT_VENV)/bin/activate: setup.py @echo "=== Installing development environment ===" test -d $(ZT_VENV) || $(BASEPYTHON) -m venv $(ZT_VENV) - $(PYTHON) -m pip install -U pip && $(PYTHON) -m pip install -e .[dev] && touch $(ZT_VENV)/bin/activate + $(PYTHON) -m pip install ...
tesseract/5.0.0: fix wrong compiler version being output The compiler version shown was the one used instead of the one required. Bonify error message to include required and currently found compiler version.
@@ -94,7 +94,7 @@ class TesseractConan(ConanFile): self.output.warn( "%s recipe lacks information about the %s compiler standard version support" % (self.name, compiler)) elif compiler_version < minimal_version[compiler]: - raise ConanInvalidConfiguration("{} requires a {} version >= {}".format(self.name, compiler, com...
Update CHANGES.txt fixed CHANGES.txt to have only one section for Peter Dienier
@@ -9,6 +9,7 @@ RELEASE VERSION/DATE TO BE FILLED IN LATER From Peter Diener: - Additional fix to issue #3135 - Also handle 'pure' and 'elemental' type bound procedures + - Fix issue #3135 - Handle Fortran submodules and type bound procedures From William Deegan: @@ -21,9 +22,6 @@ RELEASE VERSION/DATE TO BE FILLED IN L...
Extensions: beautify name unqualification Yes, that's a real word.
@@ -19,6 +19,11 @@ from bot.utils.checks import with_role_check log = logging.getLogger(__name__) +def unqualify(name: str) -> str: + """Return an unqualified name given a qualified module/package `name`.""" + return name.rsplit(".", maxsplit=1)[-1] + + def walk_extensions() -> t.Iterator[str]: """Yield extension names...
Remove_Exiled_Entries: strip obsolete foreign nodes TN:
@@ -797,7 +797,27 @@ package body ${ada_lib_name}.Analysis is -- Remove the `symbol -> AST node` associations that reference this -- unit's nodes from foreign lexical environments. AST_Envs.Remove (El.Env, El.Key, El.Node); + + -- Also filter the foreign's units foreign nodes information so that + -- it does not contai...
Fixes for supplierpart table Paginate on server side
@@ -724,6 +724,7 @@ function loadSupplierPartTable(table, url, options) { url: url, method: 'get', original: params, + sidePagination: 'server', queryParams: filters, name: 'supplierparts', groupBy: false,
Apply PR feedback: check if signing key and ID match
@@ -539,6 +539,12 @@ class Pubsub: if msg.signature == b"": logger.debug("Reject because no signature attached for msg: %s", msg) return + # Validate if message sender matches message signer, + # i.e., check if `msg.key` matches `msg.from_id` + msg_pubkey = deserialize_public_key(msg.key) + if ID.from_pubkey(msg_pubkey...
Update README.md First Draft README
-# RAPIDS notebooks -Visit the main RAPIDS [notebooks](https://github.com/rapidsai/notebooks) repo for a listing of all notebooks across all RAPIDS libraries. +# cuSpatial Notebooks +## Intro +These notebooks provide examples of how to use cuSpatial. Some of these notebooks are designed to be self-contained with the `r...
Fixing total translation count for translations import. Fixes
@@ -210,6 +210,7 @@ class Importer(object): existing_po_file = self.pod.open_file(pod_po_path, mode='w') pofile.write_po(existing_po_file, existing_catalog, width=80, sort_output=True, sort_by_file=True) + total_translations = len(catalog_to_merge) else: # Skip new catalogs if not including obsolete messages. if not se...
Make rac, rc kwargs on UnmatchedOrder Resolves liampauling/betfairlightweight#97
@@ -390,8 +390,8 @@ class MarketBookCache(BaseResource): class UnmatchedOrder(object): - def __init__(self, id, p, s, side, status, pt, ot, pd, sm, sr, sl, sc, sv, rac, rc, rfo, rfs, - md=None, avp=None, bsp=None, ld=None): + def __init__(self, id, p, s, side, status, pt, ot, pd, sm, sr, sl, sc, sv, rfo, rfs, + md=None...
Fix bug with multiple model prefetches I found when calling prefetch with a model mulitple times but on different rel models would result in only one of the rel models getting the instances populated and all others with empty lists. This changes seems to fix the issue.
@@ -7439,7 +7439,7 @@ def prefetch(sq, *subqueries): rel_map.setdefault(rel_model, []) rel_map[rel_model].append(pq) - deps[query_model] = {} + deps.setdefault(query_model, {}) id_map = deps[query_model] has_relations = bool(rel_map.get(query_model))
Update to be able to use Pytest in TIR When I use TIR with PYTEST, it doesn't use the runner, so the 'test' attribute doesn't exist. I have made a correction that fix that problem.
@@ -139,7 +139,10 @@ class Log: Returns a list of test cases from suite """ runner = next(iter(list(filter(lambda x: "runner.py" in x.filename, inspect.stack())))) + try: return list(runner.frame.f_locals['test']) + except KeyError: + return [] def get_testcase_stack(self): """
Fix race in Mesos batch system Fixes Jobs were submitted to the queue *before* their taskResources were filled in. If the leader thread gets interrupted just before the taskResources are filled in, and the Mesos driver thread calls resourceOffers, the driver will crash and the pipeline will stall.
@@ -190,8 +190,8 @@ class MesosBatchSystem(BatchSystemLocalSupport, # TODO: round all elements of resources - self.jobQueues.insertJob(job, jobType) self.taskResources[jobID] = job.resources + self.jobQueues.insertJob(job, jobType) log.debug("... queued") return jobID
Fix error in master/pyomeca in one linestyle ("-." instead of inexistant ".-") Dunno why that didn't raise an error until my recent changes
@@ -55,7 +55,7 @@ class PlotOcp: self.ocp = ocp self.plot_options = { "general_options": {"use_tight_layout": True}, - "non_integrated_plots": {"linestyle": ".-", "markersize": 3}, + "non_integrated_plots": {"linestyle": "-.", "markersize": 3}, "integrated_plots": {"linestyle": "-", "markersize": 3, "linewidth": 1.1}, ...
indexing bug Found and fixed an indexing bug.
@@ -149,10 +149,14 @@ def compare_model_and_inst(pairs=None, inst_name=[], mod_name=[], # Flatten both data sets, since accuracy routines require 1D arrays inst_dat = pairs.data_vars[iname].values.flatten() + # Ensure no NaN are used in statistics + inum = np.where(~np.isnan(mod_scaled) & ~np.isnan(inst_dat))[0] + # Ca...
Remove unnecessary test_request_context manager This doesn't affect how the tests run and just adds complexity.
@@ -167,7 +167,6 @@ def test_delete_letter_notifications_older_than_retention_calls_child_task(notif def test_timeout_notifications_after_timeout(notify_api, sample_template): - with notify_api.test_request_context(): not1 = create_notification( template=sample_template, status='sending', @@ -190,7 +189,6 @@ def test_t...
Fixup: `get_last_submission_time_for_users()` set `for_export=True` to match behavior prior to
@@ -37,7 +37,7 @@ from corehq.util.quickcache import quickcache PagedResult = namedtuple('PagedResult', 'total hits') -def get_last_submission_time_for_users(domain, user_ids, datespan, for_export=True): +def get_last_submission_time_for_users(domain, user_ids, datespan, for_export=False): def convert_to_date(date): re...
DOC: updated template docstring Updated a template docstring to include a better example for future developers.
@@ -372,12 +372,11 @@ def list_remote_files(tag, inst_id, user=None, password=None): Parameters ----------- - tag : str or NoneType + tag : str Denotes type of file to load. Accepted types are <tag strings>. - (default=None) - inst_id : str or NoneType - Specifies the satellite ID for a constellation. Not used. - (defa...
Use global user cache to fetch reaction event data. Also make sure it isn't dispatched unless the data meets the integrity checks (i.e. not None).
@@ -321,6 +321,7 @@ class ConnectionState: if message is not None: reaction = message._add_reaction(data) user = self._get_reaction_user(message.channel, int(data['user_id'])) + if user: self.dispatch('reaction_add', reaction, user) def parse_message_reaction_remove_all(self, data): @@ -339,6 +340,7 @@ class Connection...
small typo in using slots doc Make the name of the action line up with the rest of the example
@@ -123,7 +123,7 @@ When the ``fetch_profile`` action is run, it returns a class FetchProfileAction(Action): def name(self): - return "fetch_profile" + return "action_fetch_profile" def run(self, dispatcher, tracker, domain): url = "http://myprofileurl.com"
GeneratorFactory: make getCategory respect self.site Previous behavior is to generate the pages with the site in user-config, regardless of the value in self.site.
@@ -544,6 +544,7 @@ class GeneratorFactory(object): categoryname = u'{0}:{1}'.format(self.site.namespace(14), categoryname) cat = pywikibot.Category(pywikibot.Link(categoryname, + source=self.site, defaultNamespace=14)) return cat, startfrom
Removed a +1 in nr of shots on advice of Niels H Tested with SSRO. No problems introduced by change.
@@ -1381,7 +1381,6 @@ class UHFQC_input_average_detector(Hard_Detector): self.AWG = AWG self.nr_samples = nr_samples self.nr_averages = nr_averages - print(nr_samples) def get_values(self): self.UHFQC.quex_rl_readout(0) # resets UHFQC internal readout counters @@ -1592,7 +1591,7 @@ class UHFQC_integration_logging_det(H...
Update feedpress-takeover.yaml As the issue indicated, it's no longer vulnerable, since 2020/9.
@@ -3,9 +3,9 @@ id: feedpress-takeover info: name: Agilecrm Takeover Detection author: pdteam - severity: high + severity: info reference: - - https://github.com/EdOverflow/can-i-take-over-xyz + - https://github.com/EdOverflow/can-i-take-over-xyz/issues/80 tags: takeover requests:
Updated REDME Fixed some errors.
@@ -7,16 +7,16 @@ This module contains some useful classes and functions for dealing with linear a ## Overview - class Vector - - This class represents a vector of arbitray size and operations on it. + - This class represents a vector of arbitrary size and operations on it. **Overview about the methods:** - constructor...
Update file.py There were problems with Image links from Facebook for example, because they have and need ?parameter1=abc&parameter2=def in their address.
@@ -329,7 +329,12 @@ def setup_folder_path(filename, new_parent): def get_extension(filename, extn, content): mimetype = None + if extn: + # remove '?' char and parameters from extn if present + if '?' in extn: + extn = extn.split('?', 1)[0] + mimetype = mimetypes.guess_type(filename + "." + extn)[0] if mimetype is Non...
get-pip The URL of get-pip.py has changed to
@@ -187,7 +187,7 @@ function mn_deps { $install ${PYPKG}-pip || $install ${PYPKG}-pip-whl if ! ${PYTHON} -m pip -V; then if [ $PYTHON_VERSION == 2 ]; then - wget https://bootstrap.pypa.io/2.6/get-pip.py + wget https://bootstrap.pypa.io/pip/2.6/get-pip.py else wget https://bootstrap.pypa.io/get-pip.py fi
fcntl: make mutate_flag optional for ioctl w/ read-only buffer Fixes
@@ -111,7 +111,7 @@ def ioctl(__fd: FileDescriptorLike, def ioctl(__fd: FileDescriptorLike, __request: int, __arg: _ReadOnlyBuffer, - __mutate_flag: bool) -> bytes: ... + __mutate_flag: bool = ...) -> bytes: ... def flock(__fd: FileDescriptorLike, __operation: int) -> None: ... def lockf(__fd: FileDescriptorLike, __cmd...
Set utf-8 encoding for reading the logo This appears primarily in Windows CLIs, see Also `termios` is not supported on Windows, however I haven't yet looked into an alternative.
@@ -75,7 +75,7 @@ def play_aidungeon_2(): story_manager = UnconstrainedStoryManager(generator) print("\n") - with open('opening.txt', 'r') as file: + with open('opening.txt', 'r', encoding='utf-8') as file: starter = file.read() print(starter)
Modified version The default value is version object ,not None exec cmd "hagrid launch domain" ,ERROR log is "Error: '>' not supported between instances of 'NoneType' and 'Version'"
@@ -82,7 +82,7 @@ class Dependency: name: str = "" display: str = "" only_os: str = "" - version: Optional[Version] = None + version: Optional[Version] = version.parse("None") valid: bool = False issues: List[SetupIssue] = field(default_factory=list) output_in_text: bool = False @@ -165,6 +165,7 @@ class DependencyGrid...
Update search.js make doctype in search result summary translatable
@@ -303,7 +303,7 @@ frappe.search.SearchDialog = class { let $results_list = $(`<div class="results-summary"> <div class="result-section full-list ${type}-section col-sm-12"> - <div class="result-title">${type}</div> + <div class="result-title"> ` + __(type) + `</div> <div class="result-body"> </div> </div> @@ -340,7 +...
Always handle multiple image files as a stack of images. Don't allow merging SPEC and image formats in a single command.
@@ -33,6 +33,7 @@ import re import time import silx.io +from silx.io.specfile import is_specfile try: from silx.io import fabioh5 @@ -126,6 +127,26 @@ def drop_indices_after_end(filenames, regex, end): return output_filenames +def are_all_specfile(filenames): + """Return True if all files in a list are SPEC files. + :p...
appease pylint Use the context manager form of subprocess.Popen in tests.
# pylint: disable=missing-docstring import os -import socket -import subprocess import sys -import time +from socket import socket +from subprocess import PIPE +from subprocess import Popen +from subprocess import STDOUT +from time import sleep +from time import time import pytest @@ -16,42 +19,43 @@ if "BEANCOUNT_FILE...
BUG: fix win32 np.clip slowness The use of the macro _NPY_CLIP results in multiple re-evaluations of the input arguments. Thus for floating point types, the check of NaNs is performed multiple times. This manifests itself as a slowness on Win32 builds. See
* npy_datetime, npy_timedelta# */ -#define _NPY_CLIP(x, min, max) \ - _NPY_@name@_MIN(_NPY_@name@_MAX((x), (min)), (max)) - NPY_NO_EXPORT void @name@_clip(char **args, npy_intp const *dimensions, npy_intp const *steps, void *NPY_UNUSED(func)) { @@ -95,25 +92,33 @@ NPY_NO_EXPORT void /* contiguous, branch to let the com...
Fix mock emulating lvm version 'lvm version' produces multiline output whereas test_version and test_fullversion use mocks with single-line output. Use real-life 'lvm version' output in those mocks instead.
@@ -34,18 +34,29 @@ class LinuxLVMTestCase(TestCase): ''' Tests LVM version info from lvm version ''' - mock = MagicMock(return_value='Library version : 1') + mock = MagicMock(return_value= + ' LVM version: 2.02.168(2) (2016-11-30)\n' + ' Library version: 1.03.01 (2016-11-30)\n' + ' Driver version: 4.35.0\n' + ) with p...
Use hashlib instead of sha library. The sha library was deprecated in Python 2.5.
@@ -19,10 +19,10 @@ to guard the display of sensitive information.""" __author__ = 'kpy@google.com (Ka-Ping Yee)' import cgi +import hashlib import os import pickle import random -import sha import time import urlparse @@ -36,7 +36,7 @@ REVEAL_KEY_LENGTH = 20 def sha1_hash(string): """Computes the SHA-1 hash of the giv...
Retry `docker push` 5 times Hopefully this avoids annoying timeouts that we get in our CI when pushing to quay.io. Fixes
@@ -221,7 +221,7 @@ obliterate_docker: clean_docker -docker images -qf dangling=true | xargs docker rmi push_docker: docker check_docker_registry - docker push $(docker_image):$(docker_tag) + for i in $$(seq 1 5); do docker push $(docker_image):$(docker_tag) && break || sleep 60; done else
Change repeat record attempt from a <pre/> to a <div/> When the response from the server doesn't contain newlines, you have to scroll all the way over to read the error message and it's kinda annoying. This keeps it visually separated, but will break lines.
{% block js-inline %}{{ block.super }} <script> $(function() { - $('#report-content').on('click', '.toggle-next-pre', function (e) { - $(this).nextAll('pre').toggle(); + $('#report-content').on('click', '.toggle-next-attempt', function (e) { + $(this).nextAll('.record-attempt').toggle(); e.preventDefault(); }); var cod...
Update publish-flow-onchain.md small tweak: ocean no longer has `config` attribute. But we have access to `config` object directly anyway, so use that Note: even after this fix, the README still has an error. See
@@ -40,7 +40,7 @@ contract_abi = { from ocean_lib.ocean.util import get_address_of_type from ocean_lib.models.factory_router import FactoryRouter -contract_address = get_address_of_type(ocean.config, FactoryRouter.CONTRACT_NAME) +contract_address = get_address_of_type(config, FactoryRouter.CONTRACT_NAME) #create asset ...
Fix homogenize not working with tuples Also fixes data corruption bug due to lists being mutable.
@@ -64,7 +64,7 @@ def homogenize(self, key, compare_values, default_row=None): rows.append(Row(default_row(difference), self._column_names)) else: if default_row is not None: - new_row = default_row + new_row = list(default_row) else: new_row = [None] * (len(self._column_names) - len(key))
[dagster-aws cli] Wait for EC2 instance status OK Summary: This addresses (4) in Test Plan: manual Reviewers: #ft, alangenfeld Subscribers: schrockn, alangenfeld
@@ -126,7 +126,7 @@ def init(): else: key_pair_name, key_file_path = create_key_pair(client, dagster_home) - inst = create_ec2_instance(ec2, security_group_id, ami_id, key_pair_name) + inst = create_ec2_instance(client, ec2, security_group_id, ami_id, key_pair_name) # Save host configuration for future commands cfg = H...
Remove "fxedit" static library from the "script/create-dist" config. The library was removed.
@@ -109,7 +109,6 @@ BINARIES_SHARED_LIBRARY = { os.path.join('obj', 'third_party', 'pdfium', 'libfpdftext.a'), os.path.join('obj', 'third_party', 'pdfium', 'libfxcodec.a'), os.path.join('obj', 'third_party', 'pdfium', 'libfxcrt.a'), - os.path.join('obj', 'third_party', 'pdfium', 'libfxedit.a'), os.path.join('obj', 'thi...
Convert other get_url requests to wget command calls wget provides better support for retrying and timeout delays
# openjpeg - name: Download openjpeg - get_url: - url: https://github.com/uclouvain/openjpeg/archive/v2.1.2.tar.gz - dest: "{{ root_dir }}/openjpeg-2.1.2.tar.gz" - checksum: "sha1:c8671e7f577fdc58abde1e1f32b10d372e6f9b07" + command: >- + wget --retry-connrefused --waitretry=1 --read-timeout=300 https://github.com/uclou...
wizard: let UserCancelled propagate out in hw wallet flow follow
@@ -393,8 +393,10 @@ class BaseWizard(Logger): # will need to re-pair devmgr.unpair_id(device_info.device.id_) raise ChooseHwDeviceAgain() - except (UserCancelled, GoBack): + except GoBack: raise ChooseHwDeviceAgain() + except (UserCancelled, ReRunDialog): + raise except UserFacingException as e: self.show_error(str(e)...
Produce coredumps in Travis on test failure. This can help if we're crashing for some reason, which will happen more and more as our C++ library gets bigger.
@@ -14,6 +14,15 @@ env: install: - pip install pipenv - pipenv install --dev --deploy + - sudo apt-get install -y gdb # install gdb + +before_script: + - ulimit -c unlimited -S # enable core dumps + +after_failure: + - PYTHON_EXECUTABLE=$(python3 -c "import sys; print(sys.executable)") + - COREFILE=$(find . -maxdepth 1...
Restricts Voice Silence Skip To Mod Roles Raises the permission required to not be muted during a voice silence to moderation roles.
@@ -282,7 +282,10 @@ class Silence(commands.Cog): log.debug(f"Removing all non staff members from #{channel.name} ({channel.id}).") for member in channel.members: - if self._helper_role not in member.roles: + # Skip staff + if any(role.id in constants.MODERATION_ROLES for role in member.roles): + continue + try: await ...
Round unitsPerEm Fix
@@ -240,7 +240,7 @@ class BaseOutlineCompiler(object): fullFontRevision, head.fontRevision) # upm - head.unitsPerEm = getAttrWithFallback(font.info, "unitsPerEm") + head.unitsPerEm = round(getAttrWithFallback(font.info, "unitsPerEm")) # times head.created = dateStringToTimeValue(getAttrWithFallback(font.info, "openType...
Some fixes in Huawei.VRP cm parser HG-- branch : feature/microservices
@@ -260,12 +260,14 @@ class BaseVRPParser(BaseParser): """ info-center loghost 10.46.147.5 channel 9 """ + if len(tokens) > 2: self.get_sysloghost_fact(tokens[2]) def on_ntp_server(self, tokens): """ ntp-service unicast-server 1.1.1.1 """ + if len(tokens) > 2: self.get_ntpserver_fact(tokens[2]) def on_system_domain_nam...
Filter UserWarning in QASM tests The test files specifically include constructs that aren't entirely supported yet, so it's correct for them to warn. It's also correct for us to assert that the warning occurs, though.
@@ -73,6 +73,7 @@ def check_measurement_defn(gate, gate_name, targets, classical_store): def test_qasm_addcircuit(): filename = "test_add.qasm" filepath = Path(__file__).parent / 'qasm_files' / filename + with pytest.warns(UserWarning, match="not preserved in QubitCircuit"): qc = read_qasm(filepath) assert qc.N == 2 as...
Fix consistence check for elements location This was failing when there was no point mass added to the rotor.
@@ -284,7 +284,12 @@ class Rotor(object): self.df_seals = df_seals # check consistence for disks and bearings location - if df.n_l.max() > df_shaft.n_r.max() and df.n_l.max() > df_point_mass.n.max(): + if len(df_point_mass) > 0: + max_loc_point_mass = df_point_mass.n.max() + else: + max_loc_point_mass = 0 + max_locatio...
Minor edits to doc tests and unit tests for landslides component fixed minor issues with doctests and unit tests Tests pass on local computer Ready to test pull request 480
@@ -41,16 +41,16 @@ def test_input_var_names(): """Testing if the input_var_names outputs the right list. """ assert_equal(sorted(ls_prob.input_var_names), - ['topographic__specific_contributing_area', - 'topographic__slope', - 'soil__transmissivity', - 'soil__saturated_hydraulic_conductivity', - 'soil__mode_total_cohe...
Address CVE-2019-10906 in loadgenerator Upgrade Jinja2 to version 2.10.1 * [CVE-2019-10906](https://nvd.nist.gov/vuln/detail/CVE-2019-10906) * [GitHub Security Alert](https://github.com/GoogleCloudPlatform/stackdriver-sandbox/network/alert/src/loadgenerator/requirements.txt/Jinja2/open)
@@ -12,7 +12,7 @@ gevent==1.4.0 # via locustio greenlet==0.4.15 # via gevent idna==2.8 # via requests itsdangerous==1.1.0 # via flask -jinja2==2.10 # via flask +jinja2==2.10.1 # via flask locustio==0.8.1 markupsafe==1.1.0 # via jinja2 msgpack-python==0.5.6 # via locustio
Update cloudbuild.yaml changed 'stesps' to 'steps'
# See the License for the specific language governing permissions and # limitations under the License. -# Purpose - This Google Cloudbuild configuration mimics the same stesps found +# Purpose - This Google Cloudbuild configuration mimics the same steps found # in .travis.yml. This could potentially be used in lieu of ...
Make revoke via CLI single threaded Fixing error - working outside of app context
:license: Apache, see LICENSE for more details. .. moduleauthor:: Kevin Glisson <kglisson@netflix.com> """ -import multiprocessing import sys from flask import current_app from flask_principal import Identity, identity_changed @@ -26,9 +25,10 @@ from lemur.certificates.service import ( get_all_valid_certs, get, get_all...
[IMPR] Avoid deeply nested flow statements continue loop instead of indenting if-statement
@@ -523,9 +523,10 @@ def main(*args): load_global_archivo() for page in pregenerator: + if not page.exists() or page.namespace() != 6 or page.isRedirectPage(): + continue + skip = False - if page.exists() and page.namespace() == 6 \ - and not page.isRedirectPage(): imagepage = pywikibot.FilePage(page.site, page.title()...
Tree rearrange correction for operations. The tree now accesses the dataobjects directly rather than getting a copy of them.
@@ -1338,7 +1338,7 @@ class RootNode(list): self.tree_lookup = {} self.tree.SetImageList(self.tree_images) self.item = self.tree.AddRoot(self.name) - self.node_operations = Node(NODE_OPERATION_BRANCH, list(elements.ops()), self, self, name=_("Operations")) + self.node_operations = Node(NODE_OPERATION_BRANCH, elements._...
ci: fix gha deprecations for promote-rc action update docker/login-action to v2 remove usage of deprecated ::set-output
@@ -21,7 +21,7 @@ jobs: - name: "Install Deps" uses: ./.github/actions/setup-deps - name: "Docker Login" - uses: docker/login-action@v1 + uses: docker/login-action@v2 with: registry: ${{ (!startsWith(secrets.RELEASE_REGISTRY, 'docker.io/')) && secrets.RELEASE_REGISTRY || null }} username: ${{ secrets.GH_DOCKER_RELEASE_...
Fix use of FakeRepository in tests that change current dir outside of the repo root, e.g. via tmpdir_cwd, or when running any test from a different working dir.
@@ -32,16 +32,16 @@ from piptools.utils import ( make_install_requirement, ) -from .constants import MINIMAL_WHEELS_PATH +from .constants import MINIMAL_WHEELS_PATH, TEST_DATA_PATH from .utils import looks_like_ci class FakeRepository(BaseRepository): def __init__(self): - with open("tests/test_data/fake-index.json") a...
Confirm no delivery estimate for emails and SMS Only letters have a delivery estimate (which we calculate). This commit adds a test to make sure this remains the case.
@@ -9,6 +9,11 @@ from tests.app.db import ( create_template, create_service) +from tests.app.conftest import ( + sample_notification, + sample_email_notification, +) + @pytest.mark.parametrize('billable_units, provider', [ (1, 'mmg'), @@ -233,6 +238,26 @@ def test_get_notification_adds_delivery_estimate_for_letters( as...
Add possibility to add bearing outside shaft Bearing can now be added outside the shaft (on a point mass).
@@ -284,7 +284,7 @@ class Rotor(object): self.df_seals = df_seals # check consistence for disks and bearings location - if df.n_l.max() > df_shaft.n_r.max(): + if df.n_l.max() > df_shaft.n_r.max() and df.n_l.max() > df_point_mass.n.max(): raise ValueError("Trying to set disk or bearing outside shaft") self.df = df
A couple small fixes to prevent errors associated with sample start and ending when no values are passed to EK60. 1) fixed names for self.read_start_sample and end_sample in __init__ (sample and start or end were reversed). 2) added assignment of start_sample and end_sample if no values passed to EK60
@@ -135,8 +135,8 @@ class EK60(object): self.read_end_time = None self.read_start_ping = None self.read_end_ping = None - self.read_sample_start = None - self.read_sample_end = None + self.read_start_sample = None + self.read_end_sample = None # read_frequencies can be set to a list of floats specifying the frequencies...
Set whitespace-only strings to null in date columns. Fixes part of
@@ -99,6 +99,10 @@ c.execute("LOAD DATA LOCAL INFILE %s INTO TABLE raw_table " # Remove the very few records that mess up the demo # (demo purposes only! Don't do something like this in production) c.execute("DELETE FROM raw_table WHERE LENGTH(date_recieved) < 10") + +# set empty, non-zero, strings in date columns to n...
change to backup name and procedure Named backup is changed to: projectname_BKP_yyyymmdd_hh.qda This also means multiple backups are produces less often. This is a nuisance issue for a few people. So a new backup cannot overwrite another backup created within the same hour.
@@ -860,6 +860,10 @@ class MainWindow(QtWidgets.QMainWindow): """ Open an existing project. if set, also save a backup datetime stamped copy at the same time. Do not backup on a newly created project, as it wont contain data. + A backup is created if settings backuop is True. + The backup is deleted, if no changes occu...
Fixed bug nesting 2 Fixed a bug that occured when making complex nesting schemes
@@ -760,6 +760,10 @@ class SequencerWidget(QtGui.QWidget): current_sequence[depth_idx] = [] current_sequence[depth_idx - 1] = [] + if depth == next_depth: + temp_sequence[depth].extend(current_sequence[depth]) + current_sequence[depth] = [] + sequences = temp_sequence[0] for idx in range(len(sequences)):
Replacing the photo handler Replacing the photo handler and remove compatible_aspect_ratio() from upload_story_photo()
@@ -7,7 +7,7 @@ from requests_toolbelt import MultipartEncoder import json from . import config -from .api_photo import resize_image, compatible_aspect_ratio, get_image_size +from .api_photo import stories_shaper, resize_image, compatible_aspect_ratio, get_image_size def download_story(self, filename, story_url, userna...
Fix misrendered docstring The API reference for `flask.Config.from_mapping` needs a newline to separate the summary from the return description. I also wrapped the docstring at 72 characters as suggested in CONTRIBUTING.rst.
@@ -275,8 +275,9 @@ class Config(dict): def from_mapping( self, mapping: t.Optional[t.Mapping[str, t.Any]] = None, **kwargs: t.Any ) -> bool: - """Updates the config like :meth:`update` ignoring items with non-upper - keys. + """Updates the config like :meth:`update` ignoring items with + non-upper keys. + :return: Alw...
removing as causes bug with upgrade path possibly causes upgrade via web to break ``` # This attaches the armui_cfg globally to let the users use any bootswatch skin from cdn armui_cfg = UISettings.query.filter_by().first() app.jinja_env.globals.update(armui_cfg=armui_cfg) ```
@@ -24,9 +24,6 @@ from flask_login import LoginManager, login_required, current_user, login_user, login_manager = LoginManager() login_manager.init_app(app) -# This attaches the armui_cfg globally to let the users use any bootswatch skin from cdn -armui_cfg = UISettings.query.filter_by().first() -app.jinja_env.globals....
Fix for 151 empty internal attributes from LDAP store Fix for 151 "Can internal response attributes have emptyvalues?". With this fix the LDAP attribute store will no longer set an internal attribute to be an empty list when the corresponding LDAP attribute returned with the record is empty.
@@ -167,8 +167,11 @@ class LdapAttributeStore(satosa.micro_services.base.ResponseMicroService): # Populate attributes as configured. for attr in search_return_attributes.keys(): if attr in record["attributes"]: + if record["attributes"][attr]: data.attributes[search_return_attributes[attr]] = record["attributes"][attr]...
Fix in MO view HG-- branch : feature/microservices
@@ -71,12 +71,10 @@ class ManagedObjectApplication(ExtModelApplication): ] def field_platform(self, o): - # return o.platform - return o.ex_platform + return o.platform def field_version(self, o): - # return o.get_attr("version") - return o.ex_version + return o.get_attr("version") def field_row_class(self, o): return ...
Clarify preferred style in luci-py README.md Context in comments of
@@ -69,6 +69,15 @@ Run the following to setup the code review tool and create your first review: Use `git cl help` and `git cl help <cmd>` for more details. +## Style + +The preferred style is PEP8 with two-space indent; that is, the [Chromium +Python +style](https://chromium.googlesource.com/chromium/src/+/master/styl...
Add link for telegram bot Add link for telegram bot
@@ -49,6 +49,8 @@ https://discordapp.com/oauth2/authorize?client_id=537526751170002946&permissions Send `!help` to open the bot help message. +Telegram Bot +https://t.me/epub_smelter_bot `<!-- Add your bot here -->` ### A3. Python package (for Windows, Mac, and Linux)
correction in "getting response from bot." section Correction in "getting a response from your chat bot" section. the code is not executing with 'None' in the bracket, hence added 'input()' to get inputs from the user. optionally added a print statement on next line to show the response from bot.
@@ -131,7 +131,8 @@ we can exit the loop and stop the program when a user enters `ctrl+c`. while True: try: - bot_input = bot.get_response(None) + bot_input = bot.get_response(input()) + print(bot_input) except(KeyboardInterrupt, EOFError, SystemExit): break
Ignore summary when only injected batches When a candidate block only contains valid injected batches, do not produce a summary. The block would fail the criteria that it should contain at least on externally submitted batch.
@@ -361,7 +361,7 @@ impl CandidateBlock { .map(|(batch_id, _)| batch_id.clone()) .collect(); - let valid_batch_ids: Vec<String> = execution_results + let valid_batch_ids: HashSet<String> = execution_results .batch_results .into_iter() .filter(|(_, txns)| match txns { @@ -380,6 +380,11 @@ impl CandidateBlock { let mut b...
Updated file ref:
@@ -8,45 +8,45 @@ automation: platform: mqtt topic: frigate/events conditions: - - "{{ trigger.payload_json["after"]["label"] == 'person' }}" - - "{{ 'yard' in trigger.payload_json["after"]["entered_zones"] }}" + - "{{ trigger.payload_json['after']['label'] == 'person' }}" + - "{{ 'yard' in trigger.payload_json['after'...
[fix] Stop loading all http responses into memory. fix Reverts
@@ -238,7 +238,6 @@ class Session(requests.Session): try: log.debug('Fetching URL %s with args %s and kwargs %s', url, args, kwargs) result = super(Session, self).request(method, url, *args, **kwargs) - log.trace('Contents for URL %s: %s', url, result.text) except requests.Timeout: # Mark this site in known unresponsiv...
Update EPEL mirror link This update changes the previous listed mirror URL as the epel package is missing which is causing container image builds to fail.
@@ -53,7 +53,7 @@ RUN set -ex && \ curl -sSfL https://raw.githubusercontent.com/anchore/grype/main/install.sh | sh -s -- -b /build_output/deps v0.13.0 # stage RPM dependency binaries -RUN yum install -y https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm && \ +RUN yum install -y https://download-ib01...
fw/execution: rename things for clarity Rename "instrument_name" to "instrument" inside do_execute(), as ConfigManger.get_instrument() returns a list of Instrument objects, not names. To avoid name clash, rename the imported instrument module to "instrumentation".
@@ -23,7 +23,7 @@ from copy import copy from datetime import datetime import wa.framework.signal as signal -from wa.framework import instrument +from wa.framework import instrument as instrumentation from wa.framework.configuration.core import Status from wa.framework.exception import TargetError, HostError, WorkloadEr...
catch nginx timeout in preindex for couchdb2, where we're proxying with nginx
@@ -35,7 +35,7 @@ def index_design_docs(db, docid, design_name): try: list(db.view(view, limit=0)) except RequestFailed as e: - if 'timeout' not in e.message: + if 'timeout' not in e.message and 'Time-out' not in e.message: raise else: break
Minor updates to drivers: .dscl -> .robust; fewer std gauge opts. Now "standard practice" gauge optimizations only include two spam weights with vSpam == 1 in both cases.
@@ -574,7 +574,7 @@ def do_long_sequence_gst_base(dataFilenameOrSet, targetGateFilenameOrSet, # and just keep (?) old estimates of all prior iterations (or use "blank" # sentinel once this is supported). - ret.add_estimate(gs_target, gs_start, gs_lsgst_list, scale_params, estlbl + ".dscl") + ret.add_estimate(gs_target,...
Updated German Renewable Capacities updated from same source
], "capacity": { "battery storage": 280, - "biomass": 8550, + "biomass": 8560, "coal": 43950, "gas": 30500, "geothermal": 47, "hydro storage": 9810, "nuclear": 8114, "oil": 4380, - "solar": 54520, + "solar": 56040, "unknown": 3700, - "wind": 62590 + "wind": 63170 }, "contributors": [ "https://github.com/corradio", "htt...
Fix openstack-tox-py39-with-oslo-master job DB writer and reader contexts are added to test case [0] to make sure updates are commited to DB before testing if objects have been deleted. [0] neutron.tests.unit.objects.test_quota.ReservationDbObjectTestCase.test_delete_expired Closes-Bug:
import datetime +from neutron_lib.db import api as db_api from oslo_utils import uuidutils from neutron.objects import quota -from neutron.tests import base as test_base from neutron.tests.unit.objects import test_base as obj_test_base from neutron.tests.unit import testlib_api @@ -59,16 +59,18 @@ class ReservationDbOb...
Fix New.subexprs Keys should not be names but strings
@@ -188,7 +188,7 @@ class New(AbstractExpression): @property def subexprs(self): - result = dict(self.assocs) + result = {str(k): v for k, v in self.assocs.items()} result['_type'] = self.static_type.name() return result
Add support for pushing built images to ECR Summary: Going forward we will push built images to ECR as well as DockerHub as part of our release process. Test Plan: Manual Reviewers: johann, rexledesma, catherinewu
+from typing import List + import click from dagster import __version__ as current_dagster_version from dagster import check CLI_HELP = """This CLI is used for building the various Dagster images we use in test """ +# We are waiting on our custom alias, and then this will be `public.ecr.aws/dagster` +AWS_ECR_REGISTRY =...
core: Allow deferral of of going up In a GoingUpEvent handler, one can get a deferral. POX will not transition to Up state until all the deferrals have been called.
@@ -128,7 +128,8 @@ pox.lib.revent.revent.handleEventException = _revent_exception_hook class GoingUpEvent (Event): """ Fired when system is going up. """ - pass + def get_deferral (self): + return self.source._get_go_up_deferral() class GoingDownEvent (Event): """ Fired when system is going down. """ @@ -197,6 +198,8 ...
llvm, functions/Stability: Reorganize state structure Make better use of existing state_id infrastructure.
@@ -361,17 +361,12 @@ class Stability(ObjectiveFunction): my_params = super()._get_param_values(context) return (*my_params, self._metric_fct._get_param_values(context)) - def _get_state_struct_type(self, ctx): - my_state = ctx.get_state_struct_type(super()) - metric_state = ctx.get_state_struct_type(self._metric_fct) ...
Update Quickstart with requested changes addition of 'but' removal trailing phrase inside parentheses Url replaced with URL as it's still an acronym so it's written with capital letters
@@ -16,7 +16,7 @@ C. Assign rwx(read/write/execute) permissions to the user for default database d $ sudo chmod -R 700 /data/db ``` -D. Run MongoDB (do not close this terminal): +D. Run MongoDB (but do not close this terminal): ```text $ sudo mongod --replSet=bigchain-rs ``` @@ -57,7 +57,7 @@ I. Run BigchainDB Server: ...
- markets.lower() not worked Some lines was a bit confused, if (never) removed
@@ -449,8 +449,7 @@ class BinanceWebSocketApiManager(threading.Thread): else: return False else: - if market == "!userData" or market == "!miniTicker": - query += market + "@" + channel + "/" + return False else: query += market.lower() + "@" + channel + "/" uri = self.websocket_base_uri + str(query)
Remove unused self.host_repos_path from plugin InjectYumRepoPlugin After the removal, no need to keep __init__ there. So, remove it as well.
@@ -55,17 +55,6 @@ class InjectYumRepoPlugin(PreBuildPlugin): key = "inject_yum_repo" is_allowed_to_fail = False - def __init__(self, tasker, workflow): - """ - constructor - - :param tasker: ContainerTasker instance - :param workflow: DockerBuildWorkflow instance - """ - # call parent constructor - super(InjectYumRepo...
Update ncbi-covid-19.yaml Updated the "Frequency of updates" and fixed a typo
Name: COVID-19 Genome Sequence Dataset -Description: A centralized sequence repository for all strains of novel corona virus (SARS-CoV-2) submitted to the National Center for Biotechnology Information (NCBI). Included are both the original sequences submitted by the principal investigator as well as SRA-processed seque...
Fix client library URL. Closes
@@ -10,7 +10,7 @@ variants, to support your global user base. .. _Beta: https://github.com/GoogleCloudPlatform/google-cloud-python/blob/master/README.rst .. _Cloud Speech API: https://cloud.google.com/speech -.. _Client Library Documentation: https://googlecloudplatform.github.io/google-cloud-python/stable/speech/usage...
add windows-latest and macos-latest to build matrix also: apt update before apt install
@@ -12,6 +12,15 @@ jobs: - name: linux-3.10 python-version: "3.10" os: ubuntu-latest + - name: windows-3.10 + python-version: "3.10" + os: windows-latest + - name: macos-11-3.10-skip-exe + python-version: "3.10" + os: macos-11 + - name: macos-10.5-3.10-skip-exe + python-version: "3.10" + os: macos-10.15 - name: linux-3...
Unlisten Gracefully. Calls the process queue for the final time after shutdown. Finishing up any remaining processing of the queue and any removed listeners etc.
@@ -647,12 +647,7 @@ class Kernel: if channel is None: channel = self.get_context('/').channel('shutdown') - self.state = STATE_END - - # Suspend Signals - def signal(code, *message): - channel(_("Suspended Signal: %s for %s" % (code, message))) - self.signal = signal + self.state = STATE_END # Terminates the Scheduler...
docs: Added PyCharm to the list of editors. PyCharm is great for writing Python.
@@ -128,6 +128,7 @@ don't have a favorite, here are some suggestions: * [vim](https://www.vim.org/) * [spacemacs](https://github.com/syl20bnr/spacemacs) * [sublime](https://www.sublimetext.com/) +* [PyCharm](https://www.jetbrains.com/pycharm/) Next, follow our [Git and GitHub Guide](../git/index.md) to clone and config...
Update unit-timeevolution.cpp Try to isolate offending part of tests. When running ./test-timeevolution I got Dopri54 ellapsed time: 94998us odeint ellapsed time: 81332us # Graph created # Number of nodes = 1 No configurations specified for time evolution
@@ -338,6 +338,7 @@ TEST_CASE("Comparison with boost::odeint for Schroedinger eq", "[time-evolution] } #endif +/* TEST_CASE("Time evolution driver produces sensible output", "[time-evolution]") { json pars; @@ -412,3 +413,4 @@ TEST_CASE("Time evolution driver produces sensible output", "[time-evolution]") } } } +*/
tox: switch from pep8 to flake8 Added a lot more errors/warnings to the list so that things would still pass. Follow on commits will back off these one by one so make the review process easier.
@@ -13,7 +13,7 @@ commands = [testenv:pep8] deps = - pep8 + flake8 commands = - {envbindir}/pep8 -r --show-source --max-line-length=84 --ignore=E123,E124,E126,E127,E128,E303,E302 pyrax/ + {envbindir}/flake8 --show-source --max-line-length=84 --ignore=E123,E124,E126,E127,E128,E303,E302,W606,F841,E301,F401,E305,F811,F812...
Note that Quart-Motor has been released This allows for MongoDB connections.
@@ -19,6 +19,8 @@ here, broadcasting via WebSockets or SSE. - `Quart-minify <https://github.com/AceFire6/quart_minify/>`_ minify quart response for HTML, JS, CSS and less. +- `Quart-Motor <https://github.com/marirs/quart-motor>`_ Motor + (MongoDB) support for Quart applications. - `Quart-OpenApi <https://github.com/fac...
faster tril_indices nonzero is slow. Use np.indices and np.broadcast_to to speed it up.
@@ -894,7 +894,10 @@ def tril_indices(n, k=0, m=None): [-10, -10, -10, -10]]) """ - return nonzero(tri(n, m, k=k, dtype=bool)) + tri = np.tri(n, m=m, k=k, dtype=bool) + + return tuple(np.broadcast_to(inds, tri.shape)[tri] + for inds in np.indices(tri.shape, sparse=True)) def _trilu_indices_form_dispatcher(arr, k=None):...
ceres-solver: setup options in configure + validate Following up from
@@ -69,6 +69,8 @@ class ceressolverConan(ConanFile): def configure(self): if self.options.shared: del self.options.fPIC + if self.options.use_gflags: + self.options["gflags"].nothreads = False def requirements(self): self.requires("eigen/3.4.0") @@ -76,7 +78,6 @@ class ceressolverConan(ConanFile): self.requires("glog/0...