How to submit calculatons

We need to figure out how we're going to submit calculations for SPICE 2.  For version 1 we used the https://github.com/openforcefield/qca-dataset-submission repository.  It uses github automation, so that you submit calculations by creating pull requests.  Status updates are automatically posted to the PR, and it handles error cycling.  The automation scripts use QCSubmit, which is a layer on top of the QCPortal API to provide additional useful features.
Due to a major redesign of QCPortal, QCSubmit is currently not functional.  It's being updated, but there isn't a firm date for when the new version will be ready.  Also, the new version of QCPortal provides many of the features it was created to add.  According to @j-wags, QCSubmit still provides useful features for optimization datasets.  For single point datasets, which is what we're using, the benefits are much smaller.
So we have a few questions to decide.

Should we wait for QCSubmit, or just write our own scripts that use the QCPortal API directly?
Should we try to automate the process through github actions, or just create scripts that we run by hand?

It looks to me like creating submissions should be about equally simple either way.  Having status updates automatically posted to github is convenient but probably not that important.  It's easy to write a script that you run to check the status.  Error cycling might be more complicated, although I'm hoping it may no longer be as important.  Newer versions of psi4 seem to be a lot better about not producing the sort of intermittent errors it's needed for.  And while generating v1, we wasted a lot of computation time on error cycling, just repeating the same calculations over and over that kept failing.
Another benefit of the github approach is that it provides a record of the submission, but that too may be unnecessary for our purposes.  All our submission will be the same type of dataset, and they'll all use exactly the same level of theory and other settings.  I believe the only inputs needed for the submission will be the dataset name, and the HDF5 file containing the conformations (which is already in the repository).
cc @dotsdl

Here's a first pass at a script for submitting datasets (not yet tested).
from qcportal import PortalClient
from qcportal.singlepoint import QCSpecification, SinglepointDatasetNewEntry
from qcportal.molecules import Molecule
from openmm.unit import nanometer, bohr
import openff.units
import numpy as np
import h5py
import sys

dataset_name = sys.argv[1]
filename = sys.argv[2]
input_file = h5py.File(filename)
client = PortalClient.from_file()
entries = []
scale = (1*nanometer).value_in_unit(bohr)
for group in input_file:
    smiles = input_file[group]['smiles'].asstr()[0]
    conformations = np.array(input_file[group]['conformations'])*scale
    ffmol = openff.toolkit.topology.Molecule.from_mapped_smiles(smiles, allow_undefined_stereo=True)
    symbols = [atom.symbol for atom in ffmol.atoms]
    total_charge = sum(atom.formal_charge/openff.units.unit.elementary_charge for atom in ffmol.atoms)
    for conformation in conformations:
        molecule = Molecule(symbols=symbols, geometry=conformation.flatten(), molecular_charge=total_charge)
        entries.append(SinglepointDatasetNewEntry)
keywords = {'maxiter': 200,
            'scf_properties': ['dipole', 'quadrupole', 'wiberg_lowdin_indices', 'mayer_indices'],
            'wcombine': False}
spec = QCSpecification(program='psi4', driver='gradient', method='wb97m-d3bj', basis='def2-tzvppd', keywords=keywords)
dataset = client.add_dataset('singlepoint', dataset_name)
dataset.add_specification('wb97m-d3bj/def2-tzvppd', spec)
dataset.add_entries(entries)
dataset.submit(tag='spice-psi4-181')

Does that look generally correct?  A first test will be to resubmit the DES monomers dataset with it.  If everything is working correctly, QCArchive should recognize that all the samples are identical to ones that already exist and skip calculating anything.  Assuming that works, the next test would be to force it to recompute them by adding a small offset to the positions and see if the results match what we got before.

I edited the above script with a few changes.

Checking this out by analogy to OFFMol.to_qcschema, it looks like the two things this doesn't have are:

connectivity, which is probably not important (I think was an early attempt to capture what we ended up being CMILES for but which didn't fly because it didn't have formal charge and we weren't sure if it should hold other things like stereo and formal charges)
multiplicity, which you probably need

For how we set multiplicity, I'm not totally sure since I'm not a QM person. Some hints are:

The default value is in OFFMol.to_qcschema is 1
Doing a code search of our organization, we almost never change it from 1.
In this line, which isn't part of our standard submission pipeline (it's openff-recharge, a research tool), there seems to be a check for unpaired electrons, where if there IS an unpaired electron, there's a multiplicity of 2, otherwise there's a multiplicity of 1.

So, I think for "reasonable" molecules we're always treating multiplicity as 1. For radicals other values may be necessary.
I think the CMILES may need to go somewhere else (maybe there's now an actual "cmiles" attribute, but I vaguely recall mention of a properties dict or an identifiers attribute).
To test this without risking problems on the central QCArchive, I'd recommend spinning up a QCFractal "snowflake" (a mini server living in a local process) with a really cheap psi4 method, and then making sure that the outputs look reasonable (especially that the CMILES makes it through and the atom ordering seems sane).

I've tried a few different methods of getting it to store the SMILES, including identifiers = Identifiers(canonical_isomeric_explicit_hydrogen_mapped_smiles=smiles) and extras = {'canonical_isomeric_explicit_hydrogen_mapped_smiles': smiles}.  Neither one works.  The property gets set on the Molecule object before I call add_entry().  But when I query the dataset for either entries or records, it's not there anymore.
Using a Snowflake I can create the dataset, but no calculations get run.  The status of the record just stays as 'waiting'.  Do I need to do something else to make it run calculations?

@bennybp do you have any idea what I'm doing wrong that's causing the above problems?

In QCSubmit's tests, we use the fulltest_client testing fixture from QCFractal, which makes a snowflake with some local compute workers. That method is distributed in the qcarchivetesting conda package. You may be able to use that function verbatim to get a snowflake that can run a few local calculations.

I haven't looked too deeply, but my hunch is that the molecule already exists on the server without the identifiers, and add_entry won't overwrite that. You can test this by translating the molecule by a little and see what happens.
If that is the case, you can keep the old molecule and change the identifiers afterwards with the PortalClient. (https://github.com/MolSSI/QCFractal/blob/e8d9cba50b1e59bf8ff85992cd9dc8f94158fe1b/qcportal/qcportal/client.py#L473).
For the snowflake issue, you might not have the QM package installed in the backend. Something like this conda env should work (assuming you are using psi4): https://github.com/MolSSI/QCFractal/blob/main/qcarchivetesting/conda-envs/fulltest_snowflake.yaml

As far as I can tell all the dependencies are there.  Is there a way to get an error message saying why it isn't running anything?

my hunch is that the molecule already exists on the server without the identifiers

This is with a snowflake.  There's nothing on the server.

Here's an error message:
Process ForkProcess-2:
Traceback (most recent call last):
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
    self.run()
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/multiprocessing/process.py", line 108, in run
    self._target(*self._args, **self._kwargs)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractal/snowflake.py", line 60, in _compute_process
    compute = ComputeManager(compute_config)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractalcompute/compute_manager.py", line 133, in __init__
    self.app_manager = AppManager(self.manager_config)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractalcompute/apps/app_manager.py", line 108, in __init__
    qcengine_functions = discover_programs_conda(None)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractalcompute/apps/app_manager.py", line 34, in discover_programs_conda
    result = subprocess.check_output(cmd, universal_newlines=True, cwd=tmpdir)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/subprocess.py", line 424, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/subprocess.py", line 528, in run
    raise CalledProcessError(retcode, process.args,
subprocess.CalledProcessError: Command '['python3', '/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractalcompute/run_scripts/qcengine_list.py']' returned non-zero exit status 1.
Traceback (most recent call last):
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractalcompute/run_scripts/qcengine_list.py", line 12, in <module>
    progs = {x: qcengine.get_program(x).get_version() for x in qcengine.list_available_programs()}
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcfractalcompute/run_scripts/qcengine_list.py", line 12, in <dictcomp>
    progs = {x: qcengine.get_program(x).get_version() for x in qcengine.list_available_programs()}
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcengine/programs/psi4.py", line 91, in get_version
    self.version_cache[which_prog] = safe_version(exc["stdout"].split()[-1])
IndexError: list index out of range

The error happens while querying psi4.  The code
for x in qcengine.list_available_programs():
    print(x)
    print(qcengine.get_program(x).get_version())

prints
rdkit
2023.3.1
xtb
20.2
openmm
8.0.0
psi4

Here's the psi4 version in my conda environment:
psi4                      1.8.1            py39haabd4ea_2    conda-forge

what is psi4 --version, please? could there be multiple psi4's around? and check if qcengine is at 0.28.1

I think the conda package for psi4 on Mac is broken.  Just running psi4 produces a Python exception.  I tried a different computer running Linux, and there it's able to correctly enumerate the programs.
Running on that computer, the status is briefly listed as running and top shows that psi4 is running.  Then it stops and the status switches to error.  How can I find out what the error was?  The documentation says, "The error and possibly the stdout/stderr properties may have more details about the error."  But the record object has no attribute called error, stdout, or stderr.
What is the correct way to store the SMILES?  When I create the Molecule I specify extras = {'canonical_isomeric_explicit_hydrogen_mapped_smiles': smiles}.  If I then immediately print out molecule.extras it prints
{'canonical_isomeric_explicit_hydrogen_mapped_smiles': '[Br:1][C:4]([Br:2])([Br:3])[H:5]'}

But when I query the record from the dataset, it lists extras=None.

and check if qcengine is at 0.28.1

It's 0.27.0.  Conda doesn't find anything newer.

It's because psi4 pins the version.  If I try to force qcengine=0.28.1 I get
Encountered problems while solving:
  - package psi4-1.8.1-py311hedf2024_2 requires qcengine >=0.27.0,<0.28.0a0, but none of the providers can be installed

As to why a record is waiting, I was inspired to make that a feature (which isn't available yet, but will be a nice addition: https://github.com/MolSSI/QCFractal/pull/759)
For the identifiers part: It seems to work for me. The identifiers are attached to the molecule:
from qcfractal.snowflake import FractalSnowflake
from qcportal.molecules import Molecule

s = FractalSnowflake()
c = s.client()

m = Molecule(symbols=['h', 'h'],
             geometry=[0, 0, 0, 0, 0, 1],
             identifiers={'canonical_isomeric_explicit_hydrogen_mapped_smiles': "abc123"}
)

ds = c.add_dataset('singlepoint', 'test dataset')
ds.add_entry('test_entry', molecule=m)

# Re-get the dataset
ds = c.get_dataset('singlepoint', 'test dataset')
entry = ds.get_entry('test_entry')
print(entry.molecule.identifiers)

ds.add_specification('test_spec', {'program': 'psi4', 'driver': 'energy', 'method': 'b3lyp', 'basis': '6-31g'})
ds.submit()

rec = ds.get_record('test_entry', 'test_spec')
print(rec.molecule.identifiers)

The value for canonical_isomeric_explicit_hydrogen_mapped_smiles appears in both

Perhaps I was making things too complicated by trying to create an Identifiers object.  I take it the correct usage is just to pass a dict?
I want to create the new datasets in a way that's consistent with the existing ones.  I'm looking at the existing 'SPICE DES Monomers Single Points Dataset v1.1' dataset.  For the molecules in that dataset, the canonical SMILES is not present in identifiers:

Identifiers(molecule_hash='e11edc2979035fc70f58366ce13b6bb707adaf18', molecular_formula='C2H3N', smiles=None, inchi=None, inchikey=None, canonical_explicit_hydrogen_smiles=None, canonical_isomeric_explicit_hydrogen_mapped_smiles=None, canonical_isomeric_explicit_hydrogen_smiles=None, canonical_isomeric_smiles=None, canonical_smiles=None, pubchem_cid=None, pubchem_sid=None, pubchem_conformerid=None)

Instead it's in extras:

{'canonical_isomeric_explicit_hydrogen_mapped_smiles': '[H:4]C:3([H:6])[C:2]#[N:1]'}

For consistency I think we should continue to put it in extras.  But we also should presumably put it in identifiers, since that's now the recommended place for it?
I'm not clear on how to connect up records and entries.  I try to loop over everything in the dataset like this:
for s in ds.specification_names:
    for e in ds.iterate_entries():
        print(s, e.name)
        print(ds.get_record(e.name, s))

But get_record() never finds anything:
spec_1 cc#n-3
None
spec_1 cnc-2
None
spec_1 nccco-16
None

Am I not calling it correctly?  The API documentation says the first argument is the entry name and the second is the specification name.

It's because psi4 pins the version

of course it does: bad, self. I'll step up the v1.8.2 release that releases the pin. I haven't heard other reports of the mac psi4 being broken, though.

For consistency I think we should continue to put it in extras. But we also should presumably put it in identifiers, since that's now the recommended place for it?

Either is ok, and can can be added/modified later (although right now extras on molecules are not modifiable, it is on my to-do list).

Am I not calling it correctly? The API documentation says the first argument is the entry name and the second is the specification name.

 There are no calculations submitted for spec_1, only for spec_2, spec_4, and spec_6.
r = ds.get_record('cc#n-3', 'spec_2')
print(r.id, r.status)
111567635 RecordStatusEnum.complete

This must be something to do with how specifications were created when the data was converted to the new format?  There are actually six specifications.    One (which has no records) has it set to orbitals_and_eigenvalues, while the other (which has records for all samples), has it set to none.
spec_2 and spec_4 are the OpenFF and SPICE levels of theory, respectively.  Those were the only two specifications I expected to be present.  I have no idea where spec_6 came from.  It has program='dftd3'???
@loriab here is the exception I get when running psi4 on the Mac.  I assume it's unrelated to the problem I'm seeing on Linux, where the record status is reported as error with no error message.
Traceback (most recent call last):
  File "/Users/peastman/miniconda3/envs/qcportal/bin/psi4", line 213, in <module>
    import psi4  # isort:skip
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/psi4/__init__.py", line 90, in <module>
    from .driver import endorsed_plugins
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/psi4/driver/__init__.py", line 56, in <module>
    from psi4.driver import gaussian_n
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/psi4/driver/gaussian_n.py", line 31, in <module>
    from psi4.driver import driver
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/psi4/driver/driver.py", line 49, in <module>
    from psi4.driver import driver_nbody
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/psi4/driver/driver_nbody.py", line 830, in <module>
    class ManyBodyComputer(BaseComputer):
  File "pydantic/main.py", line 204, in pydantic.main.ModelMetaclass.__new__
  File "pydantic/fields.py", line 488, in pydantic.fields.ModelField.infer
  File "pydantic/fields.py", line 419, in pydantic.fields.ModelField.__init__
  File "pydantic/fields.py", line 534, in pydantic.fields.ModelField.prepare
  File "pydantic/fields.py", line 728, in pydantic.fields.ModelField._type_analysis
  File "pydantic/fields.py", line 778, in pydantic.fields.ModelField._create_sub_type
  File "pydantic/fields.py", line 419, in pydantic.fields.ModelField.__init__
  File "pydantic/fields.py", line 534, in pydantic.fields.ModelField.prepare
  File "pydantic/fields.py", line 728, in pydantic.fields.ModelField._type_analysis
  File "pydantic/fields.py", line 778, in pydantic.fields.ModelField._create_sub_type
  File "pydantic/fields.py", line 419, in pydantic.fields.ModelField.__init__
  File "pydantic/fields.py", line 534, in pydantic.fields.ModelField.prepare
  File "pydantic/fields.py", line 633, in pydantic.fields.ModelField._type_analysis
  File "pydantic/fields.py", line 778, in pydantic.fields.ModelField._create_sub_type
  File "pydantic/fields.py", line 419, in pydantic.fields.ModelField.__init__
  File "pydantic/fields.py", line 534, in pydantic.fields.ModelField.prepare
  File "pydantic/fields.py", line 638, in pydantic.fields.ModelField._type_analysis
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/typing.py", line 851, in __subclasscheck__
    return issubclass(cls, self.__origin__)
TypeError: issubclass() arg 1 must be a class

This must be something to do with how specifications were created when the data was converted to the new format? There are actually six specifications.  One (which has no records) has it set to orbitals_and_eigenvalues, while the other (which has records for all samples), has it set to none.

@peastman it's not clear to me where you're seeing this. Can you show us what you are running that gives these specs?
I recall that when we first ran SPICE, we used specs that preserved wavefunctions ('orbitals_and_eigenvalues'), and this ended up resulting in a massive amount of data filling up the old server. We later chose to run the same specs without preserving wavefunctions (None), and those calculations we kept.

I generated that output with this code:
client = PortalClient('https://ml.qcarchive.molssi.org')
ds = client.get_dataset('singlepoint', 'SPICE DES Monomers Single Points Dataset v1.1')
for s in ds.specifications:
    print(ds.specifications[s])
    print()

@bennybp I have my script working when using a snowflake.  Now I'm trying to test it on the real server by resubmitting the DES monomers dataset.  That's one of the smaller ones: 374 molecules, all of them very small, 18,700 conformations total.  It initially seems to be working, but creating the entries is really slow, about five per second.  At that rate, the larger datasets would take over a day to submit.  But after the first 100 molecules (about 20 minutes), it crashes with an exception.  I tried twice and got the same exception both times.
Traceback (most recent call last):
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/connectionpool.py", line 449, in _make_request
    six.raise_from(e, None)
  File "<string>", line 3, in raise_from
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/connectionpool.py", line 444, in _make_request
    httplib_response = conn.getresponse()
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/http/client.py", line 1377, in getresponse
    response.begin()
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/http/client.py", line 320, in begin
    version, status, reason = self._read_status()
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/http/client.py", line 281, in _read_status
    line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/socket.py", line 704, in readinto
    return self._sock.recv_into(b)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
socket.timeout: The read operation timed out

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/requests/adapters.py", line 440, in send
    resp = conn.urlopen(
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/connectionpool.py", line 785, in urlopen
    retries = retries.increment(
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/util/retry.py", line 550, in increment
    raise six.reraise(type(error), error, _stacktrace)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/packages/six.py", line 770, in reraise
    raise value
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/connectionpool.py", line 703, in urlopen
    httplib_response = self._make_request(
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/connectionpool.py", line 451, in _make_request
    self._raise_timeout(err=e, url=url, timeout_value=read_timeout)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/urllib3/connectionpool.py", line 340, in _raise_timeout
    raise ReadTimeoutError(
urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='ml.qcarchive.molssi.org', port=443): Read timed out. (read timeout=60)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/Users/peastman/workspace/spice-dataset/submission/submit.py", line 33, in <module>
    dataset.add_entry(f'{group}-{i}', molecule)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/singlepoint/dataset_models.py", line 120, in add_entry
    return self.add_entries(ent)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/singlepoint/dataset_models.py", line 88, in add_entries
    ret = self._client.make_request(
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/client_base.py", line 358, in make_request
    r = self._request(method, endpoint, body=serialized_body, url_params=parsed_url_params)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/client_base.py", line 297, in _request
    r = self._req_session.send(prep_req, verify=self._verify, timeout=self._timeout)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/requests/sessions.py", line 645, in send
    r = adapter.send(request, **kwargs)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/requests/adapters.py", line 532, in send
    raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='ml.qcarchive.molssi.org', port=443): Read timed out. (read timeout=60)

I do see similar behavior (although not quite as bad on my end). I think there's some inefficiency in the add_entry code on the server that only shows up with larger datasets. I am investigating.
An alternative which will likely be much faster is to use the bulk add_entries function. It's a little clunky, but let me see if I can polish it up quick.

Thanks!  I didn't realize there was a bulk version.  I'll try that.
The above behavior was running the script at home.  I managed to work around it by running it on a cluster with a faster internet connection.  It was still slow, but at least it didn't time out.
When I resubmitted the DES monomers dataset, it didn't recognize any of the records as duplicates of existing ones.  I let it rerun the whole dataset, and the results agree well with the existing ones.

Much better!  It successfully submitted the whole dataset in just over a minute.  And it recognized all the records as duplicates of the ones computed yesterday.

The script is in #85.  I think this means we can finally start running calculations!

When I tried to submit a larger dataset (the PubChem boron silicon set, 174,450 conformations total) it still failed even with the bulk creation.  Running from home it fails with the error
Traceback (most recent call last):
  File "/Users/peastman/workspace/spice-dataset/submission/submit.py", line 34, in <module>
    dataset.add_entries(entries)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/singlepoint/dataset_models.py", line 88, in add_entries
    ret = self._client.make_request(
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/client_base.py", line 358, in make_request
    r = self._request(method, endpoint, body=serialized_body, url_params=parsed_url_params)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/client_base.py", line 311, in _request
    return self._request(method, endpoint, body=body, url_params=url_params, retry=False)
  File "/Users/peastman/miniconda3/envs/qcportal/lib/python3.9/site-packages/qcportal/client_base.py", line 323, in _request
    raise PortalRequestError(f"Request failed: {details['msg']}", r.status_code, details)
qcportal.client_base.PortalRequestError: Request failed: Token has expired (HTTP status 401)

Running on the cluster it gets a different error:
Traceback (most recent call last):
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/connectionpool.py", line 536, in _make_request
    response = conn.getresponse()
               ^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/connection.py", line 461, in getresponse
    httplib_response = super().getresponse()
                       ^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/http/client.py", line 1378, in getresponse
    response.begin()
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/http/client.py", line 318, in begin
    version, status, reason = self._read_status()
                              ^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/http/client.py", line 279, in _read_status
    line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/socket.py", line 706, in readinto
    return self._sock.recv_into(b)
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/ssl.py", line 1311, in recv_into
    return self.read(nbytes, buffer)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/ssl.py", line 1167, in read
    return self._sslobj.read(len, buffer)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
TimeoutError: The read operation timed out

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/requests/adapters.py", line 486, in send
    resp = conn.urlopen(
           ^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/connectionpool.py", line 844, in urlopen
    retries = retries.increment(
              ^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/util/retry.py", line 470, in increment
    raise reraise(type(error), error, _stacktrace)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/util/util.py", line 39, in reraise
    raise value
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/connectionpool.py", line 790, in urlopen
    response = self._make_request(
               ^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/connectionpool.py", line 538, in _make_request
    self._raise_timeout(err=e, url=url, timeout_value=read_timeout)
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/urllib3/connectionpool.py", line 370, in _raise_timeout
    raise ReadTimeoutError(
urllib3.exceptions.ReadTimeoutError: HTTPSConnectionPool(host='ml.qcarchive.molssi.org', port=443): Read timed out. (read timeout=60)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/groups/tem26/peastman/workspace/spice-dataset/submission/submit.py", line 34, in <module>
    dataset.add_entries(entries)
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/qcportal/singlepoint/dataset_models.py", line 88, in add_entries
    ret = self._client.make_request(
          ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/qcportal/client_base.py", line 358, in make_request
    r = self._request(method, endpoint, body=serialized_body, url_params=parsed_url_params)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/qcportal/client_base.py", line 297, in _request
    r = self._req_session.send(prep_req, verify=self._verify, timeout=self._timeout)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/requests/sessions.py", line 703, in send
    r = adapter.send(request, **kwargs)
        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/users/peastman/miniconda3/envs/qcfractalcompute/lib/python3.11/site-packages/requests/adapters.py", line 532, in send
    raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='ml.qcarchive.molssi.org', port=443): Read timed out. (read timeout=60)

I tried twice on each computer and got the same result both times.

I think it's because qcportal hardcodes the timeout to 60 seconds:
https://github.com/MolSSI/QCPortal/blob/7966f3fdbca84251d5e07bb652af9db1a08ded1f/qcportal/client_base.py#L90
The server is taking longer than 60 seconds to reply, causing it to fail.

There is a time limit on the client, but that is changeable. I should make it not a private variable, but you can set client._timeout = 120. The server also has a timeout, though, which is around 1-2 minutes, so it might not help.
I did make some changes to the server to make it faster, but that needs a new release (tentatively later this week). I will also add automatic batching to add_entries with a progress bar, which would hopefully stop this particular error once in for all. ds.submit is another story, though.

@bennybp: What's the plan to deal with the server timeout? Will that be substantially increased? Can calculations be split into separate requests that append?
Even if the client timeout is increased and the server is sped up a bit, it seems we are still ultimately going to run into that timeout.

I tried setting client._timeout = 120, but I still got the same error.

I tried again, this time setting client._timeout = None to completely disable the client side timeout.  Still the same result.
The real problem may be something different.  The error message is Token has expired (HTTP status 401).  401 is an authentication failure.  I see that _request() calls _refresh_JWT_token() to try to automatically renew the token.  I gather that isn't working.  I don't know how the token lifetime is set.

@bennybp: What's the plan to deal with the server timeout? Will that be substantially increased? Can calculations be split into separate requests that append?

Two pieces to the plan. Short term is to do batching client side. This can be done already. This is from memory:
from qcportal.utils import chunk_iterable

for entry_batch in chunk_iterable(new_entries, 1000):
    ds.add_entries(entry_batch)

I want to implement this automatically in the client, with progress bars.
Long term we could exploit the server-side job queue for this, but that will take some time.

Thanks, that worked!

The scripts are in #85.


Small refactor

What is the purpose of this?

What is the purpose of this?

Closing as no reply and not sure what the benefit of this is. If you decide to revisit this we can reopen the PR.

Closing as no reply and not sure what the benefit of this is. If you decide to revisit this we can reopen the PR.

@sashahilton00 the purpose is to make some code reusable to it's easier to build a offline cache feature for librespot at some point.


ARCH-1051: enables this to work with jwt auth login required middleware

Middleware enables DRF JwtAuthentication authentication class for
endpoints using the new LoginRequired permission class.
Enables a non-standard use of DRF, because DRF only supports returning
a 401 for unauthorized users, but this middleware allows a DRF endpoint
to redirect to login.
This can be used to convert a plain Django view which was using
@login_required into a DRF APIView, which is useful to enable our DRF
JwtAuthentication authentication class.
NOTE: This includes a breaking change that is unlikely to affect anyone
unless they subclassed JwtAuthCookieMiddleware, which switched from
using process_request to process_view so it would not run before
this new middleware.
ARCH-1051
The ecommerce PR that makes use of this middleware can be found here:
https://github.com/edx/ecommerce/pull/2533
Note: JwtAuthCookieMiddleware already includes a metric for whether or not the cookies are available, so we shouldn't need an additional metric.

@robrap This looks great!  I like how you cleaned it up and made it generic as well!  Awesome.


fix version retrieving of goframe for command version

Codecov Report
Patch coverage has no change and project coverage change: +0.06 :tada:

Comparison is base (9191003) 78.90% compared to head (56cbda1) 78.96%.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #2682      +/-   ##
==========================================
+ Coverage   78.90%   78.96%   +0.06%
==========================================
  Files         631      628       -3
  Lines       51817    51478     -339
==========================================
- Hits        40884    40648     -236
+ Misses       8911     8828      -83
+ Partials     2022     2002      -20

Flag
Coverage Δ

go-1.15-386
78.94% <ø> (+0.02%)
:arrow_up:

go-1.15-amd64
78.93% <ø> (?)

go-1.16-386
78.93% <ø> (-0.02%)
:arrow_down:

go-1.16-amd64
?

go-1.17-amd64
?

go-1.18-386
?

go-1.19-386
?

go-1.20-386
?

Flags with carried forward coverage won't be shown. Click here to find out more.
see 4 files with indirect coverage changes

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.


pickListValues not an array of picklistValues but single picklistValue

Hi,
When generating  apexdocs markdown it fails in:
https://github.com/cesarParra/apexdocs/blob/39c2a30d806580ffd226759139f70596ea727a51/src/core/reflection/sobject/parse-picklist-values.ts#L26
with error:
    return pickListValues.filter((each) => "fullName" in each).map((current) => current.fullName);
                              ^

TypeError: pickListValues.filter is not a function
    at toPickListValues (...\node-versions\v22.3.0\installation\node_modules\@cparra\apexdocs\dist\logger-DC5HNMQO.js:1946:31)
...

The point where it fails is for CustomObject (name and label replaced) where there is only 1 value inside valueSetDefinition:
<?xml version="1.0" encoding="utf-8"?>
<CustomField xmlns="http://soap.sforce.com/2006/04/metadata">
    <fullName>Test__c</fullName>
    <externalId>false</externalId>
    <inlineHelpText>Test</inlineHelpText>
    Test
    <required>false</required>
    <trackFeedHistory>false</trackFeedHistory>
    <trackHistory>false</trackHistory>
    <type>Picklist</type>
    <valueSet>
        <restricted>true</restricted>
        <valueSetDefinition>
            <sorted>false</sorted>
            <value>
                <fullName>TBD</fullName>
                <default>false</default>
                TBD
            </value>
        </valueSetDefinition>
    </valueSet>
</CustomField>

This dummy fix helps: (not the best solution though as there is probably more occurencies where xml nodes can be 0,1 or many and are returned as either array or single node)
        if (Array.isArray(pickListValues)) {
          return pickListValues.filter((each) => "fullName" in each).map((current) => current.fullName);
        }
        if ("fullName" in pickListValues) {
          return pickListValues.fullName;
        }

ApexDocs version: 3.7.0
Node version: 22.3.0
Platform: win-x64

Thanks @aranwe , I was able to reproduce. The issue is due to the way that the fast-xml-parser parses that data when there is a single node vs. many. Your solution should work, since there is already a validation in there making sure that the value key exists (if there are 0 nodes it won't be there).
Let me me put that in place and release a new version

Fix is in 3.7.1. Feel free to reopen if you see any issues!


Question: render row in different color

Hi,
I would like to render a row in different colors depending on values in the row. I tried this with a custom columnRenderer but then the spaces between the cells do not have the color. Is there a way to do this?

If you set your rows (tr) background to transparent with css, you could achieve that effect using a custom cell (td). Each cell in the row would have the same color value. Yes custom columnRenderer is the right example to follow.

Give that a try -- sounds like a good approach to me.

I will try that and report if it is working. Thanks

I think what we really want is a row renderer though where we could set the cell renderer -either custom or default for each cell - and have the ability to set a custom style for the entire row (the tr)

I try around since a few hours. Your first suggestion is not working as I need it.
Currently I try to write a row renderer. But I am still a little bit confused how to do it. I think it could be possible to just replace the "rowEl = (<tr { ...rowProps }> { cells } );" in the Row.jsx with a function which could be provided like it is done with the column renderer.

What if you created a row-renderer branch and then we can review your work - sounds like you have a solid idea

I just startet this. And will create a pull request

The pull request is there, so I will close this issue


What extension should we recommend for merged CSV and TSV files?

I think it would be helpful to recommend an extension. Some possibilities:

.csv, .tsv at end

<basename>.multi.csv, <basename>.multi.tsv
<basename>.merged.csv, <basename>.merged.tsv

.csv, .tsv first

<basename>.csv.multi, <basename>.tsv.multi
<basename>.csv.merged, <basename>.tsv.merged

Putting .csv/.tsv at the end has the advantage that the extension is recognized by programs such as Excel. However, putting .csv/.tsv first is more consistent with convention (e.g., .tar.gz -- first a set of files is archived into .tar format and then the .tar document is zipped into a .gz document).
@liebermeister @artgoldberg thoughts?

Use .multi.csv and .multi.tsv. No changes needed because these are already used.


:memo: Add docs for Markdown formatting of config descriptions

:warning: Should only be merged after settings-view has been incremented past v0.214.0. :warning:
Related to atom/settings-view#635

:heart:


Changes to make tsc compile

Hi, I wanted to make a typescript project using node-nats-streaming but when I tried to compile via tsc I got these errors

-It turns out proto is never used in index.d.ts so I deleted the import
-added 'declare' modified to the enum StartPosition declaration
-and in typescript you can't have optional properties in classes, so I removed the '?'.
closes #2

Coverage remained the same at 91.954% when pulling c142ad475f302acfb39fa5d5cb2f8b53f1052638 on bkim54:master into 6b2ca77ce8f04fa8e1eae6a6a5e5376f612d290a on nats-io:master.

Thanks for your contribution. I will be taking a look at this. For the SubscriptionOptions, I was trying to document the optional fields in the class to get feedback myself on internal fields. The fields are not directly accessible (the methods should be used to se their values).

I opened https://github.com/nats-io/node-nats-streaming/issues/4 to keep track of the verification I need to do.

@bkim54 I am getting errors related to node built-in references, and wondering how you went about it. Specifying --moduleResolution node doesn't seem to have an effect.

node_modules/nats/index.d.ts(2,25): error TS2307: Cannot find module 'events'.
node_modules/nats/index.d.ts(43,13): error TS2304: Cannot find name 'BufferEncoding'.
node_modules/nats/index.d.ts(78,41): error TS2304: Cannot find name 'Buffer'.
node_modules/nats/index.d.ts(79,42): error TS2304: Cannot find name 'Buffer'.
node_modules/nats/index.d.ts(106,41): error TS2304: Cannot find name 'Buffer'.
index.d.ts(2,25): error TS2307: Cannot find module 'events'.
index.d.ts(42,18): error TS2304: Cannot find name 'Buffer'.
index.d.ts(48,22): error TS2304: Cannot find name 'Buffer'.
index.d.ts(102,60): error TS2304: Cannot find name 'Buffer'.

@aricart did you include the typings for node?
typings install dt~kafka-node --global --save
and you have to provide the path to the typings
/// <reference path="./typings/index.d.ts" />

@aricart any progress on this?

All in @bkim54. Thanks for you interactive help in getting my env to work correctly so I could verify the changes. Give me a shout if you need/find anything else!


Method getSWRegistration is not defined on examples snippets

The Subscribing a user guide mentions thegetSWRegistration method multiple times. The method itself does not appear to be defined anywhere. Developers will need to know what it is supposed to do.

The code in that guide is here: https://github.com/gauntface/web-push-book/blob/master/src/demos/node-server/frontend/app.js#L33 Although looking through that, I think here is a much nicer way of doing this. Will explore later tonight.


Update README.md

added feature
What type of PR is this? (check all applicable)

[ ] 🚀 Added Name
[x] ✨ Feature
[ ] 🌟 stared the repo
[ ] 🐛 Grammatical Error
[ ] 📝 Documentation Update
[ ] 🚩 Other

Description
Feature: Automatically adding the contributers images in readme file and showing them up in more beautifull #4027
Add Link of GitHub Profile

github.com/manoj1749

please add hacktoberfest-accepted label to this pr


Fix page section save bug - empty field is saved as [Object object]

Happens in page edit/save

page add - converted to card layout

Fixed. Changed add/edit page to use card layout.


README.md: less brittle install command

fixes issue when installing on macOS x86_64:
Malformed Archive: url


Allow admins to specify arbitrary node types to try with unlisted_choice

Based on https://2i2c.freshdesk.com/a/tickets/1054.
The idea is to allow admins to be able to type in an instance type name, and land a pod on an instance of that type. This is very helpful for trying out new GPUs, etc. On GCP, we can probably couple this with node autoprovisioning and unlisted_choice.

I am going to timebox myself to see how complex this actually is though, especially as I think unlisted_choice shifts a lot of the burden onto the hub admin.

Okay please try to refine an estimation of the long term workload implications as well, that is my concern far more than the initial setup time.

I spent some time working on this and exploring the space. My primary motivation is that we should make our systems as self serve as possible, and particularly empower hub admins to explore things without needing us to perform actions on their behalf. Then we can get a nice virtuous loop of:
admin tries something -> doesn't work -> they iterate -> works well -> we roll this out to people
Without us having to be involved throughout the process. I think this has worked well in unlisted_choice, and I think this would be a useful thing to explore here as well.
My primary concern was that last time we tried node autoprovisioning it was kinda janky! However, we also tried it in a far more expansive way, and this time I was exploring it in a far more constricted way.
This time, I basically wanted this UI to work for hub admins

It's clearly marked as a fairly advanced feature, and if things break here it's on them. Only admins should be able to land on nodes created this way (not non-admin users), and it shouldn't affect non-autoprovisioned nodes. Given the amount of time I spent when sorting out https://github.com/pangeo-data/pangeo-docker-images/issues/387 for example, I think this will long term reduce amount of time everyone has to spend on trying out GPU / accelerator stuff too. Same for trialing ARM instances.
Anyway, in this more focused fashion, node autoprovisioner seems to be doing a bit better. I could get it to spawn me an e2 instance or an n2d instance (so cheaper AMD instances could be trialed), but nothing with GPUs or any other accelerators. So I'm going to park this for a bit and try again, probably next week. The diff was fairly small!

Autoprovisioning is apparently influences the cluster autoscaler even if working to schedule pod that doesn't need it to create a new node pool. That hindered scaleup as reported for LEAP in https://2i2c.freshdesk.com/a/tickets/1074 by "max cluster memory limit reached".

There are currently no node pools created by the autoprovisioning system, so I'll go for a disable for the moment @yuvipanda.

When toggling various options, its not obvious if the change is quick or similar. I learned that changing the settings of "node auto-provisioning" took around ~30 minutes, which I think may be the amount of time it takes to do a k8s control-plane upgrade. It makes sense that it would align, because they are influencing the cluster autoscaler they manage in the k8s control-plane.
I wonder if changes to that forces the k8s api-server to restart as well, then a zonal cluster would get a k8s api-server outgage making changes to node auto-provisioning as well.

It seems that enabling/disabling node auto-provisioning is something that requires restarting the control plane. For a regional GCP cluster this takes ~25-30 minutes I think and shouldn't cause disruptions, but it would for zonal clusters.

This machine has been failing to scale down, I think because of a lack of taints made it get system pods scheduled on it. I cordoned it and deleted some pods from it, hopefully it will get scaled down.
gke-leap-cluster-nap-e2-highmem-16-19-09f720d5-j254   Ready    <none>   5d5h    v1.25.10-gke.2700

Non-terminated Pods:          (13 in total)
  Namespace                   Name                                                              CPU Requests  CPU Limits  Memory Requests  Memory Limits  Age
  ---------                   ----                                                              ------------  ----------  ---------------  -------------  ---
  kube-system                 calico-node-kdd2r                                                 100m (0%)     0 (0%)      0 (0%)           0 (0%)         2d22h
  kube-system                 fluentbit-gke-cqcz5                                               100m (0%)     0 (0%)      200Mi (0%)       500Mi (0%)     5d5h
  kube-system                 gke-metadata-server-2jrzs                                         100m (0%)     100m (0%)   100Mi (0%)       100Mi (0%)     5d5h
  kube-system                 gke-metrics-agent-jzx87                                           6m (0%)       0 (0%)      100Mi (0%)       100Mi (0%)     5d5h
  kube-system                 ip-masq-agent-bff8t                                               10m (0%)      0 (0%)      16Mi (0%)        0 (0%)         5d5h
  kube-system                 konnectivity-agent-5db5c757c7-6pg94                               10m (0%)      0 (0%)      30Mi (0%)        125Mi (0%)     5d3h
  kube-system                 konnectivity-agent-5db5c757c7-mlwxq                               10m (0%)      0 (0%)      30Mi (0%)        125Mi (0%)     5d3h
  kube-system                 kube-proxy-gke-leap-cluster-nap-e2-highmem-16-19-09f720d5-j254    100m (0%)     0 (0%)      0 (0%)           0 (0%)         5d5h
  kube-system                 metrics-server-v0.5.2-56d9dd6d95-kb6z4                            50m (0%)      45m (0%)    125Mi (0%)       375Mi (0%)     21h
  kube-system                 netd-zfq6f                                                        0 (0%)        0 (0%)      0 (0%)           0 (0%)         5d5h
  kube-system                 pdcsi-node-9zjcm                                                  10m (0%)      0 (0%)      20Mi (0%)        100Mi (0%)     5d5h
  support                     support-cryptnono-vnf7n                                           5m (0%)       800m (5%)   100Mi (0%)       2Gi (1%)       5d5h
  support                     support-prometheus-node-exporter-tptcl                            10m (0%)      10m (0%)    30Mi (0%)        30Mi (0%)      5d5h

There is an e2 node that keeps running, and I've failed to understand why the cluster-autoscaler drained a core node pool causing an outage in #3363 - I suspect it could be related to the use of the cluster-autoscaler specific to node auto-provisioning enabled though.

Sorry @consideRatio I thought you already had it disabled! Yes, let's definitely disable it.

I'm re-applying terraform from clean master so node autoprovisioning goes away.

Done.

Closed as wontfix, and i've already communicated this to LEAP.

Thank you very much for helping deal with the issues that came out of this, @consideRatio. In the future, if I try something with node autoprovisioning (which still has very good promise), I will make sure to do that on a temporary dedicated cluster.


How to use only blocks, not vm, etc. We want to render our own interface, manage rendering by ourselves, how to translate the built block into code, I hope to get help.

Expected Behavior
Please describe what should happen
Actual Behavior
Describe what actually happens
Steps to Reproduce
Explain what someone needs to do in order to see what's described in Actual behavior above
Operating System and Browser
e.g. Mac OS 10.11.6 Safari 10.0
How to use only blocks, not vm, etc. We want to render our own interface, manage rendering by ourselves, how to translate the built block into code, I hope to get help.

scratch-blocks does not have "block to js (or other code)" feature, if that's what you mean.

Blockly (github.com/google/blockly) does blocks to code without a VM, and is what scratch-blocks is forked from.

Blockly（github.com/google/blockly）在没有VM的情况下执行代码块，这是从头开始的。

Google's block is not elegant enough, scratch-block is very nice, we share your style, but we need to render our own defined interface, is there any way to read the valid code block in the workspace, is the problem I encountered, thanks your response

如果这就是您的意思，那么便笺本没有“阻止js（或其他代码）”功能。

如果这就是您的意思，那么便笺本没有“阻止js（或其他代码）”功能。

How to read the workspace code block and bind custom events to make people move？

@rachel-fenichel They took the feature away when forking
@King-whb That's where you use VM! See VM's /blocks/

@ rachel-fenichel他们在分叉
@ King-whb时取消了该功能，这就是您使用VM的地方！参见虚拟机的/ blocks /


Support 5D and 6D tensors in broadcast sampler

Description

Support 5D and 6D tensors in the broadcast output sampler.
https://github.com/tensorflow/tfjs/issues/961

For repository owners only:
Please remember to apply all applicable tags to your pull request.
Tags: FEATURE, BREAKING, BUG, PERF, DEV, DOC, SECURITY
For more info see: https://github.com/tensorflow/tfjs/blob/master/DEVELOPMENT.md

This change is

@dsmilkov I was wondering if I should close this?  Looks like the code I changed is going away in #1457

Sounds good to me, thanks!


Readme Project Links are all messed up

Many of the Project Titles in the readme are directly to incorrect URLs.

have you figured out which one ?
i could fix them if you could point out.


Type of loading isn't working

In javascript (not using typescript) vsLoading type instance not working

Can you describe more clearly? send me the code you use

loadingInstance = VsLoadingFn({
type: 'wave',
color: '#5b3cc4',
background: '#1e2023',
});
    In this code a loading overlay is coming but wave is not coming in the loading

loadingInstance = VsLoadingFn({
      type: 'wave',
      color: '#5b3cc4',
      background: '#1e2023',
   });

please try waves instead of wave

yes, I have tried But still it's not working,

thanks, let me check again

import { VsLoadingFn } from 'vuesax-alpha'

let loadingInstance;

export const loadingService = {
    show: function(){
        loadingInstance = VsLoadingFn({
            type: 'waves',
            color: '#5b3cc4',
            background: '#1e2023',
        });
    },
    hide: function(){
        loadingInstance.close();
    }
}

This is my  loading service and I am using it in
created() {
    loadingService.show();
  },

It is just showing the overlay of the background color I have specified

I just tested your code, it still runs normally, the problem is because the background and color are too similar

Yeah, my fault. Thank you

Do you see any warnings appearing in the console when using LoadingFn?


Feature request : Add --verbose flag

When I run ambs in one of my folders, it freezes on a file but I can't tell which one because there is no --verbose (or --debug) flag that makes amber more chatty.

I've added --verbose option.


Android emulator loses connection to debugger and becomes unresponsive

To reproduce:

Fire up a Genymotion emulator
react-native run-android on your project
Attach chrome debugger
Put an error in javascript, for example returns instead of return
Refresh your emulator (Cmd M, Reload)
Fix the error in your code
Refresh your emulator (Cmd M, Reload) again
Emulator will display dialog that says "Please wait.. connecting to remote debugger"
There is no way to exit this state, except to close and reboot the emulator

Errors caught in the debugger in this situation are:
GET http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false 500 (Internal Server Error) debuggerWorker.js:18 Uncaught NetworkError: Failed to execute 'importScripts' on 'WorkerGlobalScope': The script at 'http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false' failed to load.messageHandlers.executeApplicationScript @ debuggerWorker.js:18onmessage @ debuggerWorker.js:33
I use Genymotion, usually test on APIs 16 & 21 which have both experienced this issue.
I am running React Native version 0.20.
I am running on a Mac.

I've heard about this, might be something that got broken between 0.19 and 0.20. Does anyone know the root cause?

Confirmed. Very frustrating.  You can press the hardware buttons to go to say the home screen so the device is responsive, but the "Connecting to the remote debugger' popup stays on top of everything so you click click anywhere.

Seen this quite frequently on 0.17 as well

This happens on 0.21, 0.22 with stock emulator, with Genymotion.

Confirmed Ubuntu/Lunix with RN 0.21 and 0.22 and Genymotion

I've upgraded to latest and debug in chrome was not working. So I created a new app from scratch using react-native-cli 2.0. Debugging was working. So I compared all android files for things missed by the upgrade script.
I've found the following differences:
   allprojects {     repositories {         mavenLocal()         jcenter()         maven {             // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm             url "$projectDir/../../node_modules/react-native/android"         }     }   }
android/app/build.gradle the compile version was still showing 0.18
dependencies {     compile fileTree(dir: "libs", include: ["*.jar"])     compile "com.android.support:appcompat-v7:23.0.1"     compile "com.facebook.react:react-native:+" }
I rebuilt the app, now Debugging works again.
Hope it helps. Santiago

+1 on this issue
also what sesteva says, there are some issues with upgrading react-native versions and what gradle thinks is possible.

I get this in chrome console:
debuggerWorker.js:18 Uncaught NetworkError: Failed to execute 'importScripts' on 'WorkerGlobalScope': The script at 'http://localhost:8081/index.android.bundle?platform=android&dev=true&hot=false&minify=false' failed to load.
I'm using the android emulator and it also gets stuck on that message: Please wait...Connecting to remote debugger.
How to stop this without shutting down all processes?

I thought this was fixed but it's still a problem.
The issue went away a while ago for me, but now it's back. Maybe it has something to do with promises? I started using AsyncStorage last week. No errors come up, although I do sometimes have the unhandled promise rejection for no apparent reason sometimes.

Don't even have asyncstorage, blank project with only react-native-maps and it does it here and then. Very annoying to recover from.

the fastest way to recover I found out is to ctrl+c then [up], [enter] the packager. This way the app crashes instantly and I can reload.
Any other way makes android hang for ages.

@ThaJay could you expand what you mean by [up], [enter] the packager? I'm having this problem as well (and also wonder if it has something to do with promises)

I just meant running the command again in your terminal.
But in the newer versions it seems you can just press the back button on device or emulator to cancel the loading modal so you can open the dev menu again.

same issue
genymotion and real device
windows 10 and osx 10.11.6
react-native 0.33

This issue is a real bummer. Having remote JS debugging and live reloading both enabled causes constant issues because of this -- if you save a file with a syntax error everything breaks and you have to kill and reload the app manually.

Press the back button on device or emulator to cancel the loading modal doesn't work for me using 0.34.
The fastest way to recover I found to kill the app:
adb shell am force-stop com.my.app.package
where com.my.app.package is the package name

i hope this can help you,it help me solution this problem.
[(http://stackoverflow.com/questions/41088268/conditional-rendering-error-in-react-native)]

Closing this issue because it has been inactive for a while. If you think it should still be opened let us know why.

I still have this issue, where if I enable debug remotely and uses react native debugger at jhen0409/react-native-debugger, the app in genymotion just basically stops working.


Lack of support for half precision type in linear algebra operators

System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): No
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): CentOS 7
Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device: N/A
TensorFlow installed from (source or binary): Binary
TensorFlow version (use command below): v1.9.0-0-g25c197e023 1.9.0
Python version: Python 3.6.5
Bazel version (if compiling from source): N/A
GCC/Compiler version (if compiling from source): N/A
CUDA/cuDNN version: 9.0
GPU model and memory: Tesla V-100 16160MiB
Exact command to reproduce:
Minimal example to reproduce the issue

import tensorflow as tf
from tensorflow.python.ops import gen_linalg_ops

a = tf.placeholder(tf.float16, shape=[2, 2])
gen_linalg_ops.qr(a)

Problem
There seems to be no support for float16 type in linalg_ops.cc at all. Is there any reason as to why that is the case? Or a way around it?
I have run into this issue when trying to use keras with float16 (by editing .keras/keras.json), sequential model with GRU cells. Code included for completeness:
import tensorflow.keras as keras

model = keras.Sequential()
model.add(keras.layers.GRU(128, recurrent_dropout=0.75, input_shape=(200, 4)))

Log
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File ".../python3.6/site-packages/tensorflow/python/ops/gen_linalg_ops.py", line 1494, in qr
    "Qr", input=input, full_matrices=full_matrices, name=name)
  File ".../python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 609, in _apply_op_helper
    param_name=input_name)
  File ".../python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 60, in _SatisfiesTypeConstraint
    ", ".join(dtypes.as_dtype(x).name for x in allowed_list)))
TypeError: Value passed to parameter 'input' has DataType float16 not in list of allowed values: float64, float32, complex64, complex128

This feature request mirrors the question asked in stackoverflow

I don't believe there is any fundamental reason to not support it, would just have to make sure that the kernel implementations work for float16.
Marking as "Contributions Welcome", as we'd welcome PRs updating the op definitions and adding unittests.
CC @rmlarsen

I am new to open source. Can someone guide me to help me solve this issue. I have good amount of c++ knowledge and practice.
Thank You.

Should float16 support be added to all ops in linalg_ops.cc or just the qr function?

Ideally all of the ops in linalg_ops.cc unless there's a good reason not to.

Looking into it


ansible-launcher messes up with the user's terminal colorscheme

Before running ansible-launcher:

Then run ansible-launcher and immediately quit:

In order to restore the colorscheme I had to restart the terminal session.
I was using Windows Terminal and running ansible-launcher from an SSH connection to my Linux working laptop.

@elyezer Try running with --osc4 false this will disable ansible-navigators ability to change the terminal colors, I wonder if the terminal if misrepresenting it's osc4 ability as this issue doesn't exist on xterm

@elyezer anything to report here?

I will have to try with the updated version. Will try to do it tomorrow. Sorry for the delay.

@elyezer thx, please keep us posted

With the --osc4 false it works as expected. Also it seems to use the same colorscheme that it uses when --osc4 true.
I found the issue while using Windows Terminal btw.

buried in the code, there is theme support, which is not user accessible yet (maybe v2), in order to do that we need the color changing support.
I suspect your terminal is misrepresenting it's OSC4 capability, which is why the colors weren't restored
The reason it still looks same, is the theme colors are mapped to your terminal colors, so it's going to be close with 256 color support, once you get to 16 or 8, the "best" color might not be a great match.

If you are interested in where all this happens, LMK.  I didn't want to flood the issue with code link, but it's some neat stuff IMO

Now covered in the FAQ https://github.com/ansible/ansible-navigator/blob/main/docs/faq.md


Ui modify

Added in calendar view as well as module

You need to create PR to your own organization repo, not semester fork. Closing it.


Help?

Hey
So I'm new to this whole thing.
I downloaded the PokemonGoMap-Win.exe file, because I'm on Windows 10
I don't know if I have to download anything else in there too.
After I did that, I got an API key online following their directions and then I got the address of where I am. However, every time I search for Pokemon the map stays blank for about a minute and then at the top it says "Possible Ban" in red.
Did I screw this up somehow? I'm using a google account.
Thanks!

The account doesn't work until you got past the tutorial stuff in the game.
I believe the program doesn't skip through it.


When deleting on a new line cursor fails to move to last indentation

VSCode Version:1.1.1
OS Version: Linux 4.4.0-22-generic

When hitting delete, and the line is blank, cursor should move back to last tab-stop
Steps to Reproduce:

Create some code blocks, with each line indented
Press enter
Press backspace

Issues: cursor moves back only single character, the expected behavior is to move back to previous indentation.

This will come out of the box with the May release thanks to @outcoldman in PR #5423

Nice work :+1:  thanks for getting this in!


fix(enterprise management): add examples

PR summary

PR Checklist
Please make sure that your PR fulfills the following requirements:

[x] The commit message follows the Angular Commit Message Guidelines.
[x] Tests for the changes have been added (for bug fixes / features)
[ ] Docs have been added / updated (for bug fixes / features)

Current vs new behavior

Does this PR introduce a breaking change?

[ ] Yes
[ ] No

Other information

@Andras-Csanyi @pyrooka Rather than add comments similar to the other PRs, I instead just pushed a commit with the various changes that I would have commented on.   The changes mainly focused on:

removing unused variables
imroving the names of variables that will be visible in the API reference
using string literals for name-type values so they will be visible in API reference
added labels to each test block
I apologize for being so prescriptive, but I feel very strongly about the need to provide request examples that are as clear as possible to users and I think the changes I made are an improvement in that area.   I hope you both understand where I'm coming from.

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.1 out of 2 committers have signed the CLA.:white_check_mark: padamstx:x: Andras-CsanyiYou have signed the CLA already but the status is still pending? Let us recheck it.

:tada: This PR is included in version 0.18.8 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Add gethostname support to Redox module

We need this for hostname support in Ion shell.

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @alexcrichton (or someone else) soon.
If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.
Please see the contribution instructions for more information.

@bors: r+

:pushpin: Commit d650166 has been approved by alexcrichton

:hourglass: Testing commit d6501661161522a3ad6272f17695a7b325f356e1 with merge 6acb091b5e317e8eb887801ef3d7249ebbbc4682...

:sunny: Test successful - status-appveyor, status-travis
Approved by: alexcrichton
Pushing 6acb091b5e317e8eb887801ef3d7249ebbbc4682 to master...


1.3.0 missing css in production/css

The custom css is now missing from production/css

Yup, it is now move on build folder since build system was introduce

Sorry for the late response, but using the build folder with webpack is not working. The issue is that the images directory is referenced by ../images but there is no build/images directory in the npm package. If i copy images from production/images to build then everything works fine.


[TASKS-771] Support gauge tags

This interface is intended to work similarly to the MetricProducer
interface, but with Gauges. It is designed to enable sending multiple
gauges of the same name, but with different tags and values.
The MetricProducer interface has been left in place for
backwards-compatibility, but this should be considered the new way to
emit gauge metrics on a regular interval.

I opened this PR prematurely and realized after working on this intermittently that this wasn't ready yet 😅 . Tests incoming!


CIC double doors are all access.

Description
All the CIC double doors are all access instead of command locked.
Reproduction
Attempt to open any CIC double door without an ID.
Screenshots
N/A
Additional context
Relevant to - #2393

Dupe of #3737 (all doors are effected)


todo: display fencer names instead of ids in poules

This may require display_poules() to be a method of Event rather than Round, which is counter-intuitive.

Could pass in the parent object to the round, so it has an awareness of the fencers (and their names)?

I ended up getting fencers' names using a method of the parent object which returns a fencer object corresponding with a particular fencer id.


On device activity not working

it's stopped working today. Is anybody else suffering this issue?

It's never worked for me, I'm on 5.0.8.
I'm hoping this isn't going to be a cursed node, where it's perpetually forked as one dev after another stops bothering with it after working on it for a few months.

it came to working a few hours later. thanks

For some there are outages all the time. For me personally it always works. Just checked my logs, and there's plenty of activity throughout the day.
I think it's some websocket connection that is dropped (unnoticed), however unfortunately I don't have time to actively debug this at the moment.


completed user and user_relationships migrations and models

@mpieces @nicoto @andrewdonato @amjacobowitz @tisderek

@mpieces @nicoto @andrewdonato @amjacobowitz @tisderek


Latest mk2utc.clk differs from version in this repo

Assume tempo2 repo is more current.

Meerkat (TEMPO2)     2023-12-04 18:55:35.017 - Validation failed: New version of T2runtime/clock/mk2utc.clk MJDs differ from old version where they overlap in 597 places

Closed by #12


Documentation include "user images"

The documentation in the Wiki allowed editors to paste images from screenshots, etc. This resulted in the images being uploaded to https://user-images.githubusercontent.com. We need to move all these images in this repo.
Definition of Done:

[x] Come up with a logical naming convention / filesystem structure for images and add it to the Style Guide
[x] All images in the documentation are stored in /docs/images, possibly within a tree file structure
[x] Check for any other content (other than YouTube videos) that may be hosted outside the documentation

The images and videos have been migrated.


Add NL (Dutch) language support

Translated ‘tip’ in a way that it can be used for both ‘tip’ and ‘present’ by using the word ‘gift’. I’ve used Lightsats most of the times as birthday present, and then ‘tip’ is incorrect.
In 'items.json':

Are "nonCustodial" and "custodial" used in the application?
Can these be short sentences, as the exact translation 'niet custodiaal' won't mean anything to a common person?

@Wenze thanks very much for the translations!

Are "nonCustodial" and "custodial" used in the application?
I think they are no longer shown. We used to show which wallets are custodial and non-custodial, but we have simplified the interface and instead order the wallets based on a number of factors (this being one of them). So no need to translate this.

@Wenze you will be able to test the translations at https://lightsats.fly.dev/ (our dev site) once the github action has finished running.

@rolznz I ran the user workflow and everything looks good.
The only open question is the one I had in the initial pull request. I didn’t see the string “nonCustodial” so it doesn’t seem to be used. Therefore this can be pushed to production from my side.

@Wenze I replied regarding that above but the formatting was a bit broken.
I think custodial/non-custodial are no longer shown. We used to show which wallets are custodial and non-custodial, but we have simplified the interface and instead order the wallets based on a number of factors (this being one of them). So no need to translate this.

@Wenze I replied regarding that above but the formatting was a bit broken.
I think custodial/non-custodial are no longer shown. We used to show which wallets are custodial and non-custodial, but we have simplified the interface and instead order the wallets based on a number of factors (this being one of them). So no need to translate this.

All clear, thanks.


Improve sensitivity of address detection

As a Rabby user, i want to see my wallet being identified as quickly as possible, so that I can understand what data my wallet is exposing about myself.
Rabby is making quite few requests via the wallet RPC provider. So currently, it seems that it's not making (many) eth_getBalance but it does make eth_getTransactionCount requests e.g. when opening app.uniswap.org. This request identifies a wallet in the same way as eth_getBalance does and thus it should trigger the frontend to identify the address in the payload as my wallet.
A typical response looks like this:
[
  "0x5a35455c3534fD0B652667e6a94a60E3e9A56546",
  "latest"
]

Also eth_estimateGas should be added. The relevant field in the json is the from field. A typical response looks as follows:
[
  {
    "from": "0x5a35455c3534fD0B652667e6a94a60E3e9A56546",
    "to": "0xf5581dfefd8fb0e4aec526be659cfab1f8c781da",
    "data": "0x095ea7b3000000000000000000000000c36442b4a4522e871399cd717abdd847ab11fe88ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"
  }
]

To read: https://medium.com/hoprnet/derp-example-1-metamask-linkability-6b26ba42072f

@SCBuergel can you please add here a flow on how we can get eth_getTransactionCount or eth_estimateGas?


Add monitoring endpoint

Currently we have no overview on what Faucet is doing, e.g. how many transactions it sends / minute, or even if it is running at all. This needs to be changed to work like Agora (prometheus endpoint) and be added to our Grafana.

Done


Search still broken when using fix

Thanks for an all-around excellent theme!
I find myself with a broken search function. The problem seems to be in search.rake as I'm getting the undefined local variable or method amp' for main:Object` error. I'm using 0.2.7.
I know this might be construed as a duplicate, but I've had a look at #80 and applied the fixes to escape the single quotes but I'm still getting the error. Additionally, the DevTools console there's an error on line 65 in just-the-docs.js where it parses the response. From what I can see, this is because search.rake fails and the response is empty.
Any idea why the accepted escaped single quote fix isn't working? I've been banging my head against this for hours. Thanks!
To reproduce:
Run bundle exec just-the-docs rake search:init. Output:
/Users/disastrid/.rvm/gems/ruby-2.4.1/gems/just-the-docs-0.2.7/lib/tasks/search.rake:17:in `block (3 levels) in <top (required)>': undefined local variable or method `amp' for main:Object (NameError)
Did you mean?  cmp
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/just-the-docs-0.2.7/lib/tasks/search.rake:11:in `open'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/just-the-docs-0.2.7/lib/tasks/search.rake:11:in `block (2 levels) in <top (required)>'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/task.rb:273:in `block in execute'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/task.rb:273:in `each'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/task.rb:273:in `execute'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/task.rb:214:in `block in invoke_with_call_chain'
	from /Users/disastrid/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/monitor.rb:214:in `mon_synchronize'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/task.rb:194:in `invoke_with_call_chain'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/task.rb:183:in `invoke'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/rake-12.3.3/lib/rake/application.rb:160:in `invoke_task'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/gems/just-the-docs-0.2.7/bin/just-the-docs:15:in `<top (required)>'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/bin/just-the-docs:23:in `load'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/bin/just-the-docs:23:in `<main>'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:15:in `eval'
	from /Users/disastrid/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:15:in `<main>'

Augh, some of this seems to have been a caching issue. I am now generating valid json but am still getting the same errors if I run the rake file on the command line as above. Though the json file appears to be fine the search function isn't working, but I think it might be unrelated?  Happy to hear any insight though, the search function was previously fine and I'm not sure why it's broken now.

The search rake is not necessary.
You do not have to generate the search-data.json yourself, just use the theme and enable search in the _config.yml.
This sentence from the documentation is wrong:

If you don’t run this rake command or create this file manually, search will not work (or it will use the search index data from this docs site, not your site’s content).

Happy to hear any insight though, the search function was previously fine and I'm not sure why it's broken now.

Were you able to figure it out? I'm having the exact same issue. And I double checked and did as @SgtSilvio mentioned. That did not work online, but did work on my local server. Which is odd. For now I'm just manually copying and pasting the search-data.json created by my local server by finding it in the Network tab of the inspector and modifying it to work online.


Opened DMG has application misaligned.

When I create my DMG and open it, the icon is misaligned. How would I fix that, please?
- uses<EMAIL_ADDRESS>       with:
         name: 'shackleton'
         srcdir: 'build/macos/Build/Products/Release/shackleton.app'

(It's a Flutter app if that makes any difference. The image is in there, just way over to the right!

@hobleyd
I have a question, I would also like to use this action.
Does this action automatically upload the DMG, so that you can then also Downloaden in the area of the action?

     - uses<EMAIL_ADDRESS>       with:
         name: 'shackleton'
         srcdir: 'build/macos/Build/Products/Release/shackleton.app'
     # Upload generated dmg to the artifacts.
     - uses: actions/upload-artifact@v1
       with:
         name: shackleton.dmg
         path: shackleton.dmg

@hobleyd
Thank you, so if I understand correctly I do not have to specify a path from the DMG when uploading?

I certainly didn't need to.

In order for the icon to be placed correctly an additional parameter must be passed to create.dmg:
--icon Name.App 200 185


CHAOS-5129 Update chaos exp with API

Update chaos exp with API

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://6638ff10ee9376f974591ed3--harness-developer.netlify.app

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://663c56c2c30aca59e1a2c630--harness-developer.netlify.app


Ar ux buttons to move objects

Can somebody make some buttons to move objects foward backward and turn left and right.
Thanks

Did you really mean to open a PR here? Also, you can implement buttons like this on your website with a little bit of HTML; just use the onClick method to change the camera-orbit and camera-target attributes as desired.


Subresource integrity

See https://developer.mozilla.org/nl/docs/Web/Security/Subresource_Integrity. Since a lot of websites use these buttons, github-buttons is an attractive target: if subresource integrity is not implemented and github-buttons gets compromised, a lot of sites will serve malicious content.
A drawback of this is that it's no longer possible to update existing code transparently.

If you're afraid of this, you can opt to use the versioned npm release hosted on unpkg.com instead of the always up to date buttons.github.io. E.g.
<EMAIL_ADDRESS>You can add compute the hash and add integrity yourself.

I'll close this issue as using npm release hosted on unpkg.com can solve your problem.
By the way, here is what I do to reduce the chance of being compromised if you're interested:

For any commit, it is required for dist to be updated and in sync with src. CI would always rebuild the dist and check against the status of commit. If dist and src are out of sync (e.g. someone trying to sneak malicious code into the minified js), CI would catch that immediately. It's a little bit of headache for PR as only rebase merging would be allowed, but there are not many PRs anyways.
There is no possibility of compromised version of dependencies being installed by a downstream project, because there is no dependencies in this project.
This project do have devDependencies. Because the CI enforces dist to be always updated, any attempt of compromising devDependencies to inject malicious code in to dist would show up in the diff. I do manually check the diff of dist for every single commit. The only thing that I cannot really check every time is the minified js, but the only chance bad things may happen to it is that rollup or terser get compromised. It's very very unlikely, but if it ever happens it would be a disaster and for sure this project won't be the only victim.
Dependencies are installed via npm ci in CI. It enforces the package-lock.json that only exact version is installed, so that it eliminates the risk of a compromised patch version get automatically picked up by npm install. The update of dependencies is always done locally via a local build to update package-lock.json. Normally update devDependencies won't even change dist. I always manually check dist if there is any change due to updating because it can be suspicious.
No direct commit is made to buttons.github.io. Changes are made to the source repo ntkme/github-buttons-app, and then CI would build the change and update buttons.github.io. Again, the weakness here is dependencies. However, with node ecosystem being so complex today, the best anyone can do is to use best judgement to pick well known and well maintained dependencies to trust.
I do my best to keep my credentials safe.


feat: spec-manta

Hi i tested out with the script and it is working i added the test result as screenshot

Union also working


Update module github.com/stackitcloud/stackit-sdk-go/services/loadbalancer to v0.8.0

This PR contains the following updates:

Package
Type
Update
Change

github.com/stackitcloud/stackit-sdk-go/services/loadbalancer
require
minor
v0.7.0 -> v0.8.0

Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.

[ ] If you want to rebase/retry this PR, check this box

This PR has been generated by Renovate Bot.

Done in #177


undefined is not an object (evaluating React.PropTypes.oneOf

I'm getting this error with
react: 15.4.1, react-native: ^0.39.2, react-native-vector-icons: ^3.0.0
Saw there was an issue closed about the same error and the solution was to update the package, however I'm in the latest.
Thanks in advance!

Same with me ..

@caroaguilar: Is this with a new project or did you recently upgrade? Can you confirm that the version in node_modules folder corresponds to whatever version you have in package.json.?

Works for me now after re-installation of react-native-vector-icons. probably did not install properly the first time. I am using the same setup as @caroaguilar :
"react": "15.4.1",
"react-native": "0.39.2",
"react-native-vector-icons": "^3.0.0",

@samothx Yep, that's what I suspected. Closing this, reopen if you can demonstrate that this happens on a fresh project.


Explain ASCII

Codecov Report

Merging #263 (74f3006) into master (5a41aae) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master     #263   +/-   ##
=========================================
  Coverage     67.80%   67.80%
  Complexity      599      599
=========================================
  Files            97       97
  Lines          2078     2078
  Branches        217      217
=========================================
  Hits           1409     1409
  Misses          600      600
  Partials         69       69

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 5a41aae...74f3006. Read the comment docs.


PYIC-3796: Add consolidated CRI return lambda

Proposed changes
What changed
Merge lambdas and create 3 services:

CriApiService
VcStoringService
CriCheckingService

Why did it change

To simplify things in the long-run

Issue tracking

PYIC-3798

Checklists
Environment variables or secrets

[ ] Documented in the README
[ ] Added to deployment repository
[ ] Added to local startup repository

Other considerations

[ ] Update README with any new instructions or tasks

You'll also need to plumb this in to the CRI return API, so it actually gets called.


Module 1 Exercise 2 [MARVIN AYEH]

Please "drag & drop" exercise 2 file below.

Please UPDATE THE TITLE of this "Issue" in the title bar above with your name.
M.A_W4M1_E2.docx

Excellent work!


TypeError

Hi, I'm following your work!
When I run the 'deepncm_do.sh', I come across the following TypeError
TypeError: Failed to convert object of type <class 'tensorflow.python.data.ops.dataset_ops.PrefetchDataset'> to Tensor. Contents: <PrefetchDataset shapes: ((?, 32, 32, 3), (?, 100)), types: (tf.float32, tf.float32)>. Consider casting elements to a supported type.
Can you help me fix it?
Thanks!

Hi, thanks for your interest in DeepNCMs.
Unfortunately, I'm not able to reproduce this error myself, please try (ensure) the following:

Verify Tensorflow is at version 1.6.0 (that is the version it is tested with, will clarify that)
Initialise the submodule (git submodule update --init)
Download and install CIFAR10 in the following directory: /tmp/deepncm/cifar10_data
Run a single experiment, eg python cifar10_deepncm.py --dataset cifar10 --ncmmethod softmax -l 0.05

If this works, I will update README and documentation accordingly. I probably hard coded the data directory somewhere. Best

Thank you for your kind suggestions!
My software Environment: python 2.7, and Tensorflow 1.4.0.
When  I upgraded Tensorflow from 1.4.0 to 1.6.0, this issue was solved with the following modification:
resnet_ncm.py:113 ncm['method'].casefold() is replaced with ncm['method'].lower().
Thanks!

Will add that to the readme. Thanks


Question: labels support and relative address

Does this project have plans to support labels and rel address like nasm?

We do want to support labels at some point and we have talked about how we'd want to implement it, but currently nobody is dedicated to work on this project. We're more than happy to help and merge any PR, if you happen to be able to spare some time on this.
The high level idea was to create a map of "label"-"address" while the first pass of assembling.

Add a node to that map, whenever a label is parsed.
if an instruction with label is parsed, check this map and calculate the relative offset, if the label is already in the map, if not, assemble with 0x0  as the offset and create an entry in a back patch list.
at the end, traverse the back patch list, and and back patch all the necessary instructions.

@dderjoel Thank you for reply. I can have a try on this idea in free time.


Unrarx 2.2 replacement

Changes to a cask
Editing an existing cask

[x] Commit message includes cask’s name (and new version, if applicable).
[x] brew cask audit --download {{cask_file}} is error-free.
[x] brew cask style --fix {{cask_file}} left no offenses.

###Message
UnRarX's website has been dropped and it is no longer able to be installed using brew install Caskroom/cask/unrarx I have repaired this by hosting on my own personal website until I am able to get in touch with the author and be able to see if I can assist him with hosting costs.

I have repaired this by hosting on my own personal website until I am able to get in touch with the author and be able to see if I can assist him with hosting costs.

Thank you for the effort, but no can do. It’s not that I don’t trust you, but there’s no reason any of our users should. We take official links, only.


How to reinstall?

I deleted the installed file in storage folder after install but I want to reinstall to check some functions.
Its giving me 404. Please help.

If the tables are already there you will get 404 error.
You need to delete the tables from your database.


RemoteTaskRunnerConfig/HttpRemoteTaskRunnerConfig equals() and hashCode() inconsistency

HttpRemoteTaskRunnerConfig extends RemoteTaskRunnerConfig and adds more fields, but doesn't override equals() and hashCode(). While RemoteTaskRunnerConfig uses getClass() comparison in equals(), that breaks the substitution principle.

I don't think it is universally accepted that strictly adhering to the substitution principle in Java is a good thing. Using getClass has a benefit: x.equals(y) may return true improperly if y's class extends x's class and adds more fields. They are really not equal in that case (y, with more fields added, is really a different kind of thing from x). For this reason I usually use getClass rather than instanceof when writing equals methods.

I acknowledge that this is controversial, though: https://www.artima.com/intv/bloch17.html

The approach when there is no such controversal class extensions, and composition is used instead, leaves no surprises. As far as I understand, we use extension because we don't want to add another level of nesting in configs. I wonder if there is an option to "flatten" such nested entities in Jackson.

The approach when there is no such controversal class extensions, and composition is used instead, leaves no surprises. As far as I understand, we use extension because we don't want to add another level of nesting in configs. I wonder if there is an option to "flatten" such nested entities in Jackson.

I think that's indeed the reason that HttpRemoteTaskRunnerConfig extends RemoteTaskRunnerConfig.
We could simply copy and paste rather than doing a subclass, but I think we want to reduce code duplication and the maintenance burden it adds. One compromise could be to do composition, but flatten manually in the new class's constructor. It creates some more code in the new class (a constructor is needed) but avoids both the problems of equals and of too much code duplication. I don't know if Jackson has an option to do it automatically or not.


Tr/describe v2

PR Type
Enhancement, Bug fix

Description

Enhanced patch generation and logging in pr_processing.py to handle large files more effectively.
Improved error handling and logging in utils.py for patch generation and empty file content scenarios.
Optimized GitHub diff handling in github_provider.py, including better rate limit handling and merge base commit logic.
Enhanced PR description generation in pr_description.py, adding support for large PRs and uncovered files.
Updated configuration in configuration.toml to include collapsible file list threshold and removed redundant settings.
Refined PR description prompts in pr_description_prompts.toml for better clarity and output generation.

Changes walkthrough 📝
Relevant filesEnhancement

pr_processing.pyEnhanced patch generation and logging for large files.

pr_agent/algo/pr_processing.py
Improved logging for skipped patches due to size constraints.  Fixed formatting issues in patch generation.

+2/-2

github_provider.pyEnhanced GitHub diff handling and patch generation.

pr_agent/git_providers/github_provider.py
Improved handling of rate limits and file content loading.  Enhanced logic for determining merge base commits.  Optimized patch generation for incremental reviews.  Improved line addition and deletion counting.

+50/-39

pr_description.pyImproved PR description generation and large PR handling.

pr_agent/tools/pr_description.py
Added logic to handle large PRs with uncovered files.  Improved error handling and logging for PR description generation.  Enhanced collapsible file list handling and file data processing.

+143/-67

Error handling

utils.pyEnhanced error handling in patch generation.

pr_agent/algo/utils.py
Improved error handling and logging for patch generation.  Optimized handling of empty file content scenarios.

+8/-15

Configuration changes

configuration.tomlUpdated configuration for collapsible file list and large PR handling.

pr_agent/settings/configuration.toml
Added configuration for collapsible file list threshold.  Removed redundant mention of extra files setting.

+1/-1

Documentation

pr_description_prompts.tomlUpdated PR description prompts for better output clarity.

pr_agent/settings/pr_description_prompts.toml
Updated prompts to include file paths and summary changes.  Adjusted instructions for YAML output generation.

+10/-16

💡 PR-Agent usage: Comment /help "your question" on any pull request to receive relevant information

Preparing PR description...

PR Description updated to latest commit (https://github.com/Codium-ai/pr-agent/commit/e95920c58cc762b62a6b12bd35d064fbf4531dd6)

Preparing PR description...

PR Description updated to latest commit (https://github.com/Codium-ai/pr-agent/commit/e95920c58cc762b62a6b12bd35d064fbf4531dd6)


docs: fix broken links to all command source files in readme

Checklist

[ ] I've added an entry to CHANGELOG.md if necessary. You can comment this pull request with /changelog-entry [breaking-change|new-feature|bug-fix|chore] [message] and CHANGELOG.md will be updated automatically.

Why
They pointed to .js, but they're all .ts.
How
Manually.
Test Plan
I clicked them all.

the readme is generated using oclif-dev readme (source) - we need to check why oclif is not properly generating paths to ts files

Let's just say I had a premonition...

@kbrandwijk thanks for the PR. As Brent mentioned, the readme is auto-generated so this is a one-time fix.
Fortunately, there is a way to fix it. We have a script that we run to start the release process - https://github.com/expo/eas-cli/blob/main/packages/eas-cli/package.json#L178 A part of the script is responsible for patching the readme. The script is here https://github.com/expo/eas-cli/blob/main/packages/eas-cli/patch-readme.js I think the proper fix is just a matter of adding a new .replace call. It's not ideal but it does not require fixing oclif-dev readme.

@kbrandwijk thanks for the PR. As Brent mentioned, the readme is auto-generated so this is a one-time fix.
Fortunately, there is a way to fix it. We have a script that we run to start the release process - https://github.com/expo/eas-cli/blob/main/packages/eas-cli/package.json#L178 A part of the script is responsible for patching the readme. The script is here https://github.com/expo/eas-cli/blob/main/packages/eas-cli/patch-readme.js I think the proper fix is just a matter of adding a new .replace call. It's not ideal but it does not require fixing oclif-dev readme.

@dsokal Thanks for the pointers. I'll follow up with a commit with the fix to the script.

Apparently, according to https://github.com/oclif/dev-cli/blob/master/src/commands/readme.ts#L210, oclif-dev looks for the project devdepencies to see if typescript is present, and if so, generates links to the .ts instead.
So instead of adding another manual replace patch to the existing ones, I went that route, and verified that the generated commands block does indeed link to the .ts source now.


Fraudulent website detection

PR Description:
Introducing a fraud detection model using machine learning on the Malicious and Benign Websites dataset, enhancing web security by scrutinizing URL characteristics, server attributes, and content features to classify websites accurately.
Screenshots / videos

Checklist:

[x]  Developed and trained machine learning model for fraud detection.
[x]  Conducted thorough analysis of URL, server, and content features.
[x]  Evaluated model performance with robust accuracy metrics.
[x]  Visualized ROC curve to assess model effectiveness.
[x]  Documented findings and insights for transparency.

@sanjay-kv i have raised the PR  please check it once..and assign me this issue under gssoc level 3.
thank you.

where is the issue link for the same, also this is not the repo we solve this kinda of issue.