Rewrite the synthetic Go branch as master.

This enables legacy go get support, as well as vanilla go get with
modules. In theory, one should now be able to run:
go get gvisor.dev/runsc
go install gvisor.dev/runsc

And this should be always up-to-date.

It looks like the go get paths in the commit message are out of date.

This seems a bit complicated? We could just make the real master branch the generated code and move development to the "dev" branch. That makes things easy for users, and not much harder for developers.
GitHub can even be configured to show the "dev" branch by default and have git clones default to that branch: https://help.github.com/en/articles/setting-the-default-branch I just double checked that it works for git clone.

@prattmic, we could also just make a separate repository for the go getable version. We could even host it on googlesource.com given that we are going to be using the redirect.

Yeah, I got nerd sniped on this and just wanted to make it work. Let's explore the ideas a little bit.

GitHub can even be configured to show the "dev" branch by default and have git clones default to that branch: https://help.github.com/en/articles/setting-the-default-branch I just double checked that it works for git clone.

Unfortunately the default for git clone is the problem here. That would also make the dev branch be the one that go get refers to by default. (See the clone call in this file.)
I'd rather not maintain two different repositories, if we can help it. Let's think on it for a while.

I've updated the code here and made it much cleaner and more maintainable.
Effectively this target will simply change the default branch to the go branch. I think this is actually the best way to support go get while minimizing the number of repositories that we need to maintain. I don't rewrite any references here or drop anything. You can still develop from the checked out repository, assuming you checkout master.

The title is still "Rewrite the synthetic Go branch as master." Is that still accurate?

I've decided to delay this pull request in favor of #78. I'll leave it here for a while, but since we need go modules anyways, I don't think there's a huge amount of value in this indirection.

Don't we also need a simpler gvisor.dev/gvisor redirect?

So here's the summary:
The vanity package will never work with vanilla go get. It's because that will pull all the package dependencies from tip, and there are some fundamental things broken with that.
Since that's the case, go modules are essentially required. So I think I'll just leave things the way they are. You'll need to specify the go branch to use go get, but that should make it clear that's special and not a generally supported route.


[$500] [Held requests] Expense preview turns to skeleton after approving & paying request offline

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Version Number: 1.4.58-2
Reproducible in staging?: y
Reproducible in production?: n
If this was caught during regression testing, add the test name, ID and link from TestRail: n/a
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: applause internal team
Slack conversation:
Action Performed:
Precondition:

Admin and employee are in the Collect workspace.

[Employee] Request money from the workspace chat.
[Employee] Create two money requests.
[Employee] Hold one of the requests and leave the other one unheld.
[Admin] Go to expense report.
[Admin] Go offline.
[Admin] Click Approve button.
[Admin] Approve the unheld request only and pay with expensify for the unheld request.
[Admin] Go online.
[Admin] Return to the paid expense report.

Expected Result:
When returning online, the expense preview will not show skeleton loading.
Actual Result:
When returning online, the expense previews disappear and turn to skeleton loading.
Workaround:
unknown
Platforms:

Which of our officially supported platforms is this issue occurring on?

[ ] Android: Native
[ ] Android: mWeb Chrome
[ ] iOS: Native
[ ] iOS: mWeb Safari
[x] MacOS: Chrome / Safari
[ ] MacOS: Desktop

Screenshots/Videos
Add any screenshot/video evidence
https://github.com/Expensify/App/assets/38435837/4425da13-4cb7-4d6d-8ebc-4e074ad07991

View all open jobs on GitHub
Upwork Automation - Do Not Edit

Upwork Job URL: https://www.upwork.com/jobs/~01b2d44a97bebec012
Upwork Job ID:<PHONE_NUMBER>241303040
Last Price Increase: 2024-04-22

This is a pretty involved flow, so I don't think we should block on it. @greg-schroeder let's take this through the normal bug process

Okay, pending proposals and added to #wave-collect

No proposals

Still pending proposals

Same as above

Waiting for porposals

@MelvinBot I am investigating the issue. Will submit proposal soon.

No overdue. Proposal coming soon

This is unable to reproduce.

Seems CS is going to take this

I've tried to reproduce the bug. I was not able to do it. Looks like it works properly. Can you try on your end?
Video

https://github.com/Expensify/App/assets/57314631/2a43268a-8055-4015-b764-ff9e1ebd2f89

Hmm, I think it may have been fixed at some point. I'll close for now, but reopen if you disagree or are able to reproduce this.


Provide an easy way to download files

Expected Behavior
Downloading arbitrary files should be provided out of the box by Gradle. Configuring it should be easy and straight forward. Gradle should take care of deciding whether a file needs to be (re-)downloaded because it has changed, and Gradle should handle storage and retrival from the store location.
Basically there should be something similar to download Maven dependencies, but more flexible, not tied to something that has a GAV and dependency metadata.
Current Behavior (optional)
There are ways of doing this but they are cumbersome for one or the other reason:
Custom task using HTTP client

Requires ceremony in they build in order to build that custom task. You either need to put it into your build script or you need a place like buildSrc or an included build to build the task.
When running on Java < 11 you need external libraries to get access to an HTTP client
Pretty low level, you need to configure the client, provide authentication, deal with different errors, etc.
Storing efficiently is difficult. Either you download to the build folder which will cause the file to be downloaded for task registration, or you download into a central location such as Gradle user home, which requires locking in case multiple task instances execute at the same time.

Community plugins such as de.undercouch.download
This is probably the most commonly used plugin for downloading things. It provides tasks and services for downloading files.

Still suffering from the storage problem. You need to decide where to put the file and if you need it in multiple places in the build, you need to register multiple tasks and work out how to make sure it's only downloaded once.

Modeling downloadable resources using Ivy repositories
Another way of doing this is bending dependency management to work with arbitrary resources. The way this works is using a Ivy repository with exclusiveContent filtering and using a pattern layout to describe the download Url. Here is an example for downloading the Trivy docker image scanner binary that way:
val os = OperatingSystem.current()

val driverOsFilenamePart =
    when {
        os.isMacOsX && os.nativePrefix.contains("aarch64") -> "macOS-ARM64"
        os.isMacOsX && !os.nativePrefix.contains("aarch64") -> "macOS-64bit"
        os.isLinux && os.nativePrefix.contains("arm64") -> "Linux-ARM64"
        os.isLinux && os.nativePrefix.contains("64") -> "Linux-64bit"
        else -> "Linux-32bit"
    }

val trivyVersion = "0.45.1"

repositories {
    exclusiveContent {
        forRepository {
            ivy {
                url = uri("https://github.com/aquasecurity/")
                patternLayout {
                    artifact("[module]/releases/download/v[revision]/[artifact]_[revision]_[classifier].[ext]")
                }
                metadataSources {
                    artifact()
                }
            }
        }
        filter {
            includeModule("aquasecurity", "trivy")
        }
    }
}

val trivy by configurations.creating {
    isCanBeResolved = true
    isCanBeConsumed = false
    attributes.attribute(ArtifactTypeDefinition.ARTIFACT_TYPE_ATTRIBUTE, ArtifactTypeDefinition.DIRECTORY_TYPE)
}

dependencies {
<EMAIL_ADDRESS>}

This also deals with the fact that there are different binaries per operating system. Furthermore it uses an artifact transform to unpack the downloaded tar.gz.
Again there's a lot of ceremony to do something that should be easier.
Context
We use this most of the time to download binaries that we then pass to Exec tasks for execution. That way we don't need our engineers to install all of these binaries on their machines.

This feature request is in the backlog of the relevant team and is prioritized by them.

Here are two more options, neither of which are great, but I'm listening them here for exhaustiveness and to emphasise that Gradle is too confusing.

Ant Get
Ant Get task can be used to download files.
It's nice that it's included with Gradle, and that it can be used on demand without much ceremony, but not great. It's not type safe, annoying to cache. Adding advanced features like checksum validation or ETags is theoretically possible but not easy.
val downloadGradleReadme by tasks.registering {
  val gradleReadmeUrl = "https://raw.githubusercontent.com/gradle/gradle/master/README.md"

  inputs.property("gradleReadmeUrl", gradleReadmeUrl)

  val outputDir = temporaryDir
  outputs.dir(outputDir).withPropertyName("outputDir")

  doLast {
    val destinationFile = outputDir.resolve("readme.md")

    ant.withGroovyBuilder {
      "get"(
        "src" to gradleReadmeUrl,
        "dest" to destinationFile,
      )
    }

    logger.lifecycle("Downloaded Gradle README: ${destinationFile.readText()}")
  }
}

ResourceHandler
ResourceHandler can be used to download files.
It can be convenient in build scripts, but it's buggy, it can only download some files, it's not @Injectable for use during task execution, and causes cache misses because Gradle generates a random file name.
val gradleReadme: TextResource = resources.text.fromUri(
  "https://raw.githubusercontent.com/gradle/gradle/master/README.md"
)

val downloadGradleReadme by tasks.registering(Sync::class) {
  from(gradleReadme) {
    rename { "README.json" }
  }
  into("src/main/resources/gradle_data")
}

Honestly, I've thought of how npm allows for custom script execution and how all those end up in dev dependencies...
to expand on this... allowing arbitrary downloads and putting them somewhere might consider allowing a similar progression of "off classpath" "script" execution. That in and of itself would be another feature, but might be worth keeping in brain.

We agree this is a useful feature for build tools to have.

Another aspect to consider: quite often it's necessary to download more than one file per Gradle project. If it's necessary to create multiple Gradle tasks to download multiple files, then download will happen one by one, unless "configuration cache" feature is enabled.
It would be nice to have support of parallel downloads even without "configuration cache".


Register this as a package that can be installed via Bower

A bower.json file needs to be added and registered to Bower so this plugin can be installed via Bower.
http://bower.io/docs/creating-packages/

Added a bower.json with commit d2ccbbdd66596bc3628f44411d560ca1e3bc2ce1, and registered as jquery-selectability.


[Azure DevOps] Refactor error handling to be more consistent

Hey, I just made a Pull Request!
Refactor error handling to be more consistent based on comment in previous PR: https://github.com/backstage/backstage/pull/19616#discussion_r1368518517
:heavy_check_mark: Checklist

[x] A changeset describing the change and affected packages. (more info)
[ ] Added or updated documentation
[x] Tests for new functionality and regression tests for bug fixes
[ ] Screenshots attached (for UI changes)
[x] All your commits have a Signed-off-by line in the message. (more info)

Ready for merge or another review 🚀

Thanks @freben and @Rugvip 🚀


Small Bug in Firefox with the Icon.

The Icon is to big on the toolbar...   Icon is kind of stretched veritcally.
The Icon is 22 pixels High and should be max 20 pixels  (standard is 20X20 Pixels for the toolbar)
http://i.imgur.com/DoFChZk.png

:hushed:
I'll try to fix.

Mmh was that fixed back in the day? I'll close this, feel free to comment if this is not fixed.


[FLINK-24506][config] Adds checkpoint directory to CheckpointConfig

This enables the user to pass in the checkpoint directory through the Flink
configuration again. This fixes an issue that was introduced by FLINK-19463.
What is the purpose of the change
This fixes an issue where the checkpoint directory couldn't be set anymore through the Flink configuration. See a more detailed description in the ticket FLINK-24506
Brief change log

Adds the state.checkpoints.dir to CheckpointConfig.configure

Verifying this change

A test was added to the corresponding CheckpointConfigFromConfigurationTest

Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): no
The public API, i.e., is any changed class annotated with @Public(Evolving): yes
The serializers: no
The runtime per-record code paths (performance sensitive): no
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: yes
The S3 file system connector: no

Documentation

Does this pull request introduce a new feature? no
If yes, how is the feature documented? not applicable

I transformed the test to use AssertJ. Additionally, I migrated the test to JUnit5.

@flinkbot run azure


Created prelim yaml file for PortalPublication

Created a quick yaml file for PortalPublication

Made the requested changes but got error 127 when running make PortalDataset


Video: Blockchain

Blocked by #60
Use the blockchain script and slides to record a video lecture for General Blockchain information.

This was finished sometime ago, and the issue was never closed:

slides
videos


Prepare for using new bech32 release

In preparation for depending on the recently released version of rust-bech32 do a bunch of preparatory fixes.

Improve address module error handling as we are doing else where at the moment
Remove bip 173 and 350 test vector tests, these are fully covered in bech32
Trim down the docs on WitnessVersion

This PR is the first 8 patches of https://github.com/rust-bitcoin/rust-bitcoin/pull/1951

Rebase only, no other changes.

Rebased to pick up recent pinning fix, no other changes.

This PR is basically just refactoring and a some improvements to error handling. It has been open for over a month with an ack from @apoelstra. Other activity was partial review by @sanket1729 and all his concerns were explicitly ok'ed by him above.
As such it is a candidate for the "refactor carve-out" and may be merged at any time.


Add popover components

Types of changes

[x] New feature (non-breaking change which adds functionality)
[x] I have read the CONTRIBUTING document.
[x] My code follows the code style of this project.
[x] My change requires a change to the documentation.

[x] I have updated the documentation accordingly.

[x] I have added tests to cover my changes.
[x] All new and existing tests passed.

Adds Popover, PopoverContainer components.
Resolves #37

Codecov Report

Merging #40 into master will increase coverage by 0.1%.
The diff coverage is 100%.

@@            Coverage Diff            @@
##           master      #40     +/-   ##
=========================================
+ Coverage   98.09%   98.19%   +0.1%
=========================================
  Files          36       38      +2
  Lines         315      333     +18
=========================================
+ Hits          309      327     +18
  Misses          6        6

Impacted Files
Coverage Δ

src/Popover/PopoverContainer.js
100% <100%> (ø)

src/Popover/Popover.js
100% <100%> (ø)

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 822b0f6...2442d33. Read the comment docs.


[ESP32] Server the file requested in file designator

Problem

Fixes #15757
OTA-Provider crashes if file designator is invalid

Change overview

Server the file requested in file designator
Fixed the crash

Testing

Tested using Linux OTA-R and ESP32 OTA-P

Fast tracking, given this has had enough time for review (> 3 days)

/rebase

/rebase


WFS 2.0 StoredQueries bugfixes/improvements

Repaired wfs.storedqueries (crash because of wrong timeout variable)
Repaired wfs.storedqueries (crash if storedquery has no abstract)
Added WFS 2.0 StoredQuery example
Added WFS 2.0 StoredQuery test

tests/doctests/csw_gdp.txt does fail because of HTTP 404.
Issue is not in association with this PR.


Edit button disappears in preview if body is overwritten

The edit button should be more resilient in preview mode - is gone here

Fixed


Error: Cross-device link (os error 18)

Ubuntu 22.04.02 LTS, railway installed via curl -fsSL https://railway.app/install.sh | sh
I have different physical disks for "/" and "/home"
I cannot login either with railway login or railway login --browserless
Both fail with
Error: Cross-device link (os error 18)
I attempted to copy the railway binary to the same physical disk as the ~/.railway directory  but this did not work.
I copied the binary back to the root file system and symlinked ~/.railway to the root file system physical disk, this too did not work.
It would seem the the linux mv tool works around this same problem. A failed rename() call hitting error 18 it falls back to a copy.

@gazhay this should be fixed in #403 and released in the latest version. Can you confirm if this still happens? Thanks!


Encouraging use of stable

Removing the --pre flag.
I can add another section with the original text referring to "latest" if you want.

Not sure how those got there.


local file does not run javascript

I loaded a local file (file:///C:/test/html), but the script did not run, just like the most simple alert function does not run, what is the reason?

Please try this way: string url = Application.StartupPath + @"\html\main.html";


New release

1 Upvote Any chance to release a new version? We are looking for the latest hls.js

👍

@leandromoreira will it be today?

done ! https://github.com/clappr/clappr/releases/tag/0.2.56


Pass the correct for_update value for get_form_class in SnippetViewSet's edit views

Fixes #10438.
Please check the following:

[x] Do the tests still pass?[^1]
[x] Does the code comply with the style guide?

[x] Run make lint from the Wagtail root.

[x] For Python changes: Have you added tests to cover the new/fixed behaviour?

[^1]: Development Testing
[^2]: Browser and device support
[^3]: Accessibility Target

Merged in 188bbbb0c5f93aeebb23e7148ec061d246dd4e41 (main) and 854956705b (stable/5.0.x).


Is there a way to specify start and end page, or page range?

Hi @dbkaplun
PDFKit is just a wrapper around wkHTMLtoPDF, which has documentation here: http://wkhtmltopdf.org/usage/wkhtmltopdf.txt
It looks like you'll want to use the "--page-offset" option to set a start page. You would set that like this:
PDFKit.new('html', page_offset: 5)
You can also set that option in the configuration file or in each HTML source with meta tags.
After a first glance, I don't see a way to say the last page or to set a range in the wkHTMLtoPDF options, but that's an issue for you to follow up with wkHTMLtoPDF.


Expo strategy extend to use app.config.js(ts) file in addition to app.json

Latest version of Expo allows to use dynamic config file such as app.config.js(ts) instead of app.json. Here is documentation link https://docs.expo.dev/versions/latest/config/app/
In essence this is superset of app.json and has very similar structure for versioning e.g.
.....
export default {
  expo: {
    name: NAME,
    slug: SLUG,
    privacy: "unlisted",
    platforms: ["ios"],
    version: "1.0.0", // x-release-please-version
    orientation: "portrait",
    scheme: SCHEME,
    icon: "./assets/icon.png",
    updates: {
      fallbackToCacheTimeout: 30000,
      url: URL
    },
    assetBundlePatterns: ["**/*"],
    ios: {
      bundleIdentifier: IDENTIFIER
      supportsTablet: true,
      buildNumber: "1.0.0", // x-release-please-version
      runtimeVersion: {
        policy: "sdkVersion",
      },
    },
    description: DESCRIPTION
    extra: {
      eas: {
        projectId: PROJECT_ID,
      },
    },
    owner: "OWNER",
  },
};

Is your feature request related to a problem? Please describe.
When using dynamic config file app.config.js(ts) version is not being updated, unless tagging lines with version using x-release-please-version and adding app.config.js(ts) as an extra file.
Describe the solution you'd like
No need to use extra configuration with extra file.
Describe alternatives you've considered
Adding extra file with target lines works just fine.
Additional context
If you are using release please github action v4 and it's not picking up extra file, consider this undocumented behavior.

Though, now I'm thinking, for the dynamic files it might be more efficient to get version from imported package.json. Might be just worth mentioning in the docs.


Push API Queue, Source, and Index creation

Right now the push api queue lifecycle does not work. We need a solid story to explain when a queue is created, when it is deleted, and when push API source is created, what happens when an index is removed etc.
The behavior should probably be::
PushAPI Creation
We stop opening all column family from rocksdb.
When a doc is pushed to an unknown index ( queue id), The pushapi should check for the existence of the index from the metastore.
If not here, an error should be returned.
If here a queue should be created.
Upon queue creation or queue open, we spawn an indexing pipeline.
Upon index deletion (as received by the metastore)????
We need some spec.

@fulmicoton  in relation to the closed task, we will not have any determinism when index is deleted. We could just use the Gc actor to remove the queue when the index is gone.
An issue thought is the metastore fetch error will not necessarily mean index is deleted, it can be other things

Suggestion (you are closer to the problem than me).
To do GC, we need to have a function that lists queues lists queues, list indexes (in that order) does the diff, terminates  existing pipelines and deletes the extra numerous queues.
For this version, maybe we can do that in a GC actor that would run once every hour.
No need to do something super great.

Tricky stuff to handle:

what happens to a running pipeline?


fix: dotenv loading

Small update to the way dotenv loads config.
require('dotenv').load()

threw an error, apparently this is the new way they want it done.

Hi @ndom91
Thanks for the PR and sorry for taking so long to get back to you, things were on hiatus for a bit.
NextAuth 2.0 should drop soon, am going to leave this open as a reminder to include this usage example in the client code when it comes out.
Appreciate this as I've not updated my usage of dotenv in a while and must have missed this change!

Hey @iaincollins good to see your back and active in this project :)

I don't think there will be another release of 1.x at this point as 2.0 should be out soon but I'm going to merge this in and close off the PR. Thanks again for raising it, sorry it wasn't accepted sooner.


Module white

Hi, do you still get the "map" in the module? Mine gets completely white after the first "position update".
When I (re)start the mirror, all looks well:

Then I send the first coordinate update and it looks like this:

Do you have the same problem?
I have the latest version of MM. I have the same behavior on my "Dev" MM with only (default clock) and MMM-Remote-Control (to be able to send data to the module(s)) and this module enabled...

Hi, I got the same issue here. I will work on a solution quick as possible.

It's working again for me without any changes. Can you confirm? Must have been an issue in the google javascript sources

Indeed it is! Great! I had to restart my MM (pm2 restart MagicMirror) then it worked again. :)

Hi again, it's been a while... :)
This is happening again for me now... Do you have the "white" issue as well again?


Bug in UniformRandomMetaPathWalk

Hi @youph
this is a fix for the bug in issue #340. It is a simple fix. Can you have a look?
Regards,
P.

Thanks @youph
P.


 Got error FileNotFoundError: [Errno 2] No such file or directory: 'docker-compose', but file is existing in .devcontainer dir
To Reproduce
scargo new {project_name} --target stm32
scargo docker run
scargo update

Logs
job@69e3e15325b0:/workspace$ scargo update
/usr/local/lib/python3.8/dist-packages/requests/__init__.py:109: RequestsDependencyWarning: urllib3 (2.0.0) or chardet (None)/charset_normalizer (3.1.0) doesn't match a supported version!
  warnings.warn(
scargo INFO: Generated /workspace/.devcontainer/docker-compose.yaml
scargo INFO: Generated /workspace/.devcontainer/devcontainer.json
scargo INFO: Generated /workspace/.devcontainer/Dockerfile
scargo INFO: Generated /workspace/CMakeLists.txt
scargo INFO: Generated /workspace/conanfile.py
scargo INFO: Generated /workspace/tests/conanfile.py
scargo INFO: Generated /workspace/.gitlab-ci.yml
scargo INFO: Generated /workspace/tests/CMakeLists.txt
scargo INFO: Pulling the image from docker registry...
Traceback (most recent call last):

  File "/usr/local/bin/scargo", line 8, in <module>
    sys.exit(cli())

  File "/usr/local/lib/python3.8/dist-packages/scargo/cli.py", line 441, in update
    scargo_update(config_file_path)

  File "/usr/local/lib/python3.8/dist-packages/scargo/commands/update.py", line 102, in scargo_update
    if not pull_docker_image(docker_path):

  File "/usr/local/lib/python3.8/dist-packages/scargo/commands/update.py", line 111, in pull_docker_image
    result = subprocess.run(

  File "/usr/lib/python3.8/subprocess.py", line 493, in run
    with Popen(*popenargs, **kwargs) as process:

  File "/usr/lib/python3.8/subprocess.py", line 858, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,

  File "/usr/lib/python3.8/subprocess.py", line 1704, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)

FileNotFoundError: [Errno 2] No such file or directory: 'docker-compose'

cargo update actually is working inside the docker but do not update the docker itself (it will be then docker in docker). However, all file should be appropriately updated inside the docker. Propose a solution: we will skip the docker build/update step when the user is running scargo update from the docker so the error message will not pops up

Fixed in #233


Enhanced instructions for Game On devs.

Signed off by : Adam Pilkington<EMAIL_ADDRESS>

This change is

Review status: 0 of 1 files reviewed at latest revision, 2 unresolved discussions.

README.md, line 61 [r1] (raw file):

  env file suitable for use with docker-compose (whether you're using docker-machine or not).

./go-setup.sh

go-build.sh is fine for first pass, won't harm, won't build. Otherwise similar to go-setup.sh.

README.md, line 94 [r1] (raw file):

   required for local development).

./go-build.sh

go-rebuild.sh ?

Comments from Reviewable

Reviewed 1 of 1 files at r1.
Review status: all files reviewed at latest revision, 2 unresolved discussions.

Comments from Reviewable

I believe this means that we can consider removing go-build.sh, and allow go-setup.sh and go-rebuild.sh to handle things.

Reviewed 1 of 1 files at r2.
Review status: all files reviewed at latest revision, 2 unresolved discussions.

Comments from Reviewable


can_delete for inline forms

I want to hide "Delete?" checkbox.

You can just copy the model/inline_list_base.html from flask-admin to your
project's templates/admin folder and delete the
Delete?
Also delete the follow line

And then
On Thu, 22 Mar 2018 at 16:42 Alexander Schepanovski <
<EMAIL_ADDRESS>wrote:

I want to hide "Delete?" checkbox.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/flask-admin/flask-admin/issues/1621, or mute the
thread
https://github.com/notifications/unsubscribe-auth/AABYGpMsvV90aPl8qN_AwzY0SglckXFdks5tg2QBgaJpZM4S2pkm
.


Create AVAILABLE_COMMANDS.md

please review for merge

let's just get this file added, changes/additions can be made in github via edit.

@joker314 Let's make the corrections in #70 so that way both corrections to grammar are in one commit and file addition is separate.

@joker314 it's very easy to edit text files in github without downloading them and editing locally. Just select the file and then select edit. After changes are made you can either submit as a PR or do it without a PR. I used a PR this time because it is adding files to the master branch. Going forward we shouldn't need a PR to edit the file unless the person editing is making some significant changes, like redoing the entire content or reformatting the document in some way. Simply adding a command to the document shouldn't require a PR as long as the currently established format is adhered to.

The point is that if you change the code, you always have to change the markdown file.  These changes should, of course, be included as commits in the pull requests that change the wording (note, we should never push to master without two approvals, no matter how trivial a change?). However, it could save some effort if a command line tool added the second change for you.

Documentation isn't code that affects the operation of the bot.
you are wanting to approve from the command line? You can do it, but it's more complicated and I'm not sure it's scriptable. I know it's conceivable that some people don't have their browser open all the time...
In a nutshell, if you add something to the md files, make sure you know what you are doing and follow the current format. Conversely we could have roles, i.e. people that are maintainers of docs etc. which isn't a horrible idea in my opinion

I'm not wanting to approve from the command line.
I want a tool (like a command "build docs") that I can run in the command line. This will scan all the command descriptions for changes, and reflect those changes in the docs file too. shrugs


TILA-45 | Resolve deprecation warnings

Implement REST/GQL API's
Resolve deprecation warnings

This is more of a discussion starter about coding standards, than comment on this pull request. How do people feel about using type hints? How about using some fluent assertion library for testing, for example assertpy or something similar, imo it makes tests more readable, easier to do soft asserts when needed etc.


⚠ ESPN has degraded performance

In 30d7cbb, ESPN (https://espn.com) experienced degraded performance:

HTTP code: 200
Response time: 553 ms

Resolved: ESPN performance has improved in 8c47351.


Update New-CSTeamsShiftsPolicy.md

Include new setting EnableScheduleOwnerPermissions.

Docs Build status updates of commit 47298c2:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

teams/teams-ps/teams/New-CsTeamsShiftsPolicy.md
:white_check_mark:Succeeded
View (teams-ps)

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Docs Build status updates of commit e3e238d:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

teams/teams-ps/teams/New-CsTeamsShiftsPolicy.md
:white_check_mark:Succeeded
View (teams-ps)

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Docs Build status updates of commit 1a366d1:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

teams/teams-ps/teams/New-CsTeamsShiftsPolicy.md
:white_check_mark:Succeeded
View (teams-ps)

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel


Remove moment dependency

Describe the solution you'd like
oment.js is no longer being actively developed or maintained as of 2020
Describe alternatives you've considered
community recommends switching to more modern date libraries like Luxon, Day.js, or JavaScript's native Date and Intl.RelativeTimeFormat classes for new projects.
Additional context
It would be preferable to not require any additional dependencies

fixed in #31


Added german, spanish and french localization

Are there any requests for specific languages at the moment? German and spanish are my main ones so that was a fly for me, the french one was basically a copy/paste from jquery locals. Apparently I could do a bunch more of these just converting those.

I'm generally aiming for top 10-15 languages.
Feel free to contribute more if you have time, localization help is very much appreciated :+1:

French is good.
Why not include firstDayOfWeek in translation?
Like in French, Weeks start on Monday :
flatpickr.init.prototype.l10n.firstDayOfWeek = 1;

Why not include firstDayOfWeek in translation?

Certainly possible. Feel free to make pull requests


Try and throw if method names aren't valid

Fixes #494

Maybe just check the method names are not empty and not the arguments length, as php will throw it's own error. The issue in #494 is that no versions are tagged with the latest shouldReceive signature but now it requires 1 argument minimum then php itself will of course raise an error.


Do not allow users to enter non-alphanumeric characters in Code or Group names for cohort

On 1/24/19 Maggie created a cohort with the same name for code, descr, and group: "Women's Basketball." An error occurred because of the apostrophe.
Note from Matthew:
The error in the log is
NoReverseMatch: Reverse for 'cohort-members' with arguments '(u"Women's Basketball",)' not found. 1 pattern(s) tried: [u'manage/cohorts/(?P<code>[\\s\\w-]+)/members/$']
Was this a recent cohort that was added?
I fixed this by renaming "Women's Basketball" to "Womens Basketball"
It looks like there is pretty bad error with Student Explorer if you add a Cohort with special characters in the code. Especially apostrophe. It appears to be working for me now. We'd have to implement do a fix to support this or (probably easier) implement a fix to not allow these characters in the code.
SET FOREIGN_KEY_CHECKS=0;
UPDATE `student_explorer`.`management_cohort` SET `code` = 'Womens Basketball' WHERE `management_cohort`.`code` = 'Women''s Basketball';
UPDATE `student_explorer`.`management_studentcohortmentor` SET `cohort_id` = 'Womens Basketball' WHERE `management_studentcohortmentor`.`cohort_id` = 'Women''s Basketball';
SET FOREIGN_KEY_CHECKS=1;

The only acceptable inputs are alphanumeric, space, and dash.

Ignore comment, I think we're good


Switch to coiled-runtime default envs forn non-latest runs

Follow up from https://github.com/coiled/coiled-runtime/pull/70 tackling https://github.com/coiled/coiled-runtime/pull/70#pullrequestreview-944881051
Trying to use the environments generated with the software-environments.yml GHA

@jrbourbeau and I chatted about not using an env variable and parsing the version of the coiled-runtime for the soft-envs I tried what we discussed but something is not quite working for the case of latest.

Sounds good to me. Thank you @jrbourbeau!


JSON schema validation seems not to be applied to insertGraph()

I'm trying to control the insertion of data by using JSON schema validation. I created a custom Ajv validator on my model according to this recipe to supply custom options, i.e. removeAdditional: "all".
When I use insert() with intentionally wrong data (containing a field/column not existing on the table) for testing, additional fields not specified in the schema are removed from the query as expected, and the insert is executed.
When I use insertGraph(data, { relate: true }) with the same data, Objection fails with an error like DBError: <query> column "<additional_field>" of relation "<name>" does not exist, i.e. a database error. It seems like the validation is not done at all, although insertGraph() is listed in the docs as a function triggering the validation. Is that expected behavior?

Data passed to insertGraph does get validated.


Create a gh-pages site

GitHub can automatically create a website for a user, project, or organization.  It's called "github pages"  For openssl it would be "openssl.github.io"  That should be a simple repo with one file, index.html, that redirects to the official OpenSSL website.
Please take a look at https://github.com/richsalz/openssl.github.io and consider using it.

... why do we need this?

In my experience folks who look at github.org/FOO are getting more trained to look at FOO.github.io
And the cost, once you create the repo, is zero.

And here I thought that people read the README, and possibly clicked on URLs found there.
It's not like I really mind, but I do get worried about yet another thing to keep in mind, even if it looks like a one time easy peazy thing now
So I'm agnostic to the idea, other @openssl folks will have to speak their mind

That should be a simple repo with one file, index.html, that redirects to the official OpenSSL website.

Good idea. It takes the name away from potential squatters of the OpenSSL name.

There seems no enthusiasm for this idea at the moment. Closing.


Unresolved "any" is not "any"

Bug Report

🔎 Search Terms

any, unresolved
🕗 Version & Regression Information

This changed between versions 5.0.4 and 5.1.3

⏯ Playground Link

Playground link with relevant code
💻 Code

type IsAny<T> = boolean extends (T extends never ? true : false) ? true : false;
type PickNotAny<A, B> = IsAny<A> extends true ? B : A;

// @ts-ignore
type a = import('vue').GlobalComponents
//   ^?

type GlobalComponents =
//   ^?
	// @ts-ignore
	PickNotAny<import('vue').GlobalComponents, {}>

type GlobalComponents2 =
//   ^?
	// @ts-ignore
	PickNotAny<any, {}>

🙁 Actual behavior

¯_(ツ)_/¯
🙂 Expected behavior

They should not behave differently

Update: not right actually. Types include unresolved imports will be turned into any, no matter what they do. So a shorter demo: Link

Just for to make it clearer:
type IsAny<T> = boolean extends (T extends never ? true : false) ? true : false;

type A = IsAny<any>; // ✅ type A = true
type B = IsAny<import('vue').GlobalComponents>; // ❌ type B = any
type C = IsAny<import('vue').GlobalComponents & {}>; // ✅ type C = true

There are no specific guarantees on what happens when there is an error type in your program.

That's true. However, the type of it is literally any, but it doesn't behave like any.

Maybe you are right!
However I still prefer the former behavior. Typing it as any but it does not behave like any ismisleading. What's more, because volar imports the GlobalComponent interface from three different packages and the users maybe install one of them only (detecting whether they were installed without type system will increase workload), we rely on the former behavior to detect whether they were installed. If not, the interfaces are simply any and we can fallback to an empty interface. But in 5.1.3 we'll need a hack to fix that. In short, the old behavior is useful in some cases, but that in 5.1.3 is not intuitive.

My suspicion is that any check that requires a @ts-ignore in the source to work at all will never be a supported use case.  You are more or less in “undefined behavior” territory; here be dragons.


host manager checks GB vs MB resulting in incorrect home/network vs buy comparisons

Lines such as (maxRamPossibleToBuy < ns.getServerMaxRam("home") * homeThreshold) compare returns in GB for ns.purchaseServer() vs return in MB from e.g. ns.getServerMaxRam("home").
This means the server you want to purchase is being compared to 1024x higher thresholds etc.
e.g.
I have 32GB ram on home and I can buy 4TB servers.
ns.print(maxRamPossibleToBuy)
ns.print(ns.getServerMaxRam("home"))

logs:
4096
32768

This is likely an issue with the game, still as of 1.6.0 (getServerMaxRam() is supposed to return GB according to the manual), but host manager doesn't work correctly as it is right now. A simple temp fix is multiplying buy values during comparison by 1024 or dividing thresholds by the same.

I was looking at the wrong fields all this time and thinking I had 32GB home, while I have 32TB...


Push fleet-manager image tagged with latest

What would you like to be added:
Why is this needed:
From https://github.com/orgs/kurator-dev/packages/container/package/fleet-manager， we can see no fleet-manager image with tag latest.
But we have a github action here. https://github.com/kurator-dev/kurator/blob/main/.github/workflows/release-master.yaml
Need to take a look

@LiZhenCheng9527 Would you like to take a look

I'm glad to do it

#395

lgtm


Control researcher access on workspace and VM level

We would like to control researcher access on the workspace level and on the level of the virtual machine.
So, we would like for the researcher to be able to see the workspace,
and if we have e.g. 2 virtual machines in that workspace, we need to enable him to see and access a specific one of them.
Could you please advise how we could configure this?

@dusan-ilic-mhra the workspace enterprise application has the roles and users. A user will only see a workspace if they are assigned a role in the workspace (or defined globally as a treadmin)
A researcher will see only VMs (user resources) they created.
Is this what you meant?

Is this what you are after? To be able to create a VM as workspace owner for a user? So users don't/can't create their own VMs?
https://github.com/microsoft/AzureTRE/issues/1179

@tamirkamara Related to your question:
"A researcher will see only VMs (user resources) they created.
Is this what you meant?"
If we have 3 VMs in the workspace, and 3 researchers, we would like to set permissions so that each of them can see only their one dedicated VM, not everyone can see and access all the VMs. That's our point.

This is how it should work already.

But, in one workspace, not 3 VMs is 3 workspaces?

Right, in a single workspace a vm is only visible for the researcher that created it.

We have this user TRE_TEST_USER with roles:

Workspace Researcher - in WORKSPACE_API_CLIENT_ID

TRE Users - in API_CLIENT_ID

Workspace Owner created workspaces and VMs inside, and I'm logged in to Swagger with this user TRE_TEST_USER,
and I see 2  workspaces created by Workspace Owner/TRE Admin:

@tamirkamara We tested, and you were right, vm is only visible for the researcher that created it.
You can close the issue and if we experience it again we will open another one.
Thank you.


Remove DEQMAP_TRICHEM from SGID

Summary

Internal Dataset Name: SGID.ENVIRONMENT.DEQMAP_TRICHEM
External Dataset Name: opensgid.environment.deqmap_trichem
ArcGIS Online Url: https://utah.maps.arcgis.com/home/item.html?id=272831f917ef48689ae7896139f07751

A short summary of the situation.
We have confirmed with DEQ DERR and IT staff that the Enviro "Interactive Map" does not utilize data from this table but, rather, from views directly from a DEQ database; therefore, there is lacking justification to host the table in the SGID any longer. DEQ staff agree.
Migration Guide
A short summary of how users affected by this deprecation can modify their workflows and projects to continue to get similar or improved functionality
Data in this table are available directly from enviro.utah.gov by filtering for the parent data set and exploring the resulting table(s) of related data.
Action items

Assign a person who should complete the task by replacing name with their github @name.
Check [x] the box when the task is completed and add the date of completion.
~Strike~ out all items that do not apply.

Soft Delete
The purpose of the soft delete is to ensure that all of our users and applications have gracefully migrated off of the dataset. Soft deletes will remain in effect for 14 days. During this time, we will have the ability to restore the dataset to its original SGID offering(s). After these 14 days, the item is then ready for a hard delete.
Note: If this dataset is being replaced, then wait until the new data is publicly available before completing these steps:

[x] Prepend "(Mature Support)" to the end of the item title (@nathankota , completed: 2022/03/28)
[x] Remove all tags other than "Deprecated" (@nathankota , completed: 2022/03/28)
[x] Add note to ArcGIS Online description and default popup noting when layer will be deleted and any replacement layer (@nathankota , completed: 2022/03/28)
[x] Unshare item from Open Data (@nathankota , completed: 2022/03/28)
~[ ] Update the SGID Index row as deprecated by pasting the related Porter issue URL in the Deprecated field (name, completed: 2022/00/00)~ NO STEWARDSHIP TABLE RECORD
[x] Mark ArcGIS Online item as deprecated in preparation for future deletion (@nathankota , completed: 2022/03/28)

[x] Change Authoritative field to d in SGID.META.AGOLItems to automatically set the Deprecated AGOL flag. Allow the d to persist through one run of Auditor - currently, Auditor runs daily at 5:00am (@nathankota , completed: 2022/03/28)

[x] After one successful run of Auditor, remove the row from the SGID.META.AGOLItems table.  It is recommended to complete the soft delete process before moving on to these steps. If you decide to skip the soft delete, note that you will need to incorporate some of those steps here.

[x] Manually remove data from the Internal SGID (@ZachBeck, completed: 2022/04/04)

~Deprecated database layers can be backup up on Google Drive > AGRC Share > Team Projects > SGID > [deprecated layers]~

[ ] Remove ArcGIS Online item: (@nathankota , completed: 2022/00/00)

Manually delete the AGOL item
~-OR-~
~Unshare by changing the AGOL_ITEM_ID field in SGID.META.AGOLItems to something other than an Item ID and manaually changing the sharing settings (remove the item from all SGID groups, remove Public sharing),~
~-OR-~
~Shelve the data by copying the row from SGID.META.AGOLItems to the AGOLItems_shelved table in AGOL and changing the AGOL_ITEM_ID field in SGID.META.AGOLItems to shelved or some other note.~
~Deprecated AGOL items can be backup on Google Drive > AGRC Share > Team Projects > SGID > deprecated layers.~

~[ ] Remove Farm from AGOL connection (name, completed: 2022/00/00)~

~[ ] Update relevant gis.utah.gov data pages (name, completed: 2022/00/00)~

~[ ] Add this porter url to the Deprecated field of the Stewardship record (name, completed: 2022/00/00)~ NO STEWARDSHIP TABLE RECORD

~[ ] Update SGID.META.AGOLItems table (name, completed: 2022/00/00)~

~cut and paste row to AGOLItems_shelved table if shelving (see below)~
~set the AGOL_ITEM_ID field to hosted by <agency> for Farm from AGOL~
~set the AGOL_ITEM_ID field to exclude from AGOL to not publish to ArcGIS Online~

~[ ] Delete Google Drive data (name, completed: 2022/00/00)~

[x] Remove row from SGID.META.ChangeDetection (@stdavis , completed: 2022/04/01)

[x] Remove data from forklift hashing and receiving (@stdavis , completed: 2022/04/01)

[x] Remove row from data/hashed/changedetection.gdb/TableHashes (@stdavis , completed: 2022/04/01)

~Shelve/Static~
~Choose one based on situation.~

~[ ] Upload to UtahAGRC/AGRC_Shelved folder in AGOL (New shelved item not already in AGOL) (name, completed: 2022/00/00)~
~[ ] Move existing AGOL item to AGRC_Shelved AGOL folder (shelving an item already in AGOL) (name, completed: 2022/00/00)~
~[ ] Upload to appropriate UtahAGRC/{SGID Category} folder in AGOL (for static datasets) (name, completed: 2022/00/00)~

~Add record to table.~

~[ ] Add record to AGOLItems_shelved table in ArcGIS Online  with shelved or static in the CATEGORY field (name, completed: 2022/00/00)~

:robot: Automation validation

Assign yourself or someone to check the item by replacing name with their github @name.
Check [x] the box and add the date of verification 2020/01/01 when the task is verified.
~Strike~ out all items that do not apply.

[ ] Remove data from Open SGID (@steveoh on 2022/00/00)
[ ] sgid-index (@steveoh on 2022/00/00)
[x] Auditor sets appropriate shelved/static/Deprecated information (@jacobdadams on 2022/03/29)

Are there service dependencies

Does an application depend on this data? No
[x] Are clients querying this data with the WebAPI? (@steveoh on 2022/03/28)

Notification

[x] Twitter (@steveoh)

Group Task Assignments

Check [x] the box when you have assigned all the tasks relevant to your group.

[x] Data Team (@nathankota)
[x] Dev Team (@nathankota )
~[ ] Cadastre Team (@rkelson)~

conductor results for tasks - 190

check
status

@nathankota has completed 8 out of 9 tasks
:no_entry:

@ZachBeck has completed 0 out of 1 tasks
:no_entry:

stdavis has completed 3 out of 3 tasks
:+1:

@steveoh has completed 2 out of 4 tasks
:no_entry:

jacobdadams has completed 1 out of 1 tasks
:+1:

conductor results for ENVIRONMENT.DEQMAP_TRICHEM

check
status

internal sgid
:no_entry:

meta table
:+1:

stewardship
:no_entry: Did not find ENVIRONMENT.DEQMAP_TRICHEM in the worksheet

conductor results for tasks - 190

check
status

@nathankota has completed 8 out of 9 tasks
:no_entry:

ZachBeck has completed 1 out of 1 tasks
:+1:

stdavis has completed 3 out of 3 tasks
:+1:

@steveoh has completed 2 out of 4 tasks
:no_entry:

jacobdadams has completed 1 out of 1 tasks
:+1:

conductor results for ENVIRONMENT.DEQMAP_TRICHEM

check
status

internal sgid
:+1:

meta table
:+1:

stewardship
:no_entry: Did not find ENVIRONMENT.DEQMAP_TRICHEM in the worksheet

AGOL item and service def removed/deleted.


Picture preview - zoom in/out

Hi,
I'd like to have the option to zoom in and out in the picture preview using the mouse wheel or at least zoom buttons in the preview.
And once you have zooming, well... panning when holding space would also be useful. Pressing spacebar doesn't interfere with anything when you have a file selected.

As in preview pane?

Yes. I noticed that this is already available in the pdf preview.

That is a 3rd party PDF viewer that has it built in for that app.  Right now this would be us overriding all existing image viewers to accomplish it.

I would argue at this point we'd say PowerToys Peek would be your go to here and that is supported else this would be a /feedbackhub item as we don't control that render surface


Frontend-driven database access aka. "The Ultimate Endpoint"

Hi guys! I just wanted to share some ideas for the production usage of AskQL. I mean business case - which actually can be an idea for another product using AskQL :)
Use case
Imagine a legacy system having its own MySQL, Oracle, MongoDB database. You're a frontend developer building some new features and you need a single, additional piece of information from this DB. Wait - you need to match it and join with some other data from the REST endpoint.
OK, now you're writing down your specs into JIRA and waiting. Waiting, and ... waiting. In some extreme cases, the backend folks from another department that is handling the database maintenance are needing weeks if not months to deploy this change to prod. And you're blocked.
They can potentially think of GraphQL but it's still is not that elastic. If you need some heavy processing (like merging the data with REST API resources) you gonna still develop a middleware fetching the data first from GQL, then REST, and then mixing it all together. With AskQL you don't need to.
Now, imaging having a single JS endpoint with AskQL server and the resources - generated (think: prisma.io) or coded by these backend folks exposing you a set of data tables and collections.
Now, the whole app development is driven by frontend guys. They can send out the whole micro-askql application against this endpoint.
Moreover, it simplifies the data access - because the access language is always the same: AskQL and not MongoDB/JS or SQL.

it's a gamechanger for no-code/low-code envs too. Imagine airtable. You can fetch some data from REST/GraphQL but if you need a custom query you gonna ask backend dev anyway to prepare an endpoint. And you're blocked. With such a tool you gonna just ask the guys to install askQL server from an NPM + configure which resources it has access to. The app should have bindings (using Prisma or mongoose or whatever) to some popular databases like mongodb / MySQL + predefined AskQL functions like db-cursor and query features. To ensue data safety there could be an ACL based security system (we could potentially even anlyse the AskQL AST of the resources being used (and how) against the ACL rules assigned to specific user identity)

Thanks @pkarw, I really like this idea!

@pkarw , thank you for refreshing the topic of business ideas for AskQL. The vision is consistent with the vision we had.
First question that comes to my mind is how to get there.

Let's do it.

Related: #410, #514

Related: #45

Related: #364 - schema discoverability


ENH: Better validation of MPI_Datatypes

I’m trying to think of a more robust validation approach when creating the MPI_Datatypes in vic_mpi_support.c.  Right now, we check that the number of members in the MPI struct matches the number of members we counted in the actual structure definition (most likely in vic_def.h). So we are currently checking that we have the right number of members.  This is prone to errors because I can easily add a member to a structure in vic_def.h and not add it in vic_mpi_support.c.  Would it be better/possible to check that the size of the MPI_Datatype matches the size of the original structure?  In other words sizeof(options_struct) == sum(sizeof(mpi_members))?

I tried to implement this (see below for an example, by tracking the size of the member elements. Unfortunately, sizeof(struct) does not necessarily equal the sum of its members, because the structures add padding to align on n-byte boundaries (for example, 4 byte boundaries). The sizeof() includes this padding. Implementing this would likely be hardware dependent, so I have taken it back out, but I’ll keep working on this.
The first function works because the structure aligns on 4-byte boundaries. The second does not work, and the logic I added does not fix it (I understand why). To be continued ...
/******************************************************************************
 * @brief   Create an MPI_Datatype that represents the filenames_struct
 * @details This allows MPI operations in which the entire filenames_struct
 *          can be treated as an MPI_Datatype. NOTE: This function needs to be
 *          kept in-sync with the global_param_struct data type in vic_def.h.
 *
 * @param mpi_type MPI_Datatype that can be used in MPI operations
 *****************************************************************************/
void
create_MPI_filenames_struct_type(MPI_Datatype *mpi_type)
{
    int           nitems; // number of elements in struct
    int           status;
    int          *blocklengths;
    int           mpi_size; // size in bytes of MPI data type
    size_t        i;
    size_t        ssize; // sum of all elements - should equal sizeof(struct)
    MPI_Aint     *offsets;
    MPI_Datatype *mpi_types;

    // nitems has to equal the number of elements in filenames_struct
    nitems = 14;
    blocklengths = malloc(nitems * sizeof(*blocklengths));
    if (blocklengths == NULL) {
        log_err("Memory allocation error in create_MPI_filenames_struct_type().")
    }

    offsets = malloc(nitems * sizeof(*offsets));
    if (offsets == NULL) {
        log_err("Memory allocation error in create_MPI_filenames_struct_type().")
    }

    mpi_types = malloc(nitems * sizeof(*mpi_types));
    if (mpi_types == NULL) {
        log_err("Memory allocation error in create_MPI_filenames_struct_type().")
    }

    // most of the elements in filenames_struct are character arrays. Use
    // MAXSTRING as the default block length and reset as needed
    for (i = 0; i < (size_t) nitems; i++) {
        blocklengths[i] = MAXSTRING;
    }

    // reset i
    i = 0;

    // initialize ssize
    ssize = 0;

    // char forcing[2][MAXSTRING];
    offsets[i] = offsetof(filenames_struct, forcing);
    blocklengths[i] *= 2;
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char f_path_pfx[2][MAXSTRING];
    offsets[i] = offsetof(filenames_struct, f_path_pfx);
    blocklengths[i] *= 2;
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char global[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, global);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char domain[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, domain);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char constants[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, constants);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char init_state[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, init_state);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char lakeparam[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, lakeparam);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char result_dir[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, result_dir);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char snowband[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, snowband);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char soil[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, soil);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char statefile[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, statefile);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char veg[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, veg);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char veglib[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, veglib);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // char log_path[MAXSTRING];
    offsets[i] = offsetof(filenames_struct, log_path);
    mpi_types[i] = MPI_CHAR;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // make sure that the we have the right number of elements
    if (i != (size_t) nitems) {
        log_err("Miscount in create_MPI_filenames_struct_type(): "
                "%zd not equal to %d\n", i, nitems);
    }

    // make sure that we have the right size
    if (ssize != sizeof(filenames_struct)) {
      log_err("Incorrect size in create_MPI_filenames_struct_type(): "
              "%zd not equal to %zd\n", ssize, sizeof(filenames_struct));
    }

    status = MPI_Type_create_struct(nitems, blocklengths, offsets, mpi_types,
                                    mpi_type);
    if (status != MPI_SUCCESS) {
        log_err("MPI error in create_MPI_filenames_struct_type(): %d\n",
                status);
    }

    status = MPI_Type_commit(mpi_type);
    if (status != MPI_SUCCESS) {
        log_err("MPI error in create_MPI_filenames_struct_type(): %d\n",
                status);
    }

    // cleanup
    free(blocklengths);
    free(offsets);
    free(mpi_types);
}

/******************************************************************************
 * @brief   Create an MPI_Datatype that represents the location_struct
 * @details This allows MPI operations in which the entire location_struct
 *          can be treated as an MPI_Datatype. NOTE: This function needs to be
 *          kept in-sync with the location_struct data type in
 *          vic_image_driver.h.
 *
 * @param mpi_type MPI_Datatype that can be used in MPI operations
 *****************************************************************************/
void
create_MPI_location_struct_type(MPI_Datatype *mpi_type)
{
    int           nitems; // number of elements in struct
    int           status;
    int          *blocklengths;
    int           mpi_size; // size in bytes of MPI data type
    size_t        i;
    size_t        ssize; // sum of all elements - should equal sizeof(struct)
    MPI_Aint     *offsets;
    MPI_Datatype *mpi_types;

    // nitems has to equal the number of elements in global_param_struct
    nitems = 9;
    blocklengths = malloc(nitems * sizeof(*blocklengths));
    if (blocklengths == NULL) {
        log_err("Memory allocation error in create_MPI_location_struct_type().")
    }

    offsets = malloc(nitems * sizeof(*offsets));
    if (offsets == NULL) {
        log_err("Memory allocation error in create_MPI_location_struct_type().")
    }

    mpi_types = malloc(nitems * sizeof(*mpi_types));
    if (mpi_types == NULL) {
        log_err("Memory allocation error in create_MPI_location_struct_type().")
    }

    // none of the elements in location_struct are arrays.
    for (i = 0; i < (size_t) nitems; i++) {
        blocklengths[i] = 1;
    }

    // reset i
    i = 0;

    // initialize ssize
    ssize = 0;

    // size_t run;
    offsets[i] = offsetof(location_struct, run);
    mpi_types[i] = MPI_C_BOOL;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    if (ssize % ALIGN_BYTES) {
      ssize = (ssize / ALIGN_BYTES + 1) * ALIGN_BYTES;
    }
    i += 1;

    // double latitude;
    offsets[i] = offsetof(location_struct, latitude);
    mpi_types[i] = MPI_DOUBLE;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // double longitude;
    offsets[i] = offsetof(location_struct, longitude);
    mpi_types[i] = MPI_DOUBLE;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // double area;
    offsets[i] = offsetof(location_struct, area);
    mpi_types[i] = MPI_DOUBLE;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // double frac;
    offsets[i] = offsetof(location_struct, frac);
    mpi_types[i] = MPI_DOUBLE;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // size_t nveg;
    offsets[i] = offsetof(location_struct, nveg);
    mpi_types[i] = MPI_AINT;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // size_t global_idx;
    offsets[i] = offsetof(location_struct, global_idx);
    mpi_types[i] = MPI_AINT;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // size_t io_idx;
    offsets[i] = offsetof(location_struct, io_idx);
    mpi_types[i] = MPI_AINT;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // size_t local_idx;
    offsets[i] = offsetof(location_struct, local_idx);
    mpi_types[i] = MPI_AINT;
    MPI_Type_size(mpi_types[i], &mpi_size);
    ssize += mpi_size * blocklengths[i];
    i += 1;

    // make sure that the we have the right number of elements
    if (i != (size_t) nitems) {
        log_err("Miscount in create_MPI_location_struct_type(): "
                "%zd not equal to %d\n", i, nitems);
    }

    // make sure that we have the right size
    if (ssize != sizeof(location_struct)) {
      log_err("Incorrect size in create_MPI_location_struct_type(): "
              "%zd not equal to %zd\n", ssize, sizeof(location_struct));
    }

    status = MPI_Type_create_struct(nitems, blocklengths, offsets, mpi_types,
                                    mpi_type);
    if (status != MPI_SUCCESS) {
        log_err("MPI error in create_MPI_location_struct_type(): %d\n", status);
    }

    status = MPI_Type_commit(mpi_type);
    if (status != MPI_SUCCESS) {
        log_err("MPI error in create_MPI_location_struct_type(): %d\n", status);
    }

    // cleanup
    free(blocklengths);
    free(offsets);
    free(mpi_types);
}

@jhamman : Also note that vic_mpi_support.c has a built in test routine that we should automatically run as part of travis tests. If we keep this updated then it should automatically capture problems like the one we have seen here (or at least I think so, I still need to check that).

The test in vic_mpi_support() needs work since it does not capture the error that we saw in issue #445 and which was solved with PR #450


add virginia's community colleges.

Add virginia's community colleges.

@cpedia This domain is blacklisted because the college allows to register an email address there even if you are not a student of the college. If you are the student of this college, please apply with official document ("OFFICIAL DOCUMENT" tab at https://www.jetbrains.com/shop/eform/students).


Auto pin selection

Context
rstash is a fantastic script idea, and really allows teams to quickly change drivers on pairing assignments. However, in our experience, we find that a situation as follows happens constantly:
The Situation
Alice

Time runs out
Executes rstash without any arguments
rstash creates a new branch with a unique name and shows pin in the console
Says the number in the zoom call and stops sharing

Bob:

Starts sharing his screen in Zoom
Switches to his IntelliJ / Terminal
Asks once again for the number, because of the context switching
Then Alice has to look at it again, and send once more

Which just gets compounded when in Hive / Mob programming situations where there may be a gap between Alice stopping sharing the screen in zoom and the team restarting work in another driver's machine.
The proposal
I propose a new argument to rstash, making it rstash pop.  This command will have one of three outcomes:

When there are no rstash branches in the remote, then a simple message will say that no branches were found.
When there is only a single rstash branch in the remote (which is the most common occurrence, in our experience), it is selected automatically and popped.
When multiple rstash branches are found in the remote, then a fuzzy selection is given to the user. The most recent branch is pre-selected, but the user could navigate to the desired pin number either by typing or by using the arrow keys

This functionality depends on a command line tool named fzf (https://github.com/junegunn/fzf). It is super lightweight, and can be found basically in all package managers. However, in the name of clarity the code also does validate if the current user has it installed in their machines.

Preview (in action)
https://user-images.githubusercontent.com/78365040/110121820-29e48600-7dbf-11eb-9b50-ea622403b490.mov
Outro
I'd be happy to discuss the current changes as necessary, and hopefully this can be useful to more people outside our current team :)

That's really great. I'm glad you guys continue to use the tool and help make it better.
It would be great if the selection would show the same information as the list command, so you can save another step.
But for now, I'll merge your changes and make this adjustment afterwards.
Thanks a lot


Add support for Unix sockets

We report a lot of our stats over Unix sockets, so I'm adding a new sink that will accept UnixStreams instead of UdpSockets. Arguably, it should just accept anything that implements the Write trait, which I'm happy to do as that is a pretty small refactoring.
Creating the draft PR early mostly for my own edification.

Thanks for the PR! I think it's fine to create a sink solely for Unix sockets.

Thanks for the quick response! This should be ready to review now.

Awesome, merged!

Hmm, it seems like this might be the wrong UDS primitive (stream vs datagram).
According to these:

https://github.com/DataDog/datadog-agent/wiki/Unix-Domain-Sockets-support
https://docs.datadoghq.com/developers/dogstatsd/unix_socket/#using-socat-as-a-proxy

...the datagram protocol is used, not the stream protocol. This would mean using UnixDatagram in Rust instead of UnixStream.

Yeah, you're correct. I just got ahead of myself. I'll send you the PR tomorrow.


[BEAM-2516] Add fast path to ParDoTranslation for known ParDo class

Follow this checklist to help us incorporate your contribution quickly and easily:

[ ] Make sure there is a JIRA issue filed for the change (usually before you start working on it).  Trivial changes like typos do not require a JIRA issue.  Your pull request should address just this issue, without pulling in other changes.
[ ] Each commit in the pull request should have a meaningful subject line and body.
[ ] Format the pull request title like [BEAM-XXX] Fixes bug in ApproximateQuantiles, where you replace BEAM-XXX with the appropriate JIRA issue.
[ ] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
[ ] Run mvn clean verify to make sure basic checks pass. A more thorough check will be performed on your pull request automatically.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

These hacked fast paths bring the time back down to the same as before the portability stuff was put in place. The fast paths will not apply when the pipeline has gone through a proto round-trip so when I re-enable that (currently behind experiment flag) I will tackle a cached rehydration (aka RawParDo) with its own fast path.
R: @tgroh
CC: @iemejia

Fast path seems brittle compared to understanding the lifetime of an object and caching it appropriately from the callers perspective.

This is to unblock 2.2.0. After that, I will be working up a shared fast path for both original and rehydrated RawPTransforms.

Actually, a point worth mentioning is that the object lifetimes are open-ended. Anyone is free to call these methods on a ParDo.MultiOutput at any time, and anyone is free to round-trip a pipeline as many times as they want. This code needs to be agnostic.

Coverage decreased (-0.01%) to 69.5% when pulling 9b30bcaa707738da46bd238d3823717e266a8056 on kennknowles:ParDoTranslation-shortcut into 8e391d94f7a4ddc0dbbc7ec54d42df5b6cb7903c on apache:master.


chore(main): release 0.8.7

:robot: I have created a release beep boop
0.8.7 (2023-12-08)
Bug Fixes

Change release-please output (3c9b4be)

This PR was generated with Release Please. See documentation.

:robot: Release is at https://github.com/kevinah95/hacienda/releases/tag/v0.8.7 :sunflower:


count = count - (0.1*count)

In syllable_count there is a "count = count - (0.1*count)" which will always make the syllable_count 10% smaller. So "Beautiful" returned 2.7. Is there a reason for this?
This function is called in polysyllabcount(), this will then only count syllables with more than 4 syllables in, which is not the definition of polysyllablecount
(I'm using python 3, I can't think of an immediate reason why this would just effect just python 3)

+1
I have the same question, and am using python 2.7.11

Short story:
I recomend removing the 0.1, I have not seen any reason why it should be done.
Long story:
I started quantifying syllable count in a slightly different way after some research.
There are 2 methods to counting syllables from what I have seen: using dictionaries (where it is more reliable) or using some heuristic based method (which is what textstat uses).
The dictionary method is accurate, but many words are not in the dictionary (at least for what I wanted). The heuristic method will always get some words wrong as there are problems with diphthongs (e.g. most methods will get either "usually" or "beautiful" wrong as 2+ vowels either count as a diphthong (one syllable) or not). So to cut down on this, I use a 2 step measure, where a first query a dictionary in NLTK and, if it is not in there, then use a heurstic measure like textstat.
First you need to download a dictionary through nltk. Then import.
import re
from nltk.corpus import cmudict
d = cmudict.dict()

The structure of the functions are like this:
def count_syllables(wrd):
    #Make sure word contains a vowel before sending to dictionary
    restr=re.compile('[AEIOUYaeiouy]')
    if restr.search(wrd):
        try:
            cnt=count_syllables_primary(wrd)
        except:
            cnt=count_syllables_secondary(wrd)
        #If multiple syllable alternatives exist, return the largest.
        if type(cnt) is list:
            sylCount=max(cnt)
        else:
            sylCount=cnt
    else:
        sylCount = 0
return sylCount

So there are two functions primary and secondary. The primary one queries the dictionary. The second one queries the heuristic function. For the secondary one you  can use textstat one (but I'd remove the 0.1. I actually used a different one that I adapted from http://shallowsky.com this website.)
def count_syllables_primary(word):
  return [len(list(y for y in x if isdigit(y[-1]))) for x in d[word.lower()]]

def count_syllables_secondary(word):
    vowels = ['a', 'e', 'i', 'o', 'u']
    on_vowel = False
    syl = 0
    lastchar = None
    word = word.lower()
    try:
        for c in word:
            is_vowel = c in vowels
            if on_vowel == None:
                on_vowel = is_vowel
            # y is a special case
            if c == 'y':
                is_vowel = not on_vowel
            if is_vowel:
                if not on_vowel:
                    syl += 1
            on_vowel = is_vowel
            lastchar = c
        if word[-1] == 'y' and not on_vowel:
            syl += 1
    except:
        syl=0
return syl

From my experimenting around several months ago, this gave me the best results.

This looks great.  It might be nice to note in the documentation, or a code comment, that there is a dependency on the NLTK.  It's handled really well with the try/except block, but still.
I don't understand the check for is_digit in the primary method - could you explain that?

Just to be clear I have nothing to do with this textstat package. I just thought that I'd provide the  solution I came up with since you were having the same problem. And I am sorry if I wasn't clear in what I wrote above that it needs NLTK.
So after you have run the d = cmudict.dict(),iIf the word you look up is 'installer', you get the following back in the the cmudict.dict()
In [1]: d['installer']
Out[1]: [['IH0', 'N', 'S', 'T', 'AO1', 'L', 'ER0']]
I don't fully understand everything in the NLTK coding, but what I know is that all the new syllables have digits in them (and this is the case for all words). So you take the length of the words elements in the lsit with a digit in to get the syllable count. Sometimes words are coded in multiple ways:
In [2]: d['restaurant']
Out[2]:
[['R', 'EH1', 'S', 'T', 'ER0', 'AA2', 'N', 'T'],
 ['R', 'EH1', 'S', 'T', 'R', 'AA2', 'N', 'T']]

That is the reason for the double loop. And in the functions above, I take the max whenever this occurs.

Right, I realize that you are not the repo owner.  I figure this conversation is for everyone's benefit, including that of the repo owner.  My apologies for not being clearer.
You, on the other hand, were very clear about the dependency of the Python NLTK in your comments.  I just meant that if the syllable count algorithm changes to your idea of primary/secondary methods, then I think the official docs for the package would need to include a note indicating such.  From what I can tell, you have the try/except block taking care of the instance where the code is used without the NLTK, which is great, but as I said, it's probably a wise idea to put that dependency in the docs.
And thank you for the explanations.

Sorry for the misunderstanding (too hot where I am).
So for completeness for anyone who wants it. Here is a slightly modified version of the functions that also excludes the try/except so people will see if they need NLTK.
def count_syllables(wrd,d=cmudict.dict()):
    '''
    Count syllables works in two steps. First it searches a dictionary wherer the answer is usually better. If missing from the dictionary a heuristic is applied where the vowels are counted.
    Wrd: string of word
    d = dictionary of words coming from NLTK
    Requires: nltk and a dictionar. To get cmudict, install NLTK and run "from nltk.corpus import cmudict"
    '''
    #Make sure word contains a vowel before sending to dictionary
    restr=re.compile('[AEIOUYaeiouy]')
    if restr.search(wrd):
        cnt=count_syllables_primary(wrd,d)
        #If 0 from above function, go to secondary function
        if cnt==0:
            cnt=count_syllables_secondary(wrd)
        #If multiple syllable alternatives exist, return the largest.
        if type(cnt) is list:
            sylCount=max(cnt)
        else:
            sylCount=cnt
    else:
        sylCount = 0
    return sylCount

def count_syllables_primary(word,d):
    inList=any(word in x for x in d)
    if inList != 0:
        return [len(list(y for y in x if isdigit(y[-1]))) for x in d[word.lower()]]
    else:
        return 0

def count_syllables_secondary(word):
    # Adapted from Akkana Peck http://shallowsky.com.
    vowels = ['a', 'e', 'i', 'o', 'u']
    on_vowel = False
    syl = 0
    lastchar = None
    word = word.lower()
    try:
        for c in word:
            is_vowel = c in vowels
            if on_vowel == None:
                on_vowel = is_vowel
            # y is a special case
            if c == 'y':
                is_vowel = not on_vowel
            if is_vowel:
                if not on_vowel:
                    # We weren't on a vowel before.
                    # Seeing a new vowel bumps the syllable count.
                    syl += 1
            on_vowel = is_vowel
            lastchar = c
        if word[-1] == 'y' and not on_vowel:
            syl += 1
    except:
        syl=0
    return [syl]

This is updated in the latest code. Thanks


deepOverride for haskell-ng stalls for a minute then kills the evaluator

With this patch against master:
diff --git a/pkgs/development/haskell-modules/configuration-common.nix b/pkgs/de
velopment/haskell-modules/configuration-common.nix
index b60dcef..f378f71 100644
--- a/pkgs/development/haskell-modules/configuration-common.nix
+++ b/pkgs/development/haskell-modules/configuration-common.nix
@@ -39,6 +39,14 @@ self: super: {
   active = overrideCabal super.active (drv: { jailbreak = true; });
   aeson-utils = overrideCabal super.aeson-utils (drv: { jailbreak = true; });
   Agda = overrideCabal super.Agda (drv: { jailbreak = true; noHaddock = true; }
);
+  amazonka-core = super.amazonka-core.deepOverride rec {
+    transformers = self.transformers_0_4_2_0;
+    mtl = self.mtl_2_2_1.override {
+      inherit transformers;
+    };
+    time = self.time_1_5_0_1;
+    nats = self.nats_0_2;
+  };
   amqp = overrideCabal super.amqp (drv: { doCheck = false; });
   arbtt = overrideCabal super.arbtt (drv: { jailbreak = true; });
   ariadne = overrideCabal super.ariadne (drv: { doCheck = false; });
diff --git a/pkgs/development/haskell-modules/hackage-packages.nix b/pkgs/develo
pment/haskell-modules/hackage-packages.nix
index a0793d3..6317e86 100644
--- a/pkgs/development/haskell-modules/hackage-packages.nix
+++ b/pkgs/development/haskell-modules/hackage-packages.nix
@@ -79370,6 +79370,20 @@ self: {
        license = stdenv.lib.licenses.bsd3;
      }) {};

+  "nats_0_2" = callPackage
+    ({ mkDerivation, base, hashable }:
+     mkDerivation {
+       pname = "nats";
+       version = "0.2";
+       sha256 = "05skqs5ahbrnwlsxjihkvmsw0n49k9mqdhrv9nqh4dmd1j622r73";
+       editedCabalFile = "e401a5253358858109c85e8f17a4b63e7dd86b59cc77ac4baa6a421b6645b439";
+       buildDepends = [ base hashable ];
+       configureFlags = [ "-fhashable" ];
+       homepage = "http://github.com/ekmett/nats/";
+       description = "Natural numbers";
+       license = stdenv.lib.licenses.bsd3;
+     }) {};
+
   "nats" = callPackage
     ({ mkDerivation, base, hashable }:
      mkDerivation {

I get:

$ time nix-instantiate -A haskellngPackages.amazonka-core
Killed
real	0m53.051s
user	0m34.883s
sys	0m5.236s

@peti

Yeah, deepOverride turns out to be crap for anything but non-trivial cases. :-(
See 3c8b33e and 388848f for an alternative solution that works better (for haskell-ng).

Thanks!


GridAlign() origin seems incorrect

Version

Phaser Version: 3.52.0 (and earlier)

Description
Call Phaser.Actions.GridAlign() with x and y options.

Optionally place the top-left of the final grid at this coordinate.

I expected this puts the top-left of the first grid cell at (x, y). Instead it puts the center of the first grid cell at (x,  y).
Example Test Code
https://codepen.io/samme/pen/bGBbExE
This is a GridAlign() call with { x: 0, y: 0 }. The top-left of the first cell is (-32, -32), and its center is (0, 0).

Yep. This is due to the fact that "tempZone" in https://github.com/photonstorm/phaser/blob/master/src/actions/GridAlign.js has default origin as 0.5 and is unchangeable through the params. It seems like this could be easily fixed by adding a field to the params to take in a desired origin for the tempZone.
I don't have time to fork the repo, rebuild and reroute my dependencies but I was able to fix the issue by copy pasting the contents of GridAlign.js into a new file with "setOrigin(0)" on the tempZone as a quick and dirty solution. Maybe someone else can make a clean solution for this but here is what worked for me:
`import { Scene } from "phaser";
var NOOP = function ()
{
//  NOOP
};
var GetFastValue = function (source, key, defaultValue)
{
var t = typeof(source);
 if (!source || t === 'number' || t === 'string')
 {
     return defaultValue;
 }
 else if (source.hasOwnProperty(key) && source[key] !== undefined)
 {
     return source[key];
 }
 else
 {
     return defaultValue;
 }

};
var SetLeft = function (gameObject, value)
{
gameObject.x = value + (gameObject.width * gameObject.originX);
 return gameObject;

};
var SetTop = function (gameObject, value)
{
gameObject.y = value + (gameObject.height * gameObject.originY);
return gameObject;

};
var GetLeft = function (gameObject)
{
return gameObject.x - (gameObject.width * gameObject.originX);
};
var GetTop = function (gameObject)
{
return gameObject.y - (gameObject.height * gameObject.originY);
};
var TopLeft = function (gameObject, alignIn, offsetX, offsetY)
{
if (offsetX === undefined) { offsetX = 0; }
if (offsetY === undefined) { offsetY = 0; }
SetLeft(gameObject, GetLeft(alignIn) - offsetX);
SetTop(gameObject, GetTop(alignIn) - offsetY);

return gameObject;

};
var tempZone = new Phaser.GameObjects.Zone({ sys: { queueDepthSort: NOOP, events: { once: NOOP } } } as unknown as Scene, 0, 0, 1, 1).setOrigin(0);
/**

Takes an array of Game Objects, or any objects that have public x and y properties,

and then aligns them based on the grid configuration given to this action.

@function Phaser.Actions.GridAlign

@since 3.0.0

@generic {Phaser.GameObjects.GameObject[]} G - [items,$return]

@param {(array|Phaser.GameObjects.GameObject[])} items - The array of items to be updated by this action.

@param {Phaser.Types.Actions.GridAlignConfig} options - The GridAlign Configuration object.

@return {(array|Phaser.GameObjects.GameObject[])} The array of objects that were passed to this Action.
*/
export const FixedGridAlign = function (items, options)
{
if (options === undefined) { options = {}; }
var widthSet = options.hasOwnProperty('width');
var heightSet = options.hasOwnProperty('height');
var width = GetFastValue(options, 'width', -1);
var height = GetFastValue(options, 'height', -1);
var cellWidth = GetFastValue(options, 'cellWidth', 1);
var cellHeight = GetFastValue(options, 'cellHeight', cellWidth);
var x = GetFastValue(options, 'x', 0);
var y = GetFastValue(options, 'y', 0);
var cx = 0;
var cy = 0;
var w = (width * cellWidth);
var h = (height * cellHeight);
tempZone.setPosition(x, y);
tempZone.setSize(cellWidth, cellHeight);
for (var i = 0; i < items.length; i++)
{
TopLeft(items[i], tempZone, 0, 0);
 if (widthSet && width === -1)
 {
     //  We keep laying them out horizontally until we've done them all
     tempZone.x += cellWidth;
 }
 else if (heightSet && height === -1)
 {
     //  We keep laying them out vertically until we've done them all
     tempZone.y += cellHeight;
 }
 else if (heightSet && !widthSet)
 {
     //  We keep laying them out until we hit the column limit
     cy += cellHeight;
     tempZone.y += cellHeight;

     if (cy === h)
     {
         cy = 0;
         cx += cellWidth;
         tempZone.y = y;
         tempZone.x += cellWidth;

         if (cx === w)
         {
             //  We've hit the column limit, so return, even if there are items left
             break;
         }
     }
 }
 else
 {
     //  We keep laying them out until we hit the column limit
     cx += cellWidth;
     tempZone.x += cellWidth;

     if (cx === w)
     {
         cx = 0;
         cy += cellHeight;
         tempZone.x = x;
         tempZone.y += cellHeight;

         if (cy === h)
         {
             //  We've hit the column limit, so return, even if there are items left
             break;
         }
     }
 }

}
return items;
};`

Phaser is massively infested with these types of origin issues which cause insidious misalignments which can take hours to fix. I'm not sure why it is assumed that everyone loves using origin = 0.5 enough that it is the unchangable default on all of the internal code. I never, ever want to use origin = 0.5 on any of my game objects because it always requires more code to align everything correctly. Origin = 0 allows things to be aligned through simple addition, but origin = 0.5 requires many extra width calculations and mental gymnastics to conceptualize the positioning. Frankly I'm using Phaser over raw Pixi.js because I thought  common requirements like positioning would be easy to implement, but I find myself having to patch a lot of the internal code due to origin issues.

The tempZone origin has been changed to 0,0 in the master branch for Beta 13.


Apply dark grey to the nav-dividers (footsteps)

https://github.com/sievins/sarahs-footsteps/commit/851430e7bc97b972d9bf0a63f00cb585b09d2dc6


handle play/pause in background

[x] get rid of the current logic that automatically pauses the video in a background
[x] add a logic to the example app that pause/play  the video using AppState module
[x] Add the controls that toggles auto play/pause
[x] add relevant e2e test
[x] add relevant documentation

how to pause the player on exiting ??


fix: append ti-config user to request body in local dev

Closes CLM-8345
SSO users cannot use the Login mutation as no password is set, and the /access/ endpoints in the Thought Industries platform sets auth cookies for their respective domain, so they're not included in localhost requests.

@chrisvariety Sorry, that was poor phrasing on my part. What I was trying to say was: Non-SSO users can call the Login mutation and have their authToken cookie set with the local as the domain. SSO users developing locally don't have that option, and cannot use the /access/ endpoints of their Thought Industries instance because that instance will set the cookie for their Thought Industries domain - so the local ApolloClient doesn't include that cookie in its requests.

@rjschill87 ah, so that's typically what the email in ti-instances.json is for (avoids login entirely), but this is specifically for testing Login mutation locally. I'm not sure if we can make that a bit more clear in the code, e.g. only doing this when someone calls the Login mutation ?

@chrisvariety Poor phrasing on my part again, sorry. No it's not for testing Login mutation, as you mentioned -- SSO doesn't work with Login. They weren't actually using that, I was only saying they don't have the option of using it to set a currentUser when developing locally.
But yeah you're right, it's the reason for the email in ti-instances.json. The logic for it was removed from helium-server during the completion of the Sign In page: https://github.com/thoughtindustries/helium/pull/172/files#diff-44f0664d9b0b88b856ea5ff74f32f919cf06ea5b2dea14a3ecf18160e9297f59L35-L38
As that went with the release of the Login mutation, and made the email in ti-instances.json redundant as the currentUser could then be set via the Login mutation. Except for SSO users.
So this is just giving that functionality back to SSO users developing locally.

@rjschill87 hmm I'm not sure I overall agree with using the Login mutation over the email in ti-instances.json, they feel fairly separate to me, but once again I'll defer to you here.

@chrisvariety In a way, the removal of the code I linked kind of forced non-SSO users to use Login over email when dev'ing locally, so this change will at least make email the default unless they explicitly use the Login mutation to set a user.
Or is your issue more along the lines that using the Login mutation updates login event data in the TI platform, even though they're only logging in locally?

@rjschill87 Login mutation has the variables email: String!, password: String! which fundamentally doesn't apply to SSO users. Requiring them to e.g. fill in any value for password doesn't really make sense either, it just doesn't align with the various different ways folks gain access to the Ti platform.
A separate Impersonate mutation, which only takes an email: String!, could make sense, and aligns with how the Ti platform works, but personally I liked the elegance of the previous system where you could just implicitly impersonate someone by specifying their email address in ti-instances.json.

If #172 fundamentally doesn't work, we could consider reverting it as well. It seems like we should put more thought into how that works with the email in ti-instances.json, or consider removing that email (which now just doesn't do anything?)

We can also just ship this to unblock folks and figure the rest out later 😄

@chrisvariety Yeah don't see removing email really being an option as there's not much of a path forward for SSO users (aside from implementing an Impersonate mutation); but since most of the work for supporting email in ti-instance.json still exists seems like the best option at the moment.


allow submissions for NOT ENDED and STARTED phases only

@ mention of reviewers
@Didayolo @bbearce
A brief description of the purpose of the changes contained in this PR.
Now users are blocked from submitting to

ENDED phases
NOT STARTED phases

A warning message in red is shown to users when phase has ended

A warning message in yellow is shown to users when phas has not started

Separate error messages are shown in both cases

Issues this PR resolves
blocks user from submitting to ended phases
Checklist

[x] Code review by me
[x] Hand tested by me
[x] I'm proud of my work
[ ] Code review by reviewer
[ ] Hand tested by reviewer
[ ] CircleCi tests are passing
[ ] Ready to merge

The tests are failing for a good reason: the competition.zip and competition_18.zip, used in the e2e tests, have already passed deadlines in their competition.yaml. These bundles can be found here:
https://github.com/codalab/codabench/tree/develop/src/tests/functional/test_files
The final phase should be updated to "never ending".

@ihsaan-ullah
I think there is a problem for never ending phase, it is considered closed:

@ihsaan-ullah
This is perfect. I like that the box are red and oranges. I merge it now.


Updates to thank-arb-grantees collection

Adding existing projects in OSO Directory to thank-arb-grantees as sourced from the document for top grantees by program.

/validate 71141f2ab3a6613ee54a35703cbbeec5492cf22a


Imports Validation Schemas into the Examples README during CI

Many thanks for submitting your Pull Request :heart:!
Please specify parts of this PR update:

[ ] Specification
[ ] Schema
[x] Examples
[ ] Extensions
[ ] Roadmap
[ ] Use Cases
[ ] Community
[ ] TCK
[x] Other (CI workflows)

Discussion or Issue link:
#801
What this PR does / why we need it:
At the moment, examples are located both in the README and in files for the verification pipeline of the CI.
This means one change needs to be applied to 3 locations: the README json sample, the README yaml sample and the example json file.
This PR adds the possibility to reference external files thanks to an include tag.
When a pull request is merged and at least an example file has been modified, a script will render README_TEMPLATE.md and replace README.md with the output (in the example folder).
This means modifications should not be applied manually to README.md anymore but to the TEMPLATE instead. To try and prevent users from modifying the README directly, a disclaimer header is added to the file and a specific CI check is run when a pull request is opened and the README has been modified.
For the template, the include tag have two attributes:

file (string) the file to render in place of the tag
format (string: json | yaml) if the file should be rendered as JSON or YAML

e.g.: <include file="event-based-greeting.json" format="json" />
When the CI workflow is run, a bot will push a signed commit to a branch and open a PR. To do so, the owners of this repository have to:

Create a (bot) account
Add the bot to the repository (and organization ?) collaborators
Validate the invite with the bot account
Create a signing key for the bot and add the public key in the bot account settings
Generate a Personal Access Token for the bot
Add some secrets in the repository:

BOT_USERNAME - The GH username of the bot
BOT_EMAIL - The email associated to the GH account of the bot
BOT_PAT - The personal access token of the bot
BOT_GPG_PRIVATE_KEY - The private key used to sign commits

Special notes for reviewers:
Additional information:

@JBBianchi I guess for this first PR it's expected that Check examples.... would fail, correct? Since you must edit it anyway.
Maybe we can add a boolean check in the commit message to skip this check? So on a time when we need to edit this file we won't get this big red flag 🤔


Improve Fotoware integration

To be able to find images we have added to a page using the Fotoware integration, we should be able to identify "something" in Sanity.
Is it possible to

change the current alt text field in media image assets to automatically import the Unique document ID from Fotoware instead
shorten the Description field and add the Person shown in the image field below
Private Zenhub Image
Private Zenhub Image

Hi @meols, Unfortunately, changing the alt field during the image import is impossible (sanity's API does not allow it, we can open a feature request if needed). As a workaround, I used the same image name in fotoware for Sanity (that's how it should have been since the beginning, was not working due to a bug). I also added the people in the image below the description but didn't limit it to 2 lines. What is the reasoning behind limiting the description to 2 lines? Here is how a image will look after this fix:

@fernandolucchesi - this is great and will solve what we need :thumbsup: Ideally we should have the unique documentID, since in theory the same image name could be used for more than one image, but image name absolutely work fine. There is no reasoning :rofl: behind limiting the description to two lines - just an attempt to use the same amount of space. What you have done is fine :smile:

@meols @NickHaggerty1 this is ready to be tested on development studio


[Git]: Clicking on CodeDirectory Wreaks Havoc

https://user-images.githubusercontent.com/184176/174204881-2c24c078-6639-4eee-ab37-14a25aaf11c2.mp4

I can’t seem to reproduce this. Are you still seeing this behavior?

This works now.

I'm still getting the DNU and in fact the sent message does not appear to exist in my system. Maybe because I'm loading Magritte and something GT-specific gets overwritten?


New UV Channel imports into a scene file

Describe the project you are working on
3d project
Describe the problem or limitation you are having in your project
We wanted to import more UV channels for use in Godot games.
Describe the feature / enhancement and how it helps to overcome the problem or limitation
The GLTF2 importer will use the all-new extended mesh format to store UVs.
The GLTF2 exporter will store the UV channels from the mesh into the gltf2 file.
Describe how your proposal will work, with code, pseudo-code, mock-ups, and/or diagrams
New glTF importer will have a dropdown to select the lightmap channel:

(default to texcoord1)
None
texcoord0
texcoord1
..
texcoord7

This vec2 is to be stored into custom3 (vec4) and aligned to XY because it would waste two floats if not aligned.
The glTF importer will write

texcoord0->uv,
texcoord1->uv2
texcoord2,3->custom0
texcoord4,5->custom1
texcoord6,7->custom2

The glTF2 exporter will write:

uv->texcoord0
uv2->texcoord1
custom0->texcoord2,3
custom1->texcoord4,5
custom2->texcoord6,7

The importer has a dropdown to select if there are XY or XYW channels and stored in this layout:

uvw0->uv, uv2
uvw1->custom0
uvw2->custom1
uvw3->custom2

If this enhancement will not be used often, can it be worked around with a few lines of script?
Adding new UV channels is not a script change. It is a gltf2 importer change.
Is there a reason why this should be core and not an add-on in the asset library?
Importing UV channels is a core change. It is unable to be integrated with the scene importer/exporters and still be a script.

Written.