Selectors with arguments?

Is it possible with reselect to create selectors that take arguments? The selector would then return a normal selector function that accepts the state.
const someSelector = createSelector(
  [someOtherSelector, someOtherSelectorTwo],
  (argument, resultOne, resultTwo) => {}
);

const mapStateToProps = createStructuredSelector({users: someSelector('users')});

Or you know something like that? My use case is I have multiple parts of my state that share a common interface (they have a requirements object of the same signature). I want to create a selector that returns all results matching their requirements but currently I have to create one selector per entity (one for users that meet their requirements, etc).

Like this?
export const selectorDatasets = state => state.entities.get(schema.dataset.getKey()) || new Map();

export const selectorDataset = dataset_id => {
  return createSelector(
    selectorDatasets,
    (datasets) => datasets.get(dataset_id.toString()) || new Map()
  );
};

but i have similar question....how to create selector with deep nesting? I just can't solve the puzzle :(
how to select the 'attribute'?:
listA [10].listB[5].listC[6].attribute

10, 5, 6 - another parts of global state.
i tried to get it like this:
const selectorDatasetId = state => state.fakeRoute.dataset_id;
const selectorDashboardId = state => state.fakeRoute.dashboard_id;
export const selectorDatasets = state => state.entities.get(schema.dataset.getKey()) || new Map();
export const selectorDataset = dataset_id => {
  return createSelector(
    selectorDatasets,
    (datasets) => datasets.get(dataset_id.toString()) || new Map()
  );
};

export const selectorDashboard = (dataset_id, dashboard_id) => {
  return createSelector(
    selectorDashboards(dataset_id),
    state => state,
    (dashboards) => dashboards.get(dashboard_id) || new Map()
  );
};

export const selectorDashboards = dataset_id => {
  return createSelector(
    selectorDataset(dataset_id),
    (dataset) => dataset.get(schema.dashboard.getKey()) || new Map()
  );
};

export default createSelector(
  selectorDatasetId,
  selectorDashboardId,
  state => state,
selectorDashboardId(state))(state),
  (dataset_id, dashboard_id, state) => {
    const dashboard = storeSelectors.selectorDashboard(dataset_id, dashboard_id)(state);
    console.log(dashboard);

    return {
      dataset_id,
      dashboard_id,
      dashboard
    }
  }
);

but 'dashboard' never refresh :(

Yeah it just dawned on me I can just create a function that returns a createSelector call, I'm an idiot.

can you rename topic for getting deep nesting state via arguments? :))))) i don't want to create another issue, but not sure that people will look here - with current title :(

@Anahkiasen You definitely aren't an idiot, it's a pretty common question.
@plandem, thanks a lot for taking the time to the answer the original question!
As regards to your follow-up question, I can't quite follow the example but it looks like you are returning a selector as the output from selectorDashboards and then passing that into the selector created in selectorDashboard which doesn't seem right.
Also, if you create new selectors every time the state changes it will prevent Reselect from being able to memoize the results.
There are two sections in the documentation starting here that might be along the lines of what you are trying to achieve. If I've missed the point of what you are doing I'll be happy to help out more if you can give me an example that I can run on my machine (or a jsfiddle/jsbin).
By the way, rather than changing the title of this issue I actually think it is better to open a second issue for your follow-up question. That way people in the future that looking through the issues will stand a better chance of being able to find the answers to both questions.

here is issue #101

Cool :+1:

@ellbee so is it not correct way to use?
/**
 * Return ID of current dataset
 */
const selectorDatasetId = state => state.fakeRoute.dataset_id;
const selectorDashboardId = state => state.fakeRoute.dashboard_id;
const selectorDashboard = state => storeSelectors.selectorDashboard(selectorDatasetId(state), selectorDashboardId(state))(state);

export default createSelector(
  selectorDatasetId,
  selectorDashboardId,
  selectorDashboard,
  (dataset_id, dashboard_id, dashboard) => {
    return {
      dataset_id,
      dashboard_id,
      dashboard
    }
  }
);

It depends on the context, but I will say that it looks like it might be a mistake. Can you show me how you are using this in the context of a React Redux app?

well, i have deeply nested state tree(consider it like snapshot of real DB), like this:
https://www.dropbox.com/s/j8qkpft7la782m2/Screenshot%202016-03-27%2000.34.00.png?dl=0

at the same page, some components use entities from 'dashboards', other components use 'dashboard_views'. [1] and [2] at the path of above screenshot are state of router.
I'm trying to isolate each component with only required part of state, i.e. component that render 'dashboard_view' knows nothing about 'dashboard' and has no any property with it.

Specifically, the bit I think may be a mistake is that it looks like the storeSelectors.selectorDashboard is returning a selector. And then that selector is being passed into the result function. So the object the selector returns has a type like:
 {
      dataset_id :: number,
      dashboard_id :: number,
      dashboard :: function
 }

But without seeing a complete example it is hard to tell that is what it is supposed to be doing.

Right now i'm trying to use it like this:
const selectorDashboard = state => storeSelectors.selectorDashboard(selectorDatasetId(state), selectorDashboardId(state))(state);

this one return part of state. But with such deep neested tree of state, looks like it does not cache :(

Ah right, I missed the final state on the end, so ignore what I said about that part.
As for it not caching, If you create new selectors every time the state changes it will prevent Reselect from being able to memoize the results. A new selector has an empty cache so it has to perform the computation.

any recommendation for such kind of deeply nested state tree? i have feeling that this code smells :)

@plandem : certainly the common recommendation for nested/relational Redux data is to flatten it as much as possible.  See the "nested state" question in the FAQ.
You might also be interested in a higher-level abstraction like https://github.com/tommikaikkonen/redux-orm , which is specifically intended to deal with this kind of data.  It lets you define "Models" and their relationships, then treats a portion of your store as if it were a database with "tables" for each Model type.  Looking up a given Model instance by ID automatically retrieves other related items for you.

any recommendation for such kind of deeply nested state tree?

@plandem A use case for this is when you maintain detailed data for a list of entities, where the detailed data for each entity is fetched separately as they are needed.
Example
Imagine you have a view that displays a list of many products. In another view you show the details for a single product. You only want to fetch the detailed data for a product if you are going to display it.
The simple way to do this is to only store the detailed data for one product at a time, but that will require you to fetch the detailed data every time you switch between the details of two products.
By having a reducer that holds details for all products (for which you have fetched the details), you don't have to throw away details for the previous product(s) when fetching details for new products.
In the latter case, a memoized selector would recompute whenever we want to show details for a new product, which might be fine. However, what if you need to show details for several products at a time?
If several components use the memoized selector to get details for different products, the selector will keep throwing away the previous results and would have to recompute the details for every product every time.
In that case it would be beneficial to memoize the derived details per product id, so that we can reuse the derived details for a product unless the data in the reducer has been updated.
One way to achieve this is to create your own createSelector function with a custom memoization function. An example is shown below. (I'm not sure it's necessarily the best way to do it.)
import { createSelectorCreator } from 'reselect';

const createSelectorForProductId = createSelectorCreator((resultFunc) => {
    const memoAll = {};

    return (productId, ...args) => {
        if (!memoAll[productId]) {
            memoAll[productId] = {};
        }

        const memo = memoAll[productId];

        if (!shallowEquals(memo.lastArgs, args)) {
            memo.lastArgs = args;
            memo.lastResult = resultFunc(...args);
        }

        return memo.lastResult;
    };
});

const _getProductIdAsMemoKey = (state, productId) => productId;
const getRawDetailsForProduct = (state, productId) => state.productDetails[productId];

export const getDetailsForProductId = createSelectorForProductId(
    _getProductIdAsMemoKey,
    getRawDetailsForProduct,
    (rawDetails) => {
        // derive data from raw details data
        ...
    }
);

// Use selector
getProductForId(state, productId);

The memoization function passed to createSelectorCreator assumes that the first dependency resolves the productId for the product you want details for, while _getProductIdAsMemoKey and getRawDetailsForProduct and thus getForProductId requires that the productId is passed as 2nd parameter.

Is so simple: let's give you an example, I have a mapStateToProps like this:
function mapStateToProps(state) {
  return {
    categoryHistory: getCategoryHistory(state,'extended')
  }
}

then I've create a selector like this:
export const getCategoryHistory = (state, type) => createSelector([getTaxonomy, selectedCategoryID], (categories, categoryID) => categories.getIn([type, categoryID]) || [])(state)
The solution is to call createSelector() passing the state as parameters:
createSelector()(state)
inside the selector you can use all the parameter you want to pass through.

@ttessarolo not good, since each call to getCategoryHistory will create new selector, which will create new value. And that is exactly what you wanted to avoid by using reselect.

I think you can close this issue as its explained in FAQ's
https://github.com/reduxjs/reselect#q-how-do-i-create-a-selector-that-takes-an-argument


snowflake_ocsp_insecure_mode: Expose the insecure_mode python option …

…to dbt.
resolves #31
Resolves issues when the Snowflake OCSP server is not reachable and the dbt user would like to run commands without checking the OCSP server. OCSP failures/inaccessibilitiy are possible due to network routing issues or when corporate network security has exposed Snowflake (especially in privatelink) but not the OCSP server.
Description
Exposes the insecure_mode option in the Snowflake python connector to dbt via the profile.yml file.
Checklist

[X] I have signed the CLA
[X] I have run this code in development and it appears to resolve the stated issue
[ ] This PR includes tests, or tests are not required/relevant for this PR
[X] I have updated the CHANGELOG.md and added information about my change to the "dbt-snowflake next" section.

@JoshuaHuntley I do see some unrelated changes included in the commit: https://github.com/dbt-labs/dbt-snowflake/pull/30/commits/fffc4dd2a16f78fe22e68cfdcd16e2ca0663724c
Any chance you could try rebasing this PR, or close it and open a new one? It sounds like the actual change you want is a two-liner, just adding insecure_mode to SnowflakeCredentials and the call to snowflake.connector.connect.

I'm not sure why 79d7818 continues to include the other unrelated changes. It might be simpler to open a new PR.

@jtcohen6 Was out on paternity leave and got back today. Tried to fix the branch and it looks like I was successful. Will continue to monitor for feedback.


An ambiguous error: Class 'QueryCollection' incorrectly extends base class 'T[]'.

TypeScript Version:  Microsoft.TypeScript.MSBuild.2.2.0-beta-20161112-1
Code: WinJS type in DefinitelyTyped
Expected behavior: A helpful error message guiding me to the proper fix
Actual behavior:
TS2415 Build:Class 'QueryCollection' incorrectly extends base class 'T[]'. winjs.d.ts line 9777
TS2417 Build:Class static side 'typeof QueryCollection' incorrectly extends base class static side '{ isArray(arg: any): arg is any[]; readonly prototype: any[]; from<T, U>(arrayLike: ArrayLike,...'. winjs.d.ts line 9777
I cannot understand what "incorrectly" means here. What is the right fix?

This also happens in 2.1.4 but does not happen in 2.0.10.

Can you post the entire error message?

typings/winjs/winjs.d.ts(9777,11): error TS2415: Class 'QueryCollection<T>' incorrectly extends base class 'T[]'.
  Types of property 'map' are incompatible.
    Type '<U>(callbackfn: (value: T, index: number, array: T[]) => U, thisArg?: any) => U[]' is not assignable to type '{ <U>(this: [T, T, T, T, T], callbackfn: (value: T, index: number, array: T[]) => U, thisArg?: an...'.
      Type 'any[]' is not assignable to type '[any, any, any, any, any]'.
        Property '0' is missing in type 'any[]'.
typings/winjs/winjs.d.ts(9777,11): error TS2417: Class static side 'typeof QueryCollection' incorrectly extends base class static side '{ isArray(arg: any): arg is any[]; readonly prototype: any[]; }'.
  Types of property 'prototype' are incompatible.
    Type 'QueryCollection<any>' is not assignable to type 'any[]'.
      Types of property 'map' are incompatible.
        Type '<U>(callbackfn: (value: any, index: number, array: any[]) => U, thisArg?: any) => U[]' is not assignable to type '{ <U>(this: [any, any, any, any, any], callbackfn: (value: any, index: number, array: any[]) => U...'.
          Type 'any[]' is not assignable to type '[any, any, any, any, any]'.

Well,tThose two lines were in fact all I got on VS2017 RC. :/ It seems it's another issue.

Did you try updating your winjs.d.ts to the one I linked?https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/winjs/winjs.d.ts is a broken link.  It looks like it was renamed from winjs.d.ts to index.d.ts back in May.  Search engines like Google point to the old one if you do a search for "winjs.d.ts" unfortunately.

I was talking about "ambiguous error" rather than winjs fix but it was because of Visual Studio clipping build error message.


Feature: Handle currency and percentiles for numeric-sort  class.

numeric-sort currently handles decimals and negative numbers but wont work for currency. Modify numeric-sort to also allow inferring and sorting of currency such as $69, $60.69, ($69.23), -$56 etc. Also other currency signs such as pounds, euro etc. Percentages are also something that can be represented as decimals as well, so we should handle that as well e.g ( 69.1%, 69.15%, etc.)

Make sure this class also handles numbers with commas in them. (i don't think it does)

https://github.com/LeeWannacott/table-sort-js/issues/109 completed

Done in https://github.com/LeeWannacott/table-sort-js/releases/tag/v1.21.0


Intelligent motion-detection outdoor

Checklist

[x] I checked for similar existing requests (both open and closed) before posting.
[x] My request is generic, other users may benefit from it too.

Proposal
[clear description of what you want to see changed or added]
I have multiple outdoormotion-sensors. I would like to trigger if persons are running around the house.
Additional info
[some example of how the new functionality should look like]
We have had multiple events of burglary in the neighbourhood. A recognition pattern was always that some people walked around the house not touching anything. Sometimes for more than an hour they walk around. If they are sure nobody and nothing reacts, they started to break in.
If a cat or squirrel runs past one of the sensors I don't want to get an alarm but if different sensors are triggered and/or one sensor multiple times in a timeframe, it might be because one or more persons are walking around the house.

In alarmo you can make a sensor group for this. It works exactly as you describe, see the documentation for more info.

Nice! Now I finally understood how to get sensors into this grouping-mode.
But one thing could be added I guess. At the moment all group-sensors must be triggert to get alarm.
"Alarm when minmal x from y (=total groupmembers) are triggert" would be great. If the scumbag misses to pass only one out of ten sensors when walking around, he will never trigger the alarm.
... or did I get that wrong as well?   ;-)

In a sensor group 2 sensors must be triggered within the set time frame, not all.

2 sensors is a problem in my case. I needed to bring it up to at least 3.
I simply just modified "event_count" default=3 in custom_components\alarmo\store.py for my needs. But would you mind to just make the integer editable as well in the frontend?


Don’t attempt to initialise when running under FastBoot

This lets apps run under fastboot which have this addon installed
Obviously the addon will no longer work in Fastboot, but I don't see a scenario where that would be wanted anyway!

Hey @rlivsey I'm not sure I understand the use case. Why would you not want this addon to run on fastboot apps? I'm not super familiar w fastboot, know it's server side rendering but I fail to see how that relates to not loading stripe.
thx!

I blame not enough coffee, I think I tried to solve the wrong problem.
The real problem is that currently the addon fails under FastBoot, because it appears Stripe either isn't loading or at least hasn't loaded at the time the initializer kicks in. This means Stripe.setPublishableKey(config.stripe.publishableKey); fails and takes the whole app down with it.
Preventing any of this from loading obviously "fixes" the issue and got my app to boot, but the real solution would be figuring out why Stripe isn't available at this point as you're right that it should just work.
Feel free to close this and I'll dig in and issue a more correct PR in the (hopefully) near future!

oh, makes a lot of sense.
Do you think you could help me make a small isolated use case in jsbin that replicates this, that way we can figure out what the best approach is.
Thanks again!

Any update on this? The component prevents running in Fastboot mode.


hwo to reduce the memory usuage when using fhog_object_detector_ex?

Hello,
when i command fhog_object_detector_ex to training the face detector, it using all machine's memory(>200G), I think it is because the training face numbers is about >100k and training image number is about > 10k, so i guess  it maybe put all the hog features(of all faces)into the memory when training the structural svm classifier, so when debug the code, i found it is the line https://github.com/davisking/dlib/blob/master/examples/fhog_object_detector_ex.cpp#L148 which caused it.
so how to change this ?please give some advise, thanks!

Get more RAM or use smaller images.  Also, general dlib questions should be directed to the sourceforge forums.

ok,thanks


Settings page

This page will contain all the user preferences/settings/options in the app.
We'll need to keep in mind that more options may be added later in development.
Progress:

[ ] Design settings page
[ ] Implement settings page Vue template
[ ] Populate settings page with data

Settings:

[ ] (boolean) Timer: Analog / digital setting
[ ] (boolean) Analog timer: Clockwise/counter-clockwise progress
[ ] (boolean) Digital timer: always show hours
[ ] (boolean) Count up / count down

Any other suggestions for settings?

Question: Do we want to sync settings between devices/instances?
If so, do we sync all settings, or are there some settings that should not be synced?

Hmm, I like syncing everything to create a seamless experience. Would syncing more content/settings create a performance bottleneck at all?

Syncing everything sounds good to me, it shouldn't create any kind of performance bottleneck.
Do we want to provide a setting (hehe) to turn settings syncing on/off per device?

Seems like a good idea to me (how meta of you haha)- not everyone can be carefree about their data usage.


Lazy URL load for OSCAR_HOMEPAGE in defaults.py raises unhandled exception

Issue Summary
We are seeing the error 'promotions' is not a registered namespace in our log handling when the Oscar app urls are resolved. It looks like the default settings are lazy loading the promotion homepage for the OSCAR_HOMEPAGE setting: https://github.com/django-oscar/django-oscar/blob/master/src/oscar/defaults.py#L8
Since we're not using the promotions app urls in our customized integration, we see this raise the unhandled exception above.
Steps to Reproduce
We customize/override the order and payment apps, but otherwise included oscar.get_core_apps in our INSTALLED_APPS setting. In our urls.py, we did not add url(r'', include(oscar.app.application.urls)), and then finally this error is raised when the django app urls are resolved, quickly reproducible in a view that simply raises via response = handle_uncaught_exception(request, get_resolver(get_urlconf()), sys.exc_info()) in django.core.handlers.exception.py
Technical details

Python version: 3.6.3
Django version: 1.11.7
Oscar version: 1.6.3

I think the long term solution for this is in #2215 where we are pulling out the promotions app completely. Until then, the easiest workaround is to override that setting with something like:
OSCAR_HOMEPAGE = '/'

Setting has been finally updated within the #2215 and will be available within the Oscar 2.0 release.


dvc: save_dvc_exp doesn't work if repo has .dvc files.

If a repo contains .dvc files (via dvc add or dvc import) save_dvc_exp will be incorrectly skipped.
After fixing the incorrect skip, there is another issue that exp save tries to dvc commit those files, failing and requiring --force flag.
Even if that failure can be avoided with --force, it is unclear if DVCLive (via exp save) should be running dvc commit at all.

Thanks @SoyGema for uncovering this bug

I think

Even if that failure can be avoided with --force, it is unclear if DVCLive (via exp save) should be running dvc commit at all.

Let's use --force and commit those files. It's similar to changes in dependencies during dvc exp run. We commit those before running the experiment.

Let's use --force and commit those files. It's similar to changes in dependencies during dvc exp run. We commit those before running the experiment.

I worry this might cause some unexpected behavior if someone tries the DVCLive-only experiments in a repo where they also manually manage data with DVC.
Not sure how common of a scenario that would be

TBH I think I missed the behavior of dvc exp save --force and I think this should actually be the default behavior of dvc exp save @dtrifiro. There was a long similar convo about dvc exp run, and ultimately both dvc repro and dvc exp run forcefully commit any changes to dependencies. I think this will also be useful if we want dvclive to log artifacts on each run.

both dvc repro and dvc exp run forcefully commit any changes to dependencies

Actually, I just double checked. dvc repro commits changes to dependencies, and dvc exp run commits all changes even if they are not dependencies. Regardless, if it hasn't been an issue yet for dvc exp run, it's probably safe to commit for dvc exp save. It may be more surprising if dvc exp save doesn't commit and then users transition to dvc exp run, which does.


MS2LDA network visualization does not show up

When starting a network visualization, the network does not show up (Please wait... does show up!)

It's clunky and slow, but seems like the network viz still works.


Update README.md

Just a small change in a convener name

Leaving this for Wei Ji to merge in case there's a preferred order for merging the open PRs.


Azure Stack Hub GPU support is currently in public preview.

Isn't AZsH GPU support now GA?

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 682649a8-9b9c-1376-9e06-3ec3bbdaad8f
Version Independent ID: 3f14a385-148c-8ad2-5526-9c5ef5f9ac07
Content: Graphics processing unit (GPU) VM on Azure Stack Hub - Azure Stack Hub
Content Source: azure-stack/user/gpu-vms-about.md
Service: azure-stack
Sub-service: azure-stack-hub
GitHub Login: @mattbriggs
Microsoft Alias: mabrigg

@aricbernard following up. Thanks for the note.
#in-progress

@aricbernard @shashishailaj  Thanks for your question. GPU is not yet GA yet for Azure Stack Hub. We will update the page as soon as it does. Thanks! Matt
#please-close


Ensure is_hidden is properly handled

https://github.com/jpmorganchase/jupyter-fs/blob/main/jupyterfs/fsmanager.py#L143 should be replaced with an actual check, else hardcoded to !=exists instead of the current ==exists.

will fix on fork

FYI: There should also be a good fix in #20.


Adding a resume part in profile

The user can upload his resume and then view or download it

@thestarsahil A suggestion here
People are spamming issues overwhelmingly even after getting assigned for a particular one.
I have seen somewhere in github that unless contributor's PR gets merged he can't create any issues.
Please look into it


headless scripting crash

Still looking for other people to ensure it's not just my box.
system info
Ubuntu 16 LTS. Binja professional. Dev channel.
Repro
~/.bashrc
export PYTHONPATH=$PYTHONPATH:$HOME/binaryninja/python

crash.py
from binaryninja import *
bv = BinaryViewType['ELF'].open("/bin/ls")

running the script
# python crash.py
QWidget: Must construct a QApplication before a QWidget
Aborted (core dumped)

I was using a plugin messing with the UI that was the issue.


json files generated with seed0 mismatch the ones you provide

I notice some errors in the few-shot json files for coco. For instance, the json file full_box_1shot_person_trainval.json contains redundant images, expected 1 but 8. Moreover, I try to generate these files that are directly under folder datasets/cocosplit/ with seed 0. However, it turns out different with those you provide. Hope for clarifying. Thanks.

Thanks for your interest. For the seed0 annotation for COCO, we didn't generate them ourselves. We used the preprocessed json files provided by the prior work as seed0 for consistent comparison.  Our script is used to provide splits of other random seeds used in our paper.  Hope it helps!

closing the issue for now and feel free to reopen it if there is any other confusion.


Filter out null values in SQL and resulting type

Problem
model Carrier {
  id   Int;
  lat? Float;
  lng? Float;
}

const carriers = await prisma.carrier.findMany({
  select: {
    id: true,
    lat: true,
    lng: true,
  },
  where: {
    lat: { not: { equals: null } },
    lng: { not: { equals: null } },
  },
});

// This now results in "number | null", but it very much should be "number"
carriers[0].lat

Suggested solution
I would prefer using a syntax like this:
const carriers = await prisma.carrier.findMany({
  select: {
    id: true,
    lat: 'notNull',
    lat: 'notNull',
  },
});

This is very descriptive that the lat and lng are only fetched if they are not null and it would remove a lot of unnecessary where clauses.
Alternatively, it could be done via the where clause, but the types would need to be fixed.
const carriers = await prisma.carrier.findMany({
  select: {
    id: true,
    lat: true,
    lng: true,
  },
  where: {
    lat: { not: { equals: null } },
    lng: { not: { equals: null } },
  },
});

Alternatives
Fixing type at runtime...
Additional context
Possible fix to this: https://github.com/prisma/prisma/issues/15074 - We could use the custom query to define a query that would fix the types, but it is a lot of manual work just in different a file...

@danstarns, although I would love for this to be fixed, I do not think this qualifies as a bug but rather a feature.


[Bug]: CheckBoxGroup not displaying options

Is there an existing issue for this?

[X] I have searched the existing issues

Description
CheckBoxGroup inside a modal not displaying the values even though the options property of that same checkBoxGroup shows the correct evaluated values .

Steps To Reproduce
1.Create a modal with a CheckBoxGroup
2.Tick the options and close the modal
3.Reopen the modal
Public Sample App
No response
Version
Cloud

@soul-cell I'm not able to reproduce this issue. Can you please create a public app that reproduces this issue on app.appsmith.com so we can fix it?

@Nikhil-Nandagopal found a way to reproduce, happens when you reset the modal
https://www.loom.com/share/45c2d263fe7f4a04a58ceb268d9f2f4c

Reach - Assuming 20% of checkbox group users who have updated checkbox group options have faced this
Stats

Stat
Values

Reach
40

Effort (months)
0.5


Can't mix antipoison mixes

🐛 Bug Report
Can't use /mix command to create an antipoison mix on OSB. I get this message: "You don't own: 0x Roe, 0x Antipoison potion (2)." even though I have roe and 2 dose antipoison in bank. All other barbarian mixes can be created (though it's impossible to get the required items for some)

Already fixed with next osb reset https://github.com/oldschoolgg/oldschoolbot/pull/5314


Please add bootstrap.css to bower.json

Guys,
I think you forgot to include "dist/css/bootstrap.css" in your bower.json's main section. I'm using yeoman with grunt and it considers this to include the css in its unique vendor.css.
Regards,
Rodolfo.

We didn't forget; it's deliberate.
Duplicate of #16663.


Add a memory map of VRAM

Fixes #533.
The hand-written SVGs return! (Sorry, Antonio... :P)
The SVG was originally (see 966b0d13810e110fcf290422a10e3efc58a2c5d9) generated automatically from a Python script. At that point, it was fully self-contained (no JS required for interactivity)... at the cost of being just shy of one megabyte.
Considering this was ridiculously large, and visibly taxing on the browser, the SVG was entirely overhauled to move the interactivity from a ****ton of elements and a bit of CSS, to only a bunch of elements and a bit of JS. (This was never fully realised, thus never committed.)
The result was still very large, so I started making use of the <use> element, which allows duplicating elements without copy-paste—perfect for these massive grids! (And chances are, the browser may be able to optimise that. Idk.) This was impossible with the old CSS-only design, due to it being based on some elements having the same position within the parent (which <use> inherently precludes.)
Unfortunately, <use> is also very finicky with regards to mouseover/mouseenter events (especially the former), so the final implementation (fdbf3226ec587059866810a933c70de0fa091d97) may raise some eyebrows among JS devs. I tried to be clean, but I'm only an amateur in that field... :D

This last commit moves the JS file from stand-alone to being contained within the SVG itself; this makes the SVG fully interactive even when viewed stand-alone instead of within Pan Docs.


ActiveWorkRefresh

StreamingDataflowWorker is a very large class.  This breaks out the active work refresh and invalidating commit logic ( async work management) to another class.
Initial implementation is what currently exists today.  There will be another implementation of refreshActiveWork() later for direct path, but this PR lays the ground work for it.  Also add tests to have more coverage over individual components than just the StreamingDataflowWorkerTest which is larger.
R: @arunpandianp

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

[ ] Mention the appropriate issue in your description (for example: addresses #123), if applicable. This will automatically add a link to the pull request in the issue. If you would like the issue to automatically close on merging the pull request, comment fixes #<ISSUE NUMBER> instead.
[ ] Update CHANGES.md with noteworthy changes.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.
To check the build health, please visit https://github.com/apache/beam/blob/master/.test-infra/BUILD_STATUS.md
GitHub Actions Tests Status (on master branch)

See CI.md for more information about GitHub Actions CI or the workflows README to see a list of phrases to trigger workflows.

R: @arunpandianp

There is a flaky test added:
testInvalidateStuckCommits: https://github.com/apache/beam/runs/22276370706
Wanted but not invoked:
forComputation.invalidate(
    <ByteString@3e931ad0 size=0 contents="">,
    0L
);
-> at org.apache.beam.runners.dataflow.worker.windmill.work.refresh.DispatchedActiveWorkRefresherTest.testInvalidateStuckCommits(DispatchedActiveWorkRefresherTest.java:231)
Actually, there were zero interactions with this mock.

	at org.apache.beam.runners.dataflow.worker.windmill.work.refresh.DispatchedActiveWorkRefresherTest.testInvalidateStuckCommits(DispatchedActiveWorkRefresherTest.java:231)

I will take a look and fix thanks @Abacn !


chart  behaviour with real data

Hello,
when I apply real data and price to this chart. and when I am watching the history of the chart, and the chart gets new data, it jumps to the beginning of the chart.
and chart is not stable.
I want to see the history of the chart and go a bit back, but with real data, when it gets new data, it jumps to the beginning.

The trick with this is to let the chart manage the xExtents, don't set it yourself.
I'll add an example chart to do this.


OSPRay fixes and features

Removed some ospReleases that could crash OSPRay.
Added clipping plane for geometries.
Summary of Changes

See above.
References and Context

Test Instructions

Run testspheres.

The Superbuild script of OSPRay 2.4 in scripts/superbuild/ worked fine so far and you do not have to look for matching dependencies.


Configure isort to include source paths

Description

It would be nice to have our isort configurations in our .pre-commit-config.yaml file set up to recognize the repo-specific source paths: https://pycqa.github.io/isort/docs/configuration/options.html#src-paths
This would separate internal imports (1st party) from our other dependencies (3rd party) in the import statements. Presently the two are conflated and grouped in the same block:
https://github.com/WordPress/openverse-catalog/blob/dad3cb49618f38aadb3ae7772f98ca77180bf35c/openverse_catalog/dags/database/image_expiration_workflow.py#L8-L11
I believe this is reliant on #334 since we would also need use the repo-specific folders (i.e. openverse_catalog for the catalog repo, api/catalog and ingestion-server/ingestion_server for the API repo).

The API already has an isort config file .isort.cfg so the catalog can define one in the root too. This need not be blocked on #334.

Oh! It even has known_first_party defined!
https://github.com/WordPress/openverse-api/blob/55f55de18766854c63c78a39006a5d516744a811/.isort.cfg#L6
Thanks for pointing that out Dhruv 😄

isort also merges args with the .isort.cfg file so we can put the common parts of the config in the pre-commit args and leave the different parts in the config file. Since #334 is merged, this is ready for work!


[contrib/ansible] Failure to provision a working kube cluster due to unresolveable hostnames

I'm having trouble getting the most recent contrib/ansible scripts to successfully provision a Kubernetes cluster.  It used to work many days ago around kubernetes/contrib master branch commit 3634e300, but now fails at commit f48ce77f.  I'm hoping someone can provide advice that may allow me to use the unmodified stock code.  Otherwise I'm looking for approval of a proposed change which I can turn into a PR.
At some point recently, the contrib/ansible scripts seemed to have changed so that host arguments to processes are now hostnames instead of IPs.  At kubernetes/contrib commit 3634e300 the arguments to flanneld, kube-proxy, and kubelet were IP-based, and now they are hostname based.  This is also true of the contents of the kube config file found on the master at: /etc/kubernetes/kubectl.kubeconfig
For example:
# before around master branch commit 3634e300
/usr/bin/flanneld -etcd-endpoints=http://{ip-address-of-the-master}:2379 ...
# now around master branch commit f48ce77f
/usr/bin/flanneld -etcd-endpoints=http://{hostname-of-the-master}:2379 ...

Because the hostnames of cluster peers are unresolveable, the Kubernetes cluster fails to function.
In order to work around the problem, I created additional ansible tasks to update the /etc/hosts file of every node so that hostnames may resolve into IP addresses.  This solves the problem, but with the drawback of slowing down the ansible deploy due to the gathering of facts.
diff --git a/ansible/roles/pre-ansible/tasks/main.yml b/ansible/roles/pre-ansible/tasks/main.yml
index 9b21de4..21138b2 100644
--- a/ansible/roles/pre-ansible/tasks/main.yml
+++ b/ansible/roles/pre-ansible/tasks/main.yml
@@ -39,3 +39,22 @@

 - include: fedora-dnf.yml
   when: os_version.stdout|int >= 22 and 'Fedora' in distro.stdout and is_atomic is not defined
+
+- name: Gather cluster networking facts for /etc/hosts
+  setup:
+  register: networking_facts
+  tags:
+    - "/etc/hosts"
+
+- name: Insert/update /etc/hosts using ansible cluster facts
+  blockinfile:
+    dest: /etc/hosts
+    block: |
+      {% for host in groups['all'] %}
+        {{- hostvars[host].ansible_default_ipv4.address }} {{ host }}
+      {% endfor %}
+    marker: "# {mark} ANSIBLE MANAGED BLOCK"
+    create: no
+  when: networking_facts
+  tags:
+    - "/etc/hosts"

Tested on:
Kube Masters and Nodes: CentOS Linux release 7.2.1511 (Core)
Dev Machine: ansible <IP_ADDRESS>

This is my first time touching Ansible.  Feedback is appreciated.  Thanks!

Basically, you need what Vagrant does [1] with lineinfile module [2] before it runs the ansible deploy cluster playbook.
In my CI environment, all host names equals to their private IPs (automatically done by provisioning system). So there is no need for DNS resolution.
Other option is to use dynamic inventory. You need two pieces:

a file (e.g. CLUSTER_RESOURCE) with a list of IPs of your cluster. E.g.

MASTERS=<IP_ADDRESS>
ETCD=<IP_ADDRESS>
NODES=<IP_ADDRESS>,<IP_ADDRESS>

script (e.g. python) that will read the file and generate a json file, e.g.:

{
	"masters": {
		"hosts": ["<IP_ADDRESS>"],
		"vars": {
			"ansible_ssh_user": "root",
			"ansible_sudo": false
		}
	},
	"etcd": {
		"hosts": ["<IP_ADDRESS>"],
		"vars": {
			"ansible_ssh_user": "root",
			"ansible_sudo": false
		}
	},
	"nodes": {
		"hosts": ["<IP_ADDRESS>", "<IP_ADDRESS>"],
		"vars": {
			"ansible_ssh_user": "root",
			"ansible_sudo": false
		}
	}
}

I would prefer using the dynamic inventory if you run the ansible over dynamically provisioned cluster.
[1] https://github.com/kubernetes/contrib/blob/master/ansible/vagrant/vagrant-ansible.yml#L8
[2] http://docs.ansible.com/ansible/lineinfile_module.html

@dcwangmit01 would the dynamic inventory help in your case?

@ingvagabund Thanks for responding, and for the detailed pointer in the right direction.  I'm going to take the dynamic inventory approach and write a script that interprets my ~/.ssh/config.
I also realize now that the unresolvable hostname issue I experienced was not due to code changes, but was instead due to changing my inventory to be based on hostnames defined in my ~/.ssh/config, instead of IP addresses.  Thus, the need to generate /etc/hosts (much like what you pointed out regarding vagrant-ansible.yml).
Closing this issue.


Platformatic DB: seed command always applies migrations

The platformatic db seed command automatically applies migrations regardless of the migrations.autoApply configuration setting.
Expected behaviour
Migrations will only be applied if migrations.autoApply is set to true in the application's configuration file.
Actual behaviour
Migrations are always applied when platformatic db seed is run, even if the migrations.autoApply setting is not set (default value is false), or when migrations.autoApply is explicitly set to false.

I agree is not coherent, but it's weird that you have a not applied migration AND you try to apply a seed which is not based on the latest. So I know that it's more work, but IMO we should raise a warning or -better- ask the user if they wan to apply the "pending" migration before apply the seed. WDYT?

I think we might want to error out if there are migrations to apply instead.

Raising an error (with a clear message) is OK too.

let's do that!

I think we might want to error out if there are migrations to apply instead.

Good call. Now I think about it, the seed command shouldn't apply migrations at all as it's an unexpected side effect.


Demo showing that CTEs not needed for query are being included, increasing query complexity

I'm running into trouble getting dbt-unit-testing to work on bigquery.  I'm getting the error
Resources exceeded during query execution: Not enough resources for query planning - too many subqueries or query is too complex.
When I read the compiled SQL, I see that it's including CTEs that are upstream from the models that
need to be mocked.  I think it's all these unnecessary CTEs that are causing the issue.
Here's an example of a model graph that demonstrates the problem.  Model a and b are independent.
Model c is dependent on a and b.  Model d is dependent on model c.
a -> c -> d
b ---^

I want to write a unit test for model d and mock out model c.  Models a and b shouldn't be needed.  However,
the compiled SQL shows that they are included:
    with
-- NOTE: graph_c is mocked out properly here
      graph_c as (select * from (
    select 'x' as origin
    union all
    select 'y' as origin
  ) as graph_c_tmp_1
      ),

    expectations as (select "origin", count(*) as count from (
    select 'X' as origin
    union all
    select 'Y' as origin
  ) as s group by "origin"),

    actual as (select "origin", count(*) as count from ( with
-- NOTE: graph_a and graph_b are included here, but not referenced anywhere else
          graph_b as (select 'b' as origin),
          graph_a as (select 'a' as origin)
      select * from (select upper(origin) as origin from graph_c) as tmp ) as s group by "origin"),

    extra_entries as (
    select '+' as diff, count, "origin" from actual

    except

    select '+' as diff, count, "origin" from expectations),

    missing_entries as (
    select '-' as diff, count, "origin" from expectations

    except

    select '-' as diff, count, "origin" from actual)

    select * from extra_entries
    UNION ALL
    select * from missing_entries

Hi @gnilrets, it looks like model a and b are not needed but in fact that’s not the case.
One of our goals is to keep the tests as focused as possible, meaning that we want be able to mock only the columns that are necessary for a specific test.
Imagine that model c has a lot of columns, derived from models a and b. If model d uses those columns we’ll have to specify all of them when mocking model c, probably setting them to null, like this:
  {% call dbt_unit_testing.mock_ref('graph_c') %}
    select 'x', null as c1, null as c2, null as c3, null as c4, null as c5, null as c6, null as c7 as origin
    union all
    select 'y', null as c1, null as c2, null as c3, null as c4, null as c5, null as c6, null as c7 as origin
  {% endcall %}

This can get really cumbersome.
So at some point we need to build the full model starting from model c in order to get all the extra columns and include them on the select with NULL values. Maybe we could simplify the final sql but that won’t prevent us from having to build the full sql for all of its dependencies.
However I would like to understand why we are receiving that error. We are using this package on a Postgres project with  a fairly complex hierarchy of models and it’s working fine. Maybe the problem is with bigquery only.
Is it possible for you to please share the sql that’s causing that error in big query? It would help us a lot to understand the issue.
Thank you for your feedback


[SMALLFIX] Propagate -i to all master when using start_masters

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Alluxio-Pull-Request-Builder/20404/Failed Tests: 1org.alluxio:alluxio-tests: 1alluxio.client.fs.FileSystemMasterIntegrationTest.clientFileInfoDirectory
Test FAILed.

Merged build finished. Test FAILed.

Jenkins, test this please

Merged build finished. Test FAILed.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Alluxio-Pull-Request-Builder/20407/
Test FAILed.

Jenkins, test this please

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/Alluxio-Pull-Request-Builder/20411/
Test PASSed.


Support for endpoint-level validation

Judging by documentation, it is currently only possible to use the validator application-wide, immediately affecting all of the endpoints. It would be helpful to be able to attach middleware to specific endpoints with predefined swagger path already filled during instantiation.
This is useful for two scenarios:

Google Cloud Functions: while they seem to use Express under the hood and in general support swagger-style middleware, you can't attach middleware on app or router level and you don't have access to routing params, making usage of swagger-express-validator impossible;
Incremental introduction of validation into the project.

@gargol Please let me know if this change makes sense and if I could contribute to implementing it.

:wave: @kibertoad . Thanks for the input! Can you please provide some code on how you see it being used. My understanding is something like this?
const validator = require('swagger-express-validator');

server.use('/status', validator(opts), (req, res) => {
  res.json({
    status: 'OK',
  })
});

That's the thing, Google Cloud Functions have no concept of server or router, so minimal Cloud Function code looks like this:
exports.helloHttp = (req, res) => {
  res.send(`Hello ${req.body.name || 'World'}!`);
};

End result of this is that when you call HOST_NAME/helloHttp, this function will be invoked. Recommended pattern for middleware looks like this:
exports.helloHttp = (req, res) => {
 cors(req, res, () => {
res.send(`Hello ${req.body.name || 'World'}!`);
});
});

Obviously you can structure code in a somewhat smarter fashion and implement express-like chains, but the main point here is that you can't rely on any existing context for resolving triggered path.
Ideally validation middleware API would be something like this:
exports.helloHttp = (req, res) => {
 validator.get('helloHttp', (req, res) => {
res.send(`Hello ${req.body.name || 'World'}!`);
});
});

(sorry, my original example was wrong, updated it now)

My understanding is that it would require to extract resolveRequestModelSchema and resolveResponseModelSchema out of validateRequest and validateResponse methods into some more generic way or matching a schema to the endpoint that needs validation. Makes sense to me :+1: I'm not actively using the library any more but would gladly collaborate on such feature :smiley:

Thank you for the reply! Will try to cook up something for this :)

If the goal is to restrict the validator to a specific subset of the URL namespace, it might be possible to use basePath. This could be done by causing the validator to ignore any request that does not begin with that prefix.
(There could also be an override option that would let the original behavior be restored.)

(switched companies since and feature become less relevant for me, but I still intend to implement it. Sorry for delay!)

@kibertoad no worries, know the pain. I'm having troubles giving this project time as well :smiley:


Make compatible with Rust 1.31.0 and prepare patch release

Version 0.4.3 produces an error on Rust 1.31.0 which I usually take as MSRV in device drivers. Sorry about that!
This solves it and bumps the patch version. AFAIK it is not possible to send tags in a PR so somebody needs to take it from here.
error[E0502]: cannot borrow `*data` as immutable because it is also borrowed as mutable

  --> /home/travis/.cargo/registry/src/github.com-1ecc6299db9ec823/i2cdev-0.4.3/src/mock.rs:41:75
   |
41 |         data.clone_from_slice(&self.registers[self.offset..(self.offset + data.len())]);
   |         ----                                                              ^^^^        - mutable borrow ends here
   |         |                                                                 |
   |         mutable borrow occurs here                                        immutable borrow occurs here

See the error on CI here

r? @ryankurte
(rust_highfive has picked a reviewer for you, use r? to override)

0.4.4 tagged and published to crates.io


Update, clean, and reorganize the Readme files.

Review by @gzm0, but no rush at all.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://scala-webapps.epfl.ch/jenkins/job/scalajs-pr/1375/
https://scala-webapps.epfl.ch/jenkins/job/scalajs-matrix-build/1742/
Test FAILed.

That's all

Updated.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://scala-webapps.epfl.ch/jenkins/job/scalajs-pr/1376/
https://scala-webapps.epfl.ch/jenkins/job/scalajs-matrix-build/1746/
Test PASSed.

LGTM

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://scala-webapps.epfl.ch/jenkins/job/scalajs-pr/1377/
https://scala-webapps.epfl.ch/jenkins/job/scalajs-matrix-build/1747/
Test PASSed.


Setup

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@40a9c8f). Click here to learn what that means.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master       #1   +/-   ##
=========================================
  Coverage          ?   71.42%
  Complexity        ?        6
=========================================
  Files             ?        1
  Lines             ?       21
  Branches          ?        3
=========================================
  Hits              ?       15
  Misses            ?        3
  Partials          ?        3

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 40a9c8f...c8f2043. Read the comment docs.


documented function onRender missing in code

no sign of that function... where is it?
seems like i can disable certain dates with this function... but where is it? :)

This is implemented now

finally :P


DLP-2423: Include more fields in 'entry' set hash function in cloudflare_zero_trust_dlp_profile

Currently, the custom set hash function on values in the entry set only uses the name field. Start using every field (except ID) to properly detect changes to more fields without causing plan instability

acceptance tests look good
TF_ACC=1 go test ./internal/sdkv2provider -v -run "^TestAccCloudflareDLPProfile_" -count 1 -timeout 120m -parallel 1
=== RUN   TestAccCloudflareDLPProfile_Custom
--- PASS: TestAccCloudflareDLPProfile_Custom (2.93s)
=== RUN   TestAccCloudflareDLPProfile_Custom_MultipleEntries
--- PASS: TestAccCloudflareDLPProfile_Custom_MultipleEntries (2.23s)
=== RUN   TestAccCloudflareDLPProfile_CustomWithAllowedMatchCount
--- PASS: TestAccCloudflareDLPProfile_CustomWithAllowedMatchCount (2.16s)
=== RUN   TestAccCloudflareDLPProfile_CustomWithOCREnabled
--- PASS: TestAccCloudflareDLPProfile_CustomWithOCREnabled (2.13s)
=== RUN   TestAccCloudflareDLPProfile_ContextAwareness
--- PASS: TestAccCloudflareDLPProfile_ContextAwareness (2.13s)
PASS
ok  	github.com/cloudflare/terraform-provider-cloudflare/internal/sdkv2provider	12.831s


../../runtime/vm/os_linux.cc: 464: error: unreachable code when compiling AOT binary inside Docker on Armv7

Dart SDK Version (dart --version)
Dart SDK version: 2.16.1 (stable) (Tue Feb 8 12:02:33 2022 +0100) on "linux_arm"
Whether you are using Windows, MacOSX, or Linux (if applicable)
Linux: Linux hostname 5.10.63-v7l+ #1496 SMP Wed Dec 1 15:58:56 GMT 2021 armv7l GNU/Linux

$ cat /etc/os-release
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
HOME_URL="http://www.raspbian.org/"
SUPPORT_URL="http://www.raspbian.org/RaspbianForums"
BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"

$ docker --version
Docker version 20.10.12, build e91ed57
I have a very simple Dart program that outputs much the same as dart --version:
import 'dart:io' show Platform, stdout;

void main() {
  print(Platform.version);
}

This compiles and runs just fine when not using Docker.
But when I run:
export ARCH="arm"
export DART_VERSION="2.16.1"
sudo docker build -t atsigncompany/dartshowplatform:"$DART_VERSION"-"$ARCH" \
  --build-arg DART_VERSION="$DART_VERSION" -f dartshowplatform/Dockerfile .

against dartshowplatform/Dockerfile:
ARG DART_VERSION="2.14.4"
FROM dart:${DART_VERSION} AS build
WORKDIR /app
COPY ./dartshowplatform/showplatform.dart .
RUN dart compile exe /app/showplatform.dart -o /app/dartshowplatform

FROM scratch
COPY --from=build /runtime/ /
COPY --from=build /app/dartshowplatform /app/dartshowplatform
ENTRYPOINT ["/app/dartshowplatform"]

It fails like this:
Sending build context to Docker daemon  4.129MB
Step 1/9 : ARG DART_VERSION="2.14.4"
Step 2/9 : FROM dart:${DART_VERSION} AS build
 ---> d01ea6894cbd
Step 3/9 : WORKDIR /app
 ---> Using cache
 ---> ddde485ca4ad
Step 4/9 : COPY ./dartshowplatform/showplatform.dart .
 ---> Using cache
 ---> bc344772b410
Step 5/9 : RUN dart compile exe /app/showplatform.dart -o /app/dartshowplatform
 ---> Running in 81af19056609
../../runtime/vm/os_linux.cc: 464: error: unreachable code

===== CRASH =====
si_signo=Segmentation fault(11), si_code=1, si_addr=0xc
Aborting re-entrant request for stack trace.
Aborted (core dumped)
The command '/bin/sh -c dart compile exe /app/showplatform.dart -o /app/dartshowplatform' returned a non-zero code: 134

NB ARG DART_VERSION="2.14.4" is simply a default that's overridden to 2.16.1 by DART_VERSION="$DART_VERSION"
Full source etc. at https://github.com/atsign-company/at_dockerfiles
The error was first seen on a MiniNode hosted Raspberry Pi used as part of the GitHub Actions workflow, and has been replicated on another Pi4 running the commands by hand.
This was running just fine yesterday with Dart 2.16.0

The line number 464 shown above corresponds to this code
  if (clock_gettime(CLOCK_MONOTONIC, &ts) != 0) {
    UNREACHABLE();
    return 0;
  }

clock_gettime is not supported in the docker version ?

Thanks @a-siva
That led me to Raspberry Pi: clock_gettime(CLOCK_MONOTONIC, _) failed: Operation not permitted (1) and from there to Fix/Workaround - libseccomp2. So I've installed the backported libseccomp2 and now my Dart app is building OK again with Dart 2.16.1 inside Docker on Raspberry Pi OS 10 Buster.
# Get signing keys to verify the new packages, otherwise they will not install
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 04EE7237B7D453EC 648ACFD622F3D138

# Add the Buster backport repository to apt sources.list
echo 'deb http://httpredir.debian.org/debian buster-backports main contrib non-free' \
 | sudo tee -a /etc/apt/sources.list.d/debian-backports.list

sudo apt update
sudo apt install libseccomp2 -t buster-backports

Seems like a Raspberry Pi OS thing more than a Dart thing, so closing this issue. But hopefully other people who trip across the problem will find the workaround here.


Change on MongoDB storage response strategy

This is a precursor to asset support feature.
Description
Normalize response strategy of some of the methods in /node/storage/mongodb.js as some of response decisions are too specific.

Remove strategy on "reject a promise when query result is falsy".
Update getAssetList() to response with whole document instead of specific property only.
Remove getBlockList() as it never been used.

Types of changes

[x] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

[x] My code follows the code style of this project.
[ ] My change requires a change to the documentation.
[ ] I have updated the documentation accordingly.
[x] I have read the CONTRIBUTING document.
[ ] I have added tests to cover my changes.
[x] All new and existing tests passed.

Additionally, I've evaluate implication on these changes and (to my surprised) no usages in storage.js requires modification due to this change.

Retract this PR and to be incoporate as part of asset support feature PR in the future.


[otbn] Build system integration

We are starting to produce (example) software targeting the OTBN processor. This effectively is a separate processor architecture with a dedicated (assembly-only) toolchain.
We have two use cases for the software produced by this toolchain:

Normally, OTBN software is loaded into OTBN from Ibex by writing it to a special device register. For this use case, we have the following flow: OTBN assembly -> OTBN assembler -> ELF file -> objcopy -> a C header containing the binary as define/char const -> compile/link with the actual software (running on Ibex)

For simulations and DV with OTBN in isolation, we will directly provide a way to load the OTBN-ELF-file into the simulation (i.e. without letting Ibex load the software into OTBN)

The question is: how do we want to produce the OTBN software, i.e. how do we want to call the toolchain? Are we OK with calling the toolchain components (assembler, objcopy, etc.) in a simple script which produces the right header file for inclusion in the main software (e.g. meson calling an external script to produce this data, as we do for auto-generated headers), and use similar scripts for our simulation use cases, or do we want more fully-featured build system integration?
@gkelly @lenary

Another way to do part (1) is OTBN ELF file -> objcopy -> binary blob in Ibex ELF file (my_blob.o). If you do that, you can link your Ibex code against the ELF object and the build system looks much less weird (no auto-generated source code).

I don't think meson can do two cross-compiler toolchains (for separate parts of the build). So I think we end up having to invoke scripts from meson to generate the otbn object, and then put it into something DV or sw can use. This is yet another mark against meson.
For Ibex images, if we're injecting directly into the ibex elf file as @rswarbrick proposes, we can only do that for one OTBN image at a time without some kind of manifest format, which I'd rather not define until we know what SW needs. For the moment, I feel we should start by doing it @imphil's way (generating a header), and later transition to the more complex ELF injection.

I'm fine with that approach, but I'm not quite sure what you mean about needing a manifest format. I was imagining that you would generate N binary blobs in N ELF files, each defining a symbol like my_algorithm_seven or whatever. Then the "manifest" is just a load of lines like extern void *my_algorithm_seven; in the Ibex source code. Indeed, the linker will throw away any objects we turn out not to need.
Thinking about it, these might need their own section (to ensure they end up next to each other), otherwise you have to explicitly lay them out in OTBN memory, but that's equally true for the C header approach too.

Copying the data is easy. Generating symbols that point to the right place in the final binary isn't, and you also probably want both a start address and a length at least in the manifest (if you're swapping in and out parts of the OTBN image dynamically).

Oh I'm wrong, objcopy can create the symbols that point into the right place, sorry.

Ok, so I don't mind which of Philipp's/Rupert's approaches we take, but it will have to be with scripts external to meson, and not with another cross-compilation configuration.

"will have to be with scripts external to meson" Sounds like a use case for Makefiles!

Another way to do part (1) is OTBN ELF file -> objcopy -> binary blob in Ibex ELF file (my_blob.o). If you do that, you can link your Ibex code against the ELF object and the build system looks much less weird (no auto-generated source code).

I missed the previous discussions about using ELF vs a flat binary for OTBN, but either way, using objcopy with --binary-architecture to easily link it in without generating header files etc seems a nicer approach to me.

@imphil I guess I might not have been clear by saying "scripts external to meson": we'll need to use meson external commands, so that device software can still depend on the results of building otbn images - we just cannot use meson's inbuilt cross-compiler support because we're already using that for ibex.

Thinking about what @lenary said:

... and you also probably want both a start address and a length at least in the manifest (if you're swapping in and out parts of the OTBN image dynamically).

This is true. In fact, it's probably a bit more complicated than that. For example, you'll probably want to support having algorithms A and B, which both use common code C. So you'll need to load either A+C or B+C (but maybe they don't both fit in OTBN memory at once).
The usual approach to this problem is called an "overlay". The binutils linker actually has overlay support (a nice surprise!). In the example above, you'd have 2 overlaid regions. One would contain A and the other would contain B. The NOCROSSREFS feature in the linker catches silly errors like accidentally calling function in B from code in A.
So I'm imagining that we'll bundle up all the OTBN code for the application into a single, linked (OTBN) ELF. We could then use objcopy to transmogrify that into something that could be linked with Ibex code. This needs judicious application of the --keep-global-symbol flag, which lets us join the two namespaces cleanly. The result would be an ELF blob with some symbols pointing at the start and end of the "segments" of code and data, together with some symbols pointing at the the entry points we want to keep. Note that these symbols would be pointing at a sort of "double-LMA": the (Ibex) address of the data, before it gets copied to OTBN.
The Ibex code then needs to load stuff into OTBN. If we're doing clever things with overlays, there's some logic here, but it's not massively complicated. It will need to know a "single-LMA" for each blob: the address in the Ibex address space corresponding to the OTBN memory where the blob should be written.
Finally, the Ibex code will need to set a couple of pointers in OTBN addresses (the VMA). For example, it will probably need to set a reset vector register. That needs a little more simple arithmetic, converting from the base address of OTBN's instruction memory as seen from Ibex to the base address as seen from OTBN (which is zero, in fact).
And then you're done. Easy!
In practice, there are various ways for this to come unstuck (such as alignment problems between sections, missing entry points and so on), so it's probably wise to have a "link-otbn-application" script, which does some sanity checks on the result.

I did not expect to see the following when referencing overlay loading:

And then you're done. Easy!

I really think if we start using overlays this early, we have strayed far from "the simplest thing that can work". I can see us getting to a point of requiring them, but I think we can deal with the duplication of code across images before then.
All I meant for manifest and dynamic loading is if I want to run a specific algorithm on OTBN, even if I'm loading a single blob, I still need to know where it is, and what length it is (and potentially where to load it into OTBN memory if it cares). I may also need to to check the hash of that blob, if I care it's not been tampered with.

I agree with @lenary's comments.
In terms of programming model, we need to be careful with how Ibex interacts with otbn. For crypto isolation purposes, Ibex software requires the ability to determine the state of execution of otbn, and have the ability to, in some cases, safely-clear data memory and regs before execution.
So far my understanding is that we have enough IMEM to execute all required public crypto algorithms without having to reload IMEM between runs. The controller software can safely clear state (need to add a tracking issue for this), reload IMEM if needed, trigger otbn runs with deadline (#2748), and finally clean-up state.


Add parameter check for fetchData

Description of changes:

Check if engagement.id is truthy
remove unnecessary console.log(error)

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of the met-public license (Apache 2.0).

Codecov Report

Merging #1671 (3897805) into main (3f2f394) will increase coverage by 0.04%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #1671      +/-   ##
==========================================
+ Coverage   71.70%   71.74%   +0.04%
==========================================
  Files         360      360
  Lines       10569    10569
  Branches      821      826       +5
==========================================
+ Hits         7578     7583       +5
+ Misses       2862     2857       -5
  Partials      129      129

Flag
Coverage Δ

metweb
65.26% <100.00%> (+0.08%)
:arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

...components/publicDashboard/KPI/ProjectLocation.tsx
75.00% <100.00%> (+2.77%)
:arrow_up:

...omponents/publicDashboard/KPI/SurveyEmailsSent.tsx
82.85% <100.00%> (+2.85%)
:arrow_up:

...omponents/publicDashboard/KPI/SurveysCompleted.tsx
82.85% <100.00%> (+2.85%)
:arrow_up:

...ublicDashboard/SubmissionTrend/SubmissionTrend.tsx
71.73% <100.00%> (+2.17%)
:arrow_up:

...src/components/publicDashboard/SurveyBar/index.tsx
73.91% <100.00%> (+2.17%)
:arrow_up:


TES3Merge v0.4 Serious Error has Occurred

TES3Merge.log

Hi OkabeRintaro, can you give this build a try?
TES3Merge.zip

This build still gives me a serious error, here's the log.
TES3Merge.log

Give this version a try, and let me know if it fixes it:
TES3Merge.zip

That version, as well as version v0.5 that you just released, fixed the issue and now the merge is working as normal.

Great, thanks for testing.


Add inputmode="url" to URL input

gives a nicer experience for Android and iOS user with custom keyboard.
https://css-tricks.com/everything-you-ever-wanted-to-know-about-inputmode/#article-header-id-5

Thx!
You have the funny typo analyzer bot)


fix deprecated call to Aws::CredentialProvider access_key_id

This @s3.client.config.credentials is SharedCredentials, which included methods from CredentialProvider:
http://docs.aws.amazon.com/sdkforruby/api/Aws/CredentialProvider.html#access_key_id-instance_method
Instead this methods, we must use this methods from Credentials module:
http://docs.aws.amazon.com/sdkforruby/api/Aws/Credentials.html#access_key_id-instance_method

to issue #18

By chance is this related to the following error I'm getting when I start up the server?
/usr/local/lib/ruby/gems/2.2.0/gems/refile-s3-0.2.0/lib/refile/s3.rb:43:in `initialize': missing keywords: region, bucket (ArgumentError)

@trendwithin you just did't configure params region, bucket

Thanks for the reply.  I was able to pinpoint the error I made.  I was following the set-up example a tad too literally and made the mistake of:
Refile.cache = Refile::S3.new(prefix: "cache", **aws)
Refile.cache = Refile::S3.new(max_size: 10.megabytes)
Refile.store = Refile::S3.new(prefix: "store", **aws)

instead of
 Refile.cache = Refile::S3.new(prefix: "cache", max_size: 10.megabytes, **aws)
 Refile.store = Refile::S3.new(prefix: "store", **aws)

@jnicklas what do you think?

Anyone managed to use iam roles credential in a ecs container?


Example sources in examples dir and built examples in build/examples

This moves the example sources to the examples directory.  When tasks/build-examples.js is run, built examples are in the build/examples directory.
Resources that are only required by examples are in the examples/resources directory (previously these were in resources at the root of the repo).  Example resources that don't need to be in the repo are loaded from a CDN.  I hope we can continue to pare down the resources required by our examples instead of adding more.
When running the development server (tasks/serve.js or npm start), you can browse the examples at http://localhost:3000/build/examples/.  I'm sure people will be confused when they try http://localhost:3000/examples/ (which serves the source example index.html without any content).  But I think this is still a usability improvement to have all built artifacts in the build directory.
One awkward bit is that the examples need the same relative path to ol.css in the development server and when deployed as part of the website.  For now, the tasks/serve.js script copies css/ol.css to build/css/ol.css every time the examples are built.  This is not ideal, but there are other things I'd like to change about tasks/serve.js before making a larger change.
Fixes #3547.

Thank you very much for the huge effort on this @tschaub! To me, this is going in the right direction. I'd say feel free to merge when you think this is ready (and when the Travis build passes).

Notes for posterity:

Protocol relative URLs will bite you (in Phantom for example)
Phantom's --ignore-ssl-errors option doesn't get around SSL handshake failures

Ok, this is officially not fun any more.  Phantom fails because $ is not defined in the graticule.html example, but the others work.  And of course the same passes for me locally.  So now we've got transient network issues making things fail.
I'd love to have simpler examples that didn't load Bootstrap and jQuery.  I'm not feeling like putting copies of the same back in our repo or having an extra build step that copies them in place.  So I'm going to ditch this effort for now.

All passing now, but I'd like to make sure the check-examples target isn't unstable.

This seems obvious in retrospect, but here's the key bit from debugging Phantom on Travis:
Resource request error: 6 ( "SSL handshake failed" ) URL: "https://code.jquery.com/jquery-1.9.1.min.js"

So, protocol relative URLs were a mistake, we should always load resources via SSL, but we have to remember not to because Travis can't shake hands.

It may be that there is a PhantomJS option that will save us.  Testing.

Ok, when Travis gives the green light, this should be good to go.
I've taken some liberties in adding commits that are not just about renaming examples_src to examples.  Having spent an inordinate amount of time debugging Phantom failures on Travis, I felt I was justified in cleaning up some other things that have been annoying me for a while.  Namely:

The example-behavior.js script is now named common.js
Instead of exampleNS, this script creates a common object
The lint task now runs on this script
There are no more base64 / binary data / UTF-8 strings utilities in this script

For those following along at home, though I removed the use of jQuery from a number of our examples, the examples do still load jQuery and it should be safe to use now that Phantom runs with the appropriate options on Travis.  I think it would be nice not to lean to heavily on it (or any jQuery plugins), but I think it is more sensible to use code in the examples that people will understand rather than duplicating jQuery-like functionality in our common.js script.  So, my preference is for straight DOM where practical, falling back to jQuery where the reduced verbosity makes the examples easier to follow.

I agree with all your changes. Please merge before Travis changes his mind :-)

I agree with all your changes. Please merge before Travis changes his mind :-)

Thanks @elemoine.

Very impressive work, @tschaub. Thanks for taking so much time.

I got tricked today by browsing to examples from the index page instead of to build/examples
Is there a way to hide this link or another solution?


GPUImageFramework conflicts with react-native-webgl

Current Behavior
When attempting to install when already using gl-react-native which needs dependency react-native-webgl there are two errors when building via XCode:

~/node_modules/react-native-webgl/ios/framework/Source/iOS/Framework/module.modulemap:2:19: Umbrella header 'GPUImageFramework.h' not found

~/node_modules/react-native-video-processing/ios/RNVideoProcessing/VideoProcessingGPUFilters.swift:10:8: Could not build Objective-C module 'GPUImage'

I was trying to get this to work, so I started a new project and installed this module first and then one by one installed other dependencies and that is when it fails. When removing the libRNWebGL.a linked library from the existing project it builds as expected
There seems to be a conflict with the same GPUImageFramework being installed. I am unsure how to troubleshoot further, does anyone have any ideas?
Environment
"dependencies": {
"gl-react": "^3.14.0",
"gl-react-native": "^3.14.0",
"gl-react-native-filters": "^1.0.1",
"react": "16.3.1",
"react-native": "0.55.4",
"react-native-animatable": "^1.2.4",
"react-native-camera": "^1.1.4",
"react-native-keychain": "3.0.0-rc.3",
"react-native-video": "^2.0.0",
"react-native-video-processing": "^1.13.0",
"react-native-webgl": "^0.8.0",
"react-navigation": "^2.0.1",
"validate.js": "0.12.0"
},

If anyone else runs into this problem, I was able to fix by forking react-native-webgl and removing the GPUImage framework and adding the RNWebGL.xcodeproj manually to the project's Libraries and adding the libRNWebGL.a to link binary with libraries build phases.


mobile-full-screen.js is not working along with Parcel

Hi,
In my project I previously use .net Core and Openlayers, with mobile-full-screen.js which is working fine.
Now I tried to recreate it using pure Node.js by following this instruction. However, mobile-full-screen.js is no longer working.
Here is my index.html

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
	<meta http-equiv="X-UA-Compatible" content="chrome=1">

After npm start, in the dist folder, these files exist:

mobile-full-screen.xxxxxx.js
mobile-full-screen.xxxxxx.js.map

but I dont get full screen in any browser.
what could be the reason, any suggestion?
thanks

found a solution

nothing relates to mobile-full-screen.js. it is just css that caused a problem.
credit https://gis.stackexchange.com/questions/314059/increasing-size-height-of-openlayers-map-canvas


fetch 3d course ids from 3d_to_4d_course_translation.json for tooltip functionality

Looks great, thanks for adding this!


Build failure for stack build intero

I wanted to try out intero but it failed while installing intero into Stack environment:
Intero is not installed in the Stack environment.

Installing intero-0.1.13 automatically ...

terminfo-<IP_ADDRESS>: download
terminfo-<IP_ADDRESS>: configure
terminfo-<IP_ADDRESS>: build
terminfo-<IP_ADDRESS>: copy/register
haskeline-<IP_ADDRESS>: download
haskeline-<IP_ADDRESS>: configure
haskeline-<IP_ADDRESS>: build
haskeline-<IP_ADDRESS>: copy/register
intero-0.1.13: download
intero-0.1.13: configure
intero-0.1.13: build
Completed 3 action(s).

--  While building package intero-0.1.13 using:
      /home/qrilka/.stack/setup-exe-cache/x86_64-linux/setup-Simple-Cabal-<IP_ADDRESS>-ghc-7.10.3 --builddir=.stack-work/dist/x86_64-linux/Cabal-<IP_ADDRESS> build --ghc-options " -ddump-hi -ddump-to-file"
    Process exited with code: ExitFailure 1
    Logs have been written to: /home/qrilka/ws/h/xlsx/.stack-work/logs/intero-0.1.13.log

    Configuring intero-0.1.13...
    Warning: This package indirectly depends on multiple versions of the same
    package. This is highly likely to cause a compile failure.
    package intero-0.1.13 requires transformers-<IP_ADDRESS>
    package haskeline-<IP_ADDRESS> requires transformers-<IP_ADDRESS>
    package ghc-7.10.3 requires transformers-<IP_ADDRESS>
    Building intero-0.1.13...
    Preprocessing executable 'intero' for intero-0.1.13...
    [1 of 8] Compiling GhciTypes        ( src/GhciTypes.hs, .stack-work/dist/x86_64-linux/Cabal-<IP_ADDRESS>/build/intero/intero-tmp/GhciTypes.o )
    [2 of 8] Compiling GhciMonad        ( src/GhciMonad.hs, .stack-work/dist/x86_64-linux/Cabal-<IP_ADDRESS>/build/intero/intero-tmp/GhciMonad.o )

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:189:31:
        No instance for (MonadIO Ghc) arising from a use of ‘liftIO’
        In the expression: liftIO
        In a stmt of a 'do' block: ref <- liftIO $ newIORef state
        In the expression:
          do { ref <- liftIO $ newIORef state;
               unGHCi g ref }

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:213:22:
        No instance for (MonadIO Ghc) arising from a use of ‘liftIO’
        In the second argument of ‘(.)’, namely ‘liftIO’
        In the expression: liftGhc . liftIO
        In an equation for ‘liftIO’: liftIO = liftGhc . liftIO

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:229:10:
        No instance for (transformers-<IP_ADDRESS>:Control.Monad.IO.Class.MonadIO
                           GHCi)
          arising from the superclasses of an instance declaration
        In the instance declaration for ‘ExceptionMonad GHCi’

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:248:10:
        No instance for (transformers-<IP_ADDRESS>:Control.Monad.IO.Class.MonadIO
                           (InputT GHCi))
          arising from the superclasses of an instance declaration
        In the instance declaration for ‘ExceptionMonad (InputT GHCi)’

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:270:3:
        Could not deduce (MonadIO m) arising from a use of ‘liftIO’
        from the context (GhcMonad m)
          bound by the type signature for
                     printForUserNeverQualify :: GhcMonad m => SDoc -> m ()
          at src/GhciMonad.hs:267:29-54
        Possible fix:
          add (MonadIO m) to the context of
            the type signature for
              printForUserNeverQualify :: GhcMonad m => SDoc -> m ()
        In the expression: liftIO
        In a stmt of a 'do' block:
          liftIO $ Outputable.printForUser dflags stdout neverQualify doc
        In the expression:
          do { dflags <- getDynFlags;
               liftIO $ Outputable.printForUser dflags stdout neverQualify doc }

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:277:3:
        Could not deduce (MonadIO m) arising from a use of ‘liftIO’
        from the context (GhcMonad m)
          bound by the type signature for
                     printForUserModInfo :: GhcMonad m => GHC.ModuleInfo -> SDoc -> m ()
          at src/GhciMonad.hs:272:24-67
        Possible fix:
          add (MonadIO m) to the context of
            the type signature for
              printForUserModInfo :: GhcMonad m => GHC.ModuleInfo -> SDoc -> m ()
        In the expression: liftIO
        In a stmt of a 'do' block:
          liftIO $ Outputable.printForUser dflags stdout unqual doc
        In the expression:
          do { dflags <- getDynFlags;
               mUnqual <- GHC.mkPrintUnqualifiedForModule info;
               unqual <- maybe GHC.getPrintUnqual return mUnqual;
               liftIO $ Outputable.printForUser dflags stdout unqual doc }

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:283:3:
        Could not deduce (MonadIO m) arising from a use of ‘liftIO’
        from the context (GhcMonad m)
          bound by the type signature for
                     printForUser :: GhcMonad m => SDoc -> m ()
          at src/GhciMonad.hs:279:17-42
        Possible fix:
          add (MonadIO m) to the context of
            the type signature for printForUser :: GhcMonad m => SDoc -> m ()
        In the expression: liftIO
        In a stmt of a 'do' block:
          liftIO $ Outputable.printForUser dflags stdout unqual doc
        In the expression:
          do { unqual <- GHC.getPrintUnqual;
               dflags <- getDynFlags;
               liftIO $ Outputable.printForUser dflags stdout unqual doc }

    /tmp/stack8063/intero-0.1.13/src/GhciMonad.hs:395:5:
        No instance for (MonadIO Ghc) arising from a use of ‘liftIO’
        In the expression: liftIO
        In a stmt of a 'do' block:
          liftIO
          $ do { initDynLinker dflags;
                 mb_stdin_ptr <- lookupSymbol
                                   "base_GHCziIOziHandleziFD_stdin_closure";
                 mb_stdout_ptr <- lookupSymbol
                                    "base_GHCziIOziHandleziFD_stdout_closure";
                 mb_stderr_ptr <- lookupSymbol
                                    "base_GHCziIOziHandleziFD_stderr_closure";
                 .... }
        In the expression:
          do { dflags <- getSessionDynFlags;
               liftIO
               $ do { initDynLinker dflags;
                      mb_stdin_ptr <- lookupSymbol
                                        "base_GHCziIOziHandleziFD_stdin_closure";
                      .... } }
Could not install Intero!

We don't know why it failed. Please read the above output and try
installing manually. If that doesn't work, report this as a
problem.

Using stack install intero gives the same result. I use GHC 7.10.3 if that matters
And using stack build intero as it's said in https://github.com/commercialhaskell/intero/blob/master/TOOLING.md fails with
$ stack build
error: file ‘nixpkgs’ was not found in the Nix search path (add it using $NIX_PATH or -I)

Is intero still unstable?

And stack --no-nix build fails the same way

@qrilka
Can you paste the output for each of the following?
stack exec which ghc
stack exec --no-nix which ghc
stack exec -- ghc-pkg list transformers

Probably the problem comes from transformers?
qrilka@qdesktop ~/ws/h/xlsx $ stack exec -- ghc-pkg list transformers
/usr/lib64/ghc-7.10.3/package.conf.d
   transformers-<IP_ADDRESS>
/home/qrilka/.stack/snapshots/x86_64-linux/lts-5.3/7.10.3/pkgdb
   transformers-<IP_ADDRESS>
/home/qrilka/ws/h/xlsx/.stack-work/install/x86_64-linux/lts-5.3/7.10.3/pkgdb
qrilka@qdesktop ~/ws/h/xlsx $ stack exec which ghc
/usr/bin/ghc
qrilka@qdesktop ~/ws/h/xlsx $ stack exec --no-nix which ghc
/usr/bin/ghc

Right. GHC 7.10.3 ships with transformers-<IP_ADDRESS>: http://downloads.haskell.org/~ghc/7.10.3/docs/html/libraries/index.html
Maybe something installed the newer version into your GHC 7.10.3 database? That's rather confusing.

I use Gentoo and it does not set upper bounds for transformers when it's not required.
Looking into transformers changelog I don't see how monads could change from the following:
<IP_ADDRESS> Ross Paterson<EMAIL_ADDRESS>Mar 2015
	* Added Eq1, Ord1, Show1 and Read1 instances for Const

Probably I could try getting a separate GHC with stack when I will have some time for it...

system-ghc: false resolved the problem but for me that's just a workaround or do I miss something?

I think that's a workaround of the fact your global GHC has strange
packages in it, but the GHC provided by stack is the regular distribution
so it's also the preferred method of using GHC.
On Monday, 6 June 2016, Kirill Zaborsky<EMAIL_ADDRESS>wrote:

system-ghc: false resolved the problem but for me that's just a
workaround or do I miss something?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/commercialhaskell/intero/issues/69#issuecomment-224070882,
or mute the thread
https://github.com/notifications/unsubscribe/AAArC6c4a-I8e7azuTcVv3tPI2bb74Nmks5qJHyVgaJpZM4IuV1W
.

Closing as this is a user issue. No change needed in Intero.


Searching Specific Serial Number

Issue To Be Solved
There has to be a way to search a specific serial number, especially if there isn't any transaction history yet. How can I search search a specific serial number? For Example: If a player was born on 12286, and I want to buy that specific serial number, how can I search it to see who owns it? A lot of profiles will have their twitter accounts linked where I can talk to them about a specific moment.
Clicking on 'Circulating Count' and scrolling down would take over an hour. There has to be an easier way..? Please advise or consider this as an option for users.
Thanks,
CodePro

You can definitely do this with the topshot API (SearchMintedMoments with the play and set in the MintedMomentFilterInput) . Not sure about the flow sdk.


Put emphasis on the --swarm option in the documentation

After hours of trying to figure out what was wrong... things slowly clicked how this is all tied together.... Which led me back to the documentation, this line in the docs...
eval $(docker-machine env --swarm swarm-master)

I was thinking "wait a minute, if you have to point your environment to an instance of docker server and that server is running inside of a machine in a container with no port mapping, how the heck could it ever connect??? Oooooh snap. Look at that --swarm option I never noticed thus never typed thus never saw it working until right now." Face palm.
Thanks for making such a cool tool! I still don't understand how that --swarm option works...

I'd be happy to make a documentation pull request. Can someone point me to where that resides? I see three repos related to docs but none of them return results when search for the article I linked to on docs.docker.com.

Look in docs folder in this repo. That's the correct location.  Probably docs/reference/create.md


Misleading docs on increasing Consulo heap size (Mac)

I find the docs on increasing the Consulo heap size (found in tha F.A.Q.) a bit misleading.
Instead of editing idea.vmoptions in /Applications/Consulo.app/Contents/bin the should be copied to ~/Library/Preferences/ConsuloData where it should be edited to have any effect.
The docs found at jetbrains explains it pretty well.
All the above counts for Mac only. I can't tell how it works on a PC.

I am idk how it works. JB was changed their MacOS runner, and this change i am not merged (due i dont want break MacOS distribution)
As i known - any user can edit wiki

Anyone can edit the docs and if it's OK with you I will edit the docs whenever I have the time.

changed in Consulo 2.0. Doc updated


tf12 errors on parameter list format

For the tf12 parser the block syntax works as expected:
  parameter {
        name  = "tls"
        value = "enabled"
      }
  parameter  {
        name = "audit_logs"
        value = "enabled"
      }

But the list of objects returns a warning/failure condition for the same rule
  parameter   =
    [{
        name  = "tls"
        value = "enabled"
      },
      {
        name = "audit_logs"
        value = "enabled"
      }]

Per https://www.terraform.io/docs/configuration/attr-as-blocks.html this syntax is not recommended, but is still supported.
Assertion that works for blocks and fails for list of objects
    assertions:
      - some:
          key: parameter
          expressions:
            - and:
              - key: name
                op: eq
                value: tls
              - key: value
                op: eq
                value: enabled

I am able to reproduce the error and am working on a resolution. So far, looks like separate blocks are grouped together as a single block and then linted. Whereas a joined block that's already in that format isnt read correctly, and instead UNDEFINED is returned. Looking into why now.
In this example, fail_best has the working, separated block syntax and fail_alt has the failing, joined as a list block syntax.
  {
    "ID": "fail_best",
    "Type": "aws_redshift_parameter_group",
    "Category": "resource",
    "Properties": {
      "__name__": "fail_best",
      "__type__": "aws_redshift_parameter_group",
      "family": "redshift-1.0",
      "name": "fail_foo",
      "parameter": [
        {
          "name": "tls",
          "value": "disabled"
        },
        {
          "name": "audit_logs",
          "value": "enabled"
        }
      ]
    },
    "Filename": "./testdata/resources/attr_block_syntax.tf",
    "LineNumber": 33
  },
  {
    "ID": "fail_alt",
    "Type": "aws_redshift_parameter_group",
    "Category": "resource",
    "Properties": {
      "__name__": "fail_alt",
      "__type__": "aws_redshift_parameter_group",
      "family": "redshift-1.0",
      "name": "fail_bar",
      "parameter": "UNDEFINED"
    },
    "Filename": "./testdata/resources/attr_block_syntax.tf",
    "LineNumber": 48
  }


An error "inside" relabel_configs drops all metrics from a pod

What did you do?
A snippet from relabel_configs:
  - source_labels: [__meta_kubernetes_pod_annotation_XXX_metrics_port]
    action: replace
    regex: (.+)
    replacement: metrics
    target_label: __meta_kubernetes_pod_container_port_name
  - source_labels: [__meta_kubernetes_pod_container_port_name]
    regex: ^metrics$
    action: keep

What did you expect to see?
All metrics from a pod with XXX.metrics.port annotation are scraped.
(As worked up to 2.42.0 version (inclusive).)
What did you see instead? Under which circumstances?
No metrics from a pod.
After upgrade to 2.43.0.
System information
No response
Prometheus version
No response
Prometheus configuration file
No response
Alertmanager version
No response
Alertmanager configuration file
No response
Logs
Please, pay attention to:

https://github.com/prometheus/prometheus/blob/main/model/labels/labels.go#L492
https://github.com/prometheus/prometheus/blob/main/model/labels/labels.go#L519
https://github.com/prometheus/prometheus/blob/main/model/labels/labels.go#L535

Prometheus version
2.43.0
(I am sorry.)

What is the "error" from your title?
Also, I did not understand the "Please, pay attention to:" part.  Please explain again in a different way.

Can you provide the problematic set of labels that are dropped but should not, with the complete relabeling rules?

Hi, I'm sorry for being so monosyllabic.
Further info is as follows:

What is the "error" from your title?

Well, I'd presumed when all metrics were gone after the upgrade and the Target Labels read Dropped within the Service Discovery view (Prometheus) there could be something wrong with relabeling.

Also, I did not understand the "Please, pay attention to:" part. Please explain again in a different way.

There was a small misunderstanding with a colleague of mine over here, I C&P wrong links, sorry for that.
FMPOV I can see some inconsistency at
https://github.com/prometheus/prometheus/blame/release-2.43/model/labels/labels.go#L592
vs.
https://github.com/prometheus/prometheus/blame/release-2.43/model/labels/labels.go#L534
What if there's a same label within both add and del arrays?
TBH, the Set() function
https://github.com/prometheus/prometheus/blame/release-2.43/model/labels/labels.go#L517
seems suspicious to me as well - it ignores the del array and just sets the add array, but it might be just my ignorance.

Real use cases for the snippet
  - source_labels: [__meta_kubernetes_pod_annotation_XXX_metrics_port]
    action: replace
    regex: (.+)
    replacement: metrics
    target_label: __meta_kubernetes_pod_container_port_name
  - source_labels: [__meta_kubernetes_pod_container_port_name]
    regex: ^metrics$
    action: keep

as follows:
When there is the Discovered Label __meta_kubernetes_pod_annotation_XXX_metrics_port="9091" set
2.42.0: metrics are scraped
2.43.0: no metrics.
When there are both Discovered Labels __meta_kubernetes_pod_annotation_XXX_metrics_port="9091" and __meta_kubernetes_pod_container_port_name="metrics" set,
2.42.0: metrics are scraped
2.43.0: metrics are scraped.
When there is the Discovered Label __meta_kubernetes_pod_container_port_name="metrics" set,
2.42.0: metrics are scraped
2.43.0: metrics are scraped.

As for

... MPOV I can see some inconsistency at...

metioned above, we've tested steps:

Del("LABEL")
Set("LABEL")

from Get("LABEL") we've got nothing, from Labels(...) we've got the label LABEL.

OK, now I see, if you call Del followed by Set of the same label name, then Builder will sometimes not return the value.
That was unintended.

At #12322 I tried to create the problem based on the relabeling rules you quoted, but I had to add something at the beginning to do the initial Del().  If you can see what I missed from the context of your rules, or your study of the code, please let me know.

@hawran are you able to test with the new 2.44 release candidate? https://github.com/prometheus/prometheus/releases/tag/v2.44.0-rc.1 ?

At #12322 I tried to create the problem based on the relabeling rules you quoted, but I had to add something at the beginning to do the initial Del(). If you can see what I missed from the context of your rules, or your study of the code, please let me know.

Well, I've pasted just a little snippet from somewhere in the middle of a much bigger relabel_configs section.
The Del("__meta_kubernetes_pod_container_port_name") function is called internally by prometheus.

@hawran are you able to test with the new 2.44 release candidate? https://github.com/prometheus/prometheus/releases/tag/v2.44.0-rc.1 ?

We've upgraded to 2.43.1 and it seems to be OK now, thank you.

The Del("__meta_kubernetes_pod_container_port_name") function is called internally by prometheus.

Do you know any more about how this comes about?  I just want to make sure my test case is accurate.

We've upgraded to 2.43.1 and it seems to be OK now, thank you.

That's great.  I think we will leave this issue open until the fix is merged to main.

Would you mind if I re-titled this issue to "Relabel rules: a label that is deleted then set will read back as empty" ?
To me, this is a clearer description of the bug, and should make it easier for others to find in future.

Would you mind if I re-titled this issue to "Relabel rules: a label that is deleted then set will read back as empty" ? To me, this is a clearer description of the bug, and should make it easier for others to find in future.

No problem, feel free to change the title as you need.

Fixed by #12322


Approach to make building this pipeline easier than previous data release ones

Sticking points in the past:

Knowing which target was built from which system (local? Yeti? Tallgrass?) and which repo (lake-temperature-model-prep? lake-temperature-process-models? lake-temperature-out?).
A single individual being able to build all the targets in the repo, especially.

For this reason, I'd like to propose getting the targets from the various repos into this data release repo differently than before. Here's what I am thinking:

We have a different makefile for each repo that contains files we need to gather in this data release (e.g. 1_lake_temperature_model_prep_targets, 2_lake_temperature_process_models_targets, and 3_lake_temperature_out_targets), and all those targets are ultimately pushed up to SB using the targets in remake.yml (example data release target pushing to SB).
Build this pipeline in a shared space, like Tallgrass.
Use file.copy() to make targets that copy files from other repos into this one in our repo-specific makefiles. Use a dummy date per repo makefile to kick off the file copying and update the files in this pipeline only when necessary. This would allow some people to still build everything in the repo, even if they couldn't build the file.copy() step.

My only hesitation is that I am not sure how #3 will work for repos built locally ...

Item created: https://www.sciencebase.gov/catalog/item/6206d3c2d34ec05caca53071