Uncaught TypeError: Invalid Point: (565, NaN)

[Steps to reproduce below:]

Opened Atom Editor v1.4.0. Got this error.
Upgraded to the latest v1.4.2, got the same error.

Atom Version: 1.4.2
System: Ubuntu 14.04.3
Thrown From: linter package, v1.11.3
Stack Trace
Uncaught TypeError: Invalid Point: (565, NaN)
At /usr/share/atom/resources/app.asar/node_modules/text-buffer/lib/point.js:63

TypeError: Invalid Point: (565, NaN)
    at Function.module.exports.Point.assertValid (/usr/share/atom/resources/app.asar/node_modules/text-buffer/lib/point.js:63:15)
    at TextBuffer.module.exports.TextBuffer.clipPosition (/usr/share/atom/resources/app.asar/node_modules/text-buffer/lib/text-buffer.js:1015:13)
    at TextBuffer.module.exports.TextBuffer.clipRange (/usr/share/atom/resources/app.asar/node_modules/text-buffer/lib/text-buffer.js:1003:20)
    at MarkerLayer.module.exports.MarkerLayer.markRange (/usr/share/atom/resources/app.asar/node_modules/text-buffer/lib/marker-layer.js:204:46)
    at TextEditorMarkerLayer.module.exports.TextEditorMarkerLayer.markBufferRange (/usr/share/atom/resources/app.asar/src/text-editor-marker-layer.js:78:52)
    at DisplayBuffer.module.exports.DisplayBuffer.markBufferRange (/usr/share/atom/resources/app.asar/src/display-buffer.js:1100:38)
    at TextEditor.module.exports.TextEditor.markBufferRange (/usr/share/atom/resources/app.asar/src/text-editor.js:1339:59)
    at /home/none-da/.atom/packages/linter/lib/editor-linter.js:50:34
    at Function.module.exports.Emitter.simpleDispatch (/usr/share/atom/resources/app.asar/node_modules/event-kit/lib/emitter.js:25:14)
    at Emitter.module.exports.Emitter.emit (/usr/share/atom/resources/app.asar/node_modules/event-kit/lib/emitter.js:125:28)
    at EditorLinter.addMessage (/home/none-da/.atom/packages/linter/lib/editor-linter.js:137:20)
    at /home/none-da/.atom/packages/linter/lib/linter-views.js:104:22
    at Array.forEach (native)
    at LinterViews.notifyEditorLinters (/home/none-da/.atom/packages/linter/lib/linter-views.js:102:11)
    at LinterViews.render (/home/none-da/.atom/packages/linter/lib/linter-views.js:59:10)
    at /home/none-da/.atom/packages/linter/lib/linter.coffee:39:14
    at Function.module.exports.Emitter.simpleDispatch (/usr/share/atom/resources/app.asar/node_modules/event-kit/lib/emitter.js:25:14)
    at Emitter.module.exports.Emitter.emit (/usr/share/atom/resources/app.asar/node_modules/event-kit/lib/emitter.js:125:28)
    at MessageRegistry.updatePublic (/home/none-da/.atom/packages/linter/lib/message-registry.js:84:18)
    at UpdateMessages (/home/none-da/.atom/packages/linter/lib/message-registry.js:24:16)

Commands

Config
{
  "core": {
    "autoHideMenuBar": true,
    "disabledPackages": [
      "grammar-selector",
      "language-c",
      "language-clojure",
      "language-coffee-script",
      "language-csharp",
      "language-java",
      "language-less",
      "language-make",
      "language-mustache",
      "language-objective-c",
      "language-perl",
      "language-php",
      "language-ruby-on-rails",
      "language-sass",
      "language-toml",
      "language-yaml",
      "metrics",
      "archive-view",
      "background-tips",
      "bookmarks",
      "dev-live-reload",
      "encoding-selector",
      "image-view",
      "language-property-list",
      "link",
      "open-on-github",
      "package-generator",
      "spell-check",
      "autocomplete-atom-api",
      "deprecation-cop",
      "exception-reporting",
      "language-go",
      "language-hyperlink",
      "language-source",
      "styleguide",
      "welcome",
      "autosave",
      "keybinding-resolver"
    ],
    "excludeVcsIgnoredPaths": false,
    "ignoredNames": [
      "*.pyc",
      ".git",
      "*egg*",
      "usr"
    ],
    "packagesWithKeymapsDisabled": [
      "linter"
    ]
  },
  "linter": {
    "showErrorPanel": false,
    "showErrorTabFile": false,
    "showErrorTabProject": false,
    "statusIconScope": "File"
  }
}

Installed Packages
# User
angularjs, v0.3.4
atom-ternjs, v0.13.2
autocomplete-python, v1.5.2
color-picker, v2.1.1
editorconfig, v1.2.4
language-ini, v1.14.0
linter, v1.11.3
linter-jshint, v1.3.0
linter-pylama, v0.2.6
pigments, v0.22.1
project-manager, v2.7.5
set-syntax, v0.3.0

# Dev
No dev packages

This is almost certainly a bug in the esprima parser used by jshint. If you want us to verify that you'll need to send the file you were seeing this on somewhere we can access it, but it's unlikely this is necessary.
You might want to look into moving to a linter that supports alternative parsers like eslint or jscs.

Ok. Let me install linter-eslint and give it a shot. Thanks :+1:
On Thu, 4 Feb 2016 at 01:01 Landon Abney<EMAIL_ADDRESS>wrote:

This is almost certainly a bug in the esprima parser used by jshint. If
you want us to verify that you'll need to send the file you were seeing
this on somewhere we can access it, but it's unlikely this is necessary.
You might want to look into moving to a linter that supports alternative
parsers like eslint or jscs.
—
Reply to this email directly or view it on GitHub
https://github.com/atom-community/linter/issues/1062#issuecomment-179417417
.

Switched to eslint and couldn't be more happier :+1:


Update README.md make test command

Change execution tests. Makefile has a test entry but not a tests entry
Description
make tests don't work. Is make test

@victormartingarcia may you look at this minor change. I think you can change without PR and this is not necessary.

Hi @oriolpiera , I think it's fixed #121

Sorry @oriolpiera , you're right. You could make a rebase with master and remove the draft.
I'll merge it.
Thanks!


CLI Tool for Build System

This PR closes the issue #1966.
This PR continue the great work in the PR  #1967.
At the end of this drafts we should have a working CLI tool to build, lint, clean and test the project to replace the current solution using rake
Here is the road map for this PR:

[x] Support build, lint, clean and test commands
[x] Providing an option to report all the build logs to stdout or to the given file
[ ] Test the tool across platforms
[x] Find a better way to get the root repository path. (Using Git?)
[ ] Complete missing test commands

Points for stage 2 (After this is merged?):

[ ] Solve dependencies tree before starting the build function in order to avoid building the same projects many times unnecessarily
[ ] Provide a way to know if the projects have changed since the last build to avoid unnecessary builds

Originally created PR with useful discussion

@DmitryAstafyev I was working on the prettifying the error messages and wanted to eliminate the app panic when it starts outside of chipmunk repo and replace it with an error message, which lead me to use OnceCell from Tokio to achieve that. After implementing it for LOCATION, I've implemented it for TRACKER as well to remove the dependency Lazy-Statics since the same functionality is provided by tokio

I ran into a strange error while implementing the test command for TS bindings, where I need some help. Here are the error infos and what I've found out after some debugging and investigations:
Running the test for the spec jobs leads to the program receiving SIGTRAP because of " Fatal Javascript out of memory" from the operating system even if we run the spec jobs only.  In the most cases the program get terminated without any error but in some cases I've got the following error:
Test Wrapper:
<--- Last few GCs --->
[65036:0x3d58002fc000]       82 ms: Mark-Compact (reduce) 0.8 (3.2) -> 0.8 (2.0) MB, 9.49 / 0.00 ms  (average mu = 0.222, current mu = 0.064) last resort; GC in old space requested
[65036:0x3d58002fc000]       86 ms: Mark-Compact (reduce) 0.8 (2.0) -> 0.8 (2.0) MB, 3.55 / 0.00 ms  (average mu = 0.163, current mu = 0.005) last resort; GC in old space requested
<--- JS stacktrace --->
#
# Fatal JavaScript out of memory: CALL_AND_RETRY_LAST
#
~/chipmunk/application/apps/rustcore/ts-bindings/node_modules/electron/dist/electron exited with signal SIGTRAP

After debugging and investigations I've found the responsible lines of codes for this error. There are two positions worth further investigation:

We use Stdio::piped() when executing the commands in the file spawner.rs line 74. But if we use Stdio::inherit() we don't get this error, but the message will be printed on the console.
The error is produced by calling the method jobs.getShellProfiles() in the file session.jobs.spec.ts line 173. When this line is commented out the command runs in the CLI app with Stdio::pipe() without any problem.
Currently I've commented the spec jobs' out and wrote the information about this problem in a TODO inside the app in the file wrapper.rs` line 122.

I think the problem is with method jobs.getShellProfiles() from typescript having problem to run inside a Stdio::piped() in rust (with tokio runtime).
Since my experience with typescript is very basic I would appreciate it if a typescript expert can have a look on it. @DmitryAstafyev @marcmo

@AmmarAbouZor but the jobs test works with the current build sys based on ruby.
rake bindings:test:jobs

@DmitryAstafyev Sorry I didn't mention that I've had the same observation while I was investigating in it. It works with Rust too if we set the stdout in Rust command to Stdio::inherit() instead Stdio::piped() in  the filespawner.rs line 74.
The problem happens only if the typescript function runs inside a piped stdout in Rust runtime.

I've finally implemented a work-around for the problem with Stdio with TS bindings tests.

I've created a new method in the tracker that suspends the progress bars and run the giving blocking command.
All TS command run sequentially with Stdio::inherit() printing their outputs direct to the command line while the bars are suspended.
After the commands are finished the progress bar will be shown again.

The CLI tool can now be installed and invoked as cargo extension or sub-command
To install it we can use cargo install --path=cli
And after the installation we can invoke the command via cargo cargo chipmunk {args}

Builds will be tracked in a shared map to prevent duplications
When a build is called the shared map will be checked and it will proceed as following:

If the build already done then return early with its result
If the build is running then wait for it to be done then return its result
If the build hasn't started then start it and update the build states map

I made a large refactoring to replace the trait Manager with the enum Target to improve the structure and the readability of the code.
This refactor solved the problem with the duplicated install calls to install TS bindings tools between TS and RS bindings
The crate async-trait has been removed since it's not used anymore
I had to solve the problem that (recursive async calls aren't supported in rust currently) with Boxed Futures

I've tested the tool on Windows and made some fixes to make work there and it's working.
I think this PR is ready for review now since it has all the needed functionalities. I've marked at as ready for review and I'll continue working on the auto completion while it's being reviewed

Shell Completion has been added

I've started with the re-write to calculate the jobs upfront and I marked this PR as draft again until the re-write is done

Following steps in the re-write to app logic has been done:

Jobs dependencies will be resolved upfront which make it possible to write unit-tests for them too
All jobs will be viewed on the status bar from the start with the new stat wait for the pending jobs that are waiting for their dependencies
Jobs will still run concurrently
Linting TS targets pulls build jobs for all involved targets in their dependencies because TS linting doesn't check for type correctness which is only possible with build. This was solved before by calling build command from linting function which led to errors when linting is called after clean.
New print dot CLI argument has been added to print all the tasks alongside with the current print-dot command that prints the targets only
Missing paths for clean command has been added.
When an install job fails, their corresponding build and copy jobs will be automatically skipped but the other jobs will still run
Yarn 4 Integration form master are already built within this PR

Changes tests on Windows at it seems it's working fine

Hi @DmitryAstafyev
Here is a list of all included features that needed to be tested on this PR:

All commands (build, clean, test, lint, run) should run cross-platform.
Checksum computation to figure out if something has changed on some target, then all the targets who are dependent on it must be built too.
Build functions will be called in the linting for TypeScript and the Checksums + Dependencies build will be applied here as well.
Print dot function to print dependencies between the main targets and their tasks as well.
Shell completion.

@DmitryAstafyev @marcmo

I've created integration tests for all provided commands on the CLI tool + Tests for the checksum implementation for detect code changes and for the dependencies between build targets.
I've also fixed unit-tests from wasm-bindens that weren't working on Windows and added Clippy fixes for Windows.
The integration tests are tested on Linux and Windows only

@DmitryAstafyev @marcmo
I've integrated the CLI tool in a separate GitHub Actions for reference now.
These steps are just for testing for now and would need more improvements once we want to replace the current ones with them

Hi @marcmo,
As we had spoken yesterday, the following changes have been added:

mathces!() macros and catch-all place holders in match statements have been replaced with explicit types, this will keep the compiler assistance powerful when we add more targets or job types in the future
Boolean in Checksum comparison map has been replaced with an enum to enforce logic correctness with rust type system
While making the changes I've found out that we have been running build steps for all test targets which is needed for typescript and WASM targets only. This has been fixed as well.

@marcmo Requested changes are implemented/answered. The PR can be reviewed again :+1:


⚠ Bofrost.fr has degraded performance

In 69c9d0c, Bofrost.fr (https://www.bofrost.fr) experienced degraded performance:

HTTP code: 200
Response time: 1313 ms

Resolved: Bofrost.fr performance has improved in 5a916e8 after 10 minutes.


Use custom OpenSSL engine - GOST TLS

How can I use the GOST engine from the custom assembly OpenSSL
OpenSSL works great with this engine, as does curl. But when you try to use in Java - nothing comes out
For example, I declare
System.setProperty ("org.wildfly.openssl.path", "/usr/local/ssl/lib/");
In log:
2020-02-19 14: 19: 52.581 INFO 28673 --- [restartedMain] org.wildfly.openssl.SSL: WFOPENSSL0002 OpenSSL Version OpenSSL 1.1.1d 10 Sep 2019
It's fine, but not work.
when trying to connect to the host, I get an error:
org.springframework.web.client.ResourceAccessException: I/O error on POST request for "https://{host}/api/v1/account/login":
error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure; nested exception is javax.net.ssl.SSLException:
error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure

Block of code with details SSLContext

KeyStore trustedKeyStore = KeyStore.getInstance ("JKS");
trustedKeyStore.load (new FileInputStream ("/home/ubuntu/demo/trustStore"), "truststore" .toCharArray ());

TrustManagerFactory tmf = TrustManagerFactory.getInstance (TrustManagerFactory.getDefaultAlgorithm ());
tmf.init (trustedKeyStore);

SSLContext sslContext = SSLContext.getInstance ("openssl.TLS");
sslContext.init(null, tmf.getTrustManagers(), null);

From the code perspective,  you can take a look at this source file.
https://github.com/wildfly-security/wildfly-openssl-natives/blob/main/libwfssl/src/ssl.c
Line 537.
ssl_thread_setup();
/* TODO: engine support? */
So I think this library doesn't support custom engine now.
Could anyone add the support to custom engine ? We also need this feature now.


MBL-1338: Re-fetch stored cards after login

📲 What
Re-fetch stored cards after login.
🤔 Why
If you weren't logged in the first time you accessed the late pledge page, we never fetched your stored cards. This means that, when you tapped on submit, one of the prerequisites was missing and your pledge would never complete.
⏰ TODO

[x] I'm getting a server 500 when I try to complete the pledge. Asking in Slack for help with that and leaving this as a draft for the moment.

⏫ Follow up
I created a ticket  for us to resolve the 500, which is due to where we call Checkout vs. where we call Login.

SwiftFormat found issues:

File
Rules

Library/ViewModels/PostCampaignCheckoutViewModelTests.swift:509:1
warning: (trailingSpace) Remove trailing space at end of a line.

  Generated by :no_entry_sign: Danger


Synapse SQL query for SStream not working in Azure Data Studio

Issue Type: Bug
Here is a query that is not working in Azure Data Studio that is working in Synapse.
SELECT TOP 10 *
FROM OPENROWSET(
BULK 'Path/2021/11/Stream.D1_2021_11_14.ss',
DATA_SOURCE = 'PROCESSED',
FORMAT = 'SStream',  PARSER_VERSION='2.0'
) AS a
I get the following error
"Incorrect syntax near 'FORMAT'"
Azure Data Studio version: azuredatastudio 1.33.1 (0b9ef714c823d662815f441aec4a94eaa21940f8, 2021-11-04T17:45:15.872Z)
OS version: Windows_NT x64 10.0.22000
Restricted Mode: No

System Info

Item
Value

CPUs
Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz (8 x 1498)

GPU Status
2d_canvas: enabledgpu_compositing: enabledmultiple_raster_threads: enabled_onoop_rasterization: enabledopengl: enabled_onrasterization: enabledskia_renderer: enabled_onvideo_decode: enabledvulkan: disabled_offwebgl: enabledwebgl2: enabled

Load (avg)
undefined

Memory (System)
31.59GB (12.39GB free)

Process Argv

Screen Reader
no

VM
0%

Extensions: none

Hi @mmiryala2, what are you attempting to connect to in both Synapse Studio and in Azure Data Studio?

@mmiryala2 please reopen with answers to Alan's question.


On trying to change email to one already taken by another user, notify the user that it's already taken

Apparently it just fails silently right now

What's the flow? going under your own account > details > edit the email address?

I just wrote that down quickly while handling a ticket 😅 repro details should have been here in the first place, though.

Open chobby
Log in
Account -> Recover/Change tab
type a taken "New email address": value
see "Request accepted, enter verification code received via email" green message - it should probably check whether the email is valid instead


Nothing logged to syslog on iOS

My setup

iOS 13.2
macOS 10.14

Problem

zf_log does not log to syslog as advertised.

Repro

Build and run a test app on an iPhone using zf_log APIs in the same manner as in examples/hello.c, i.e., calling the following

zf_log_set_tag_prefix("MyHeader");
ZF_LOGW("Hello ZF_LOG!!");

Then open Console.app on macOS and select the phone in the sidebar

Search for keyword such as ZF_LOG in the log.

Console returns nothing in the search result.

The log is only visible in the Xcode console.

I wonder if this has anything to do with having ASL as the backend, syslog works for me. I've never used ASL though.

See custom_output.c, it doesn’t log every where by default, you need to configure it.

Also see ZF_LOG_USE_NSLOG in zf_log.c.

@wonder-mice Thanks for the prompt reply. I tried to port the custom_output.c into a barebone iOS app.
- (void)viewDidLoad {
    [super viewDidLoad];
    // Do any additional setup after loading the view.
    #if defined(OUTPUT_SYSLOG)
        openlog("custom_output", LOG_CONS|LOG_PERROR|LOG_PID, LOG_USER);
    #endif

    const unsigned put_mask =
    #if defined(OUTPUT_SYSLOG)
        ZF_LOG_PUT_STD & !ZF_LOG_PUT_CTX;
    #else
        ZF_LOG_PUT_STD;
    #endif

    zf_log_set_output_v(put_mask, 0, custom_output_callback);

    int argc = 3;
    char* argv[] = {"myprogram", "myparam1", "myparam2"};
    ZF_LOGI("KAKYO: INFO: Number of arguments goes into custom output: %i", argc);
    ZF_LOGW("KAKYO: WARNING: Number of arguments goes into custom output: %i", argc);
    ZF_LOGE("KAKYO: ERROR: Number of arguments goes into custom output: %i", argc);
    ZF_LOGI_MEM(argv, argc * sizeof(*argv), "and argv pointers as well:");

    #if defined(OUTPUT_SYSLOG)
        closelog();
    #endif
}

All the helpers have been copied into the same source files, and the program runs without crashing.
However, I still don't see anything related to the logging code in the syslog, i.e., the one associated with my iPhone OS, viewed from Console.app on macOS.
Could you explain what exactly I should see? Right now what I can see are a few lines in the Xcode console:
2019-11-14 19:44:24.535668+0800 hello_zflog[5268:1548106]
2019-11-14 19:44:27.165700+0800 hello_zflog[5268:1548106]
2019-11-14 19:44:28.116835+0800 hello_zflog[5268:1548106]
2019-11-14 19:44:28.861495+0800 hello_zflog[5268:1548106]

They clearly correspond to my ZF_LOG calls, but the messages don't look like what I give the API calls.

I modified the callback to use msg->msg_b,
static void custom_output_callback(const zf_log_message *msg, void *arg)
{
    (void)arg;
    /* p points to the log message end. By default, message is not terminated
     * with 0, but it has some space allocated for EOL area, so there is always
     * some place for terminating zero in the end (see ZF_LOG_EOL_SZ define in
     * zf_log.c).
     */
    *msg->p = 0;
#if defined(OUTPUT_DEBUG_STRING)
    OutputDebugStringA(msg->buf);
#elif defined(OUTPUT_SYSLOG)
    syslog(syslog_level(msg->lvl), "%s", msg->msg_b);
#else
    #error Unsupported platform
#endif
}

but still can only see garbage output:
2019-11-14 19:58:17.398582+0800 hello_zflog[5282:1552635] 8\M^Tt
2019-11-14 19:58:17.398666+0800 hello_zflog[5282:1552635] 8\M^Tt
2019-11-14 19:58:17.398702+0800 hello_zflog[5282:1552635] 8\M^Tt
2019-11-14 19:58:17.398759+0800 hello_zflog[5282:1552635]

Maybe I'm stupid. But I really couldn't figure out how to use this feature. Since there is a lack of documentation, could you kindly point me to the right direction?
What I would like to achieve:
Run the barebone iPhone app, and see the four lines of messages in the default iPhone syslog, i.e., they one associated with the phone seen in Console.app.
Thanks in advance!


jobDocumentParser is broken

in ota_over_mqtt_demo.c
the function jobDocumentParser does not parse the JSON correctly.
after jobDocLength = Jobs_GetJobDocument( message, messageLength, &jobDoc );
I call ESP_LOGE(TAG, "job doc: %s", jobDoc);
but the result is E (13504) ota_over_mqtt_demo: job doc: {"afr_ota":{"protocols":["MQTT"],"streamname":"AFR_OTA-bf707e32-11f9-4b40-a406-6989b1af799f","files":[{"filepath":"/","filesize":1449840,"fileid":0,"certfile":"Code Verify Key","sig-sha256-ecdsa":"MEUCIQCBhWhsLLGmI8LSiX85mk90bdBStqj8bnuHCVlcKedlCwIge6N8hS6y+S90W7RopIo8oC9sXj9uXU8mksKCxEA9dDk="}]}}}}
Which is not valid JSON.
So when I later try to query jobFields.filepath I get the wrong path E (16984) ota_over_mqtt_demo: Path is /","filesize":1449840,"fileid":0,"certfile":"Code Verify Key","sig-sha256-ecdsa":"MEUCIQCBhWhsLLGmI8LSiX85mk90bdBStqj8bnuHCVlcKedlCwIge6N8hS6y+S90W7RopIo8oC9sXj9uXU8mksKCxEA9dDk="}]}}}}
I am using these features to download non-firmware files, so I need to detect the path.

possibly I am overlooking filepathlen, sorry if that is the bug

indeed it was, apologies.


Smallest fixes from static source analyzer

Smallest fixes from static source analyzer (some security and speed optimization's)

Great, thank you. I'll merge this.
Which code analysis tool did you use?

PHPStorm with PHPInspections (EA)


signed ssh key

is there a possibility to store a signed ssh key, which should be in the same folder as the pub-key.
https://access.redhat.com/documentation/de-de/red_hat_enterprise_linux/6/html/deployment_guide/sec-creating_ssh_ca_certificate_signing-keys
the procedure is relativ unknown but still very useful, with it you can give different public keys temporally access to different devices

seems to be too unknown, too bad.

I would also like to use signed keys with semaphore. Is this possible?


Term change suggestion SDG01 - [poor families]

SDG: 1
Target & phrase: target 1.2
Suggested term/change: Add "families"/"family" to children, communities etc.
Reason: Also likely to be used in the relevant context

SDG: 7
Target & phrase: 7.1, phrase 3
Suggested term/change: Add "paraf$in" to "dirty fuels"
Reason: Also likely to be used in the relevant context


[KO Number] Korean Percentage refinements

Al test cases pass.

@aitelint Approved. Please resolve the conflicts to merge. Thanks!

conflict solved


Flow requires me to explicitly annotate useState only if I return the setter function

Flow version: 0.93.0
Expected behavior
Flow should allow me to return the setArg function in [arg, setArg] = useState('initial'), e.g.:
export const useHook = (initial: string) => {
  const [arg, setArg] = useState(initial);

  return [arg, setArg];
};

Actual behavior
Flow requires I provide an annotation to the useState() call, but only if I return the setter function. If I do not, I am not required to annotate useState().
Return only the arg, not the setter:
export const useHook1 = (initial: string) => {
  const [arg, setArg] = useState(initial);

  // type-at-pos shows
  // arg: string
  // setArg: ((((string) => string) | string)) => void

  return arg;
};

Return the arg and setter, without explicitly specifying <S>
export const useHook2 = (initial: string) => {
  // Missing type annotation for `S` [...] implicitly instantiated at call of `useState`.
  const [arg, setArg] = useState(initial);

  // type-at-pos shows
  // arg: any | string
  // setArg: ((((any) => any) | any)) => void

  return [arg, setArg];
};

Return the arg and setter, do explicitly specify <S = string>
export const useHook3 = (initial: string) => {
  const [arg, setArg] = useState<string>(initial);

  // type-at-pos shows
  // arg: string
  // setArg: ((((string) => string) | string)) => void

  return [arg, setArg];
};

Link to Try Flow
View on Try Flow

I believe it's a case of the situation described here: https://medium.com/flow-type/asking-for-required-annotations-64d4f9c1edf8

In order to infer a type, Flow needs to see all the values that might reach a given position. In order to infer types in input positions which are exported from a module, Flow would need to analyze files together with all of their transitive dependents. This is called “global” type inference, and while theoretically possible, this would be impossible to scale to the size of our codebase.
Instead of global type inference, Flow makes a humble request: annotate the input positions of your modules and we can infer the rest. This makes it possible to infer modules in parallel in dependency order.

By exporting setArg, Flow can no longer globally infer all the possible values that could flow into that state (the fact that initial is a string is a bit irrelevant when it comes to overall safety of the codebase).
Either way, it's not like adding <string> is particularly cumbersome...?
Agree the error message could be clearer though, like mentioned in #7497

Yeah, I was wondering if flow behaves because of the input-export situation you linked. And you're right, adding <string> is not cumbersome and is what I ended up doing. However, I wanted to flag this for two reasons:
First, because flow types arg and setArg differently based on whether I export setArg. My expectation is that if flow is able to recognize arg as string and setArg as (string) => void when I don't export setArg, flow should continue to recognize those types even when I export setArg as well. Or on the flip side, if flow requires me to annotate useState(), it should do so whether or not I export setArg.
Second, because based on the libdef for useState, it looks like flow ought to be able to infer both arg and setArg as <S = string>. That is, I don't think the act of exporting setArg should cause an generic type to be exported, since <S> should be made concrete with the type of the initialState argument.
declare export function useState<S>(
  initialState: (() => S) | S,
): [S, ((S => S) | S) => void];

Of course, I may be misunderstanding what Flow does when it tries to infer types from arguments. If so, I'm sorry for the noise and please feel free close the issue.

As far as I understand the point is: if you're not exporting setArg outside of the file, Flow can trivially find all usages of it, and therefore infer a type for S that satisfies all those usages.  It doesn't matter if initialState is of type string, because that could still satisfy an S of, say, string | number.
However, if you export it, there are now thousands of other potential call sites, and solving inference around that becomes a lot more challenging.  For reasons of performance on large codebases, the Flow team made the conscious decision to force type annotations in this instance.  This gains abilities such as parallelisation, like they mention in the blog post, without sacrificing soundness.
While in theory yes it might be the better DX to globally infer all the inputs anyway (and like they say in the blog post that would have worked before Flow 0.16), it's a conscious trade-off that's been made for practical performance reasons.

I see, that makes sense. Thanks for your time and the explanation.


Update README.md

Description
Fix #374

Thanks for the contribution, but some of these are intended. We'll be doing a review of the README with content-strategy in the future and won't be revising it until then.


[Doom - Downgrade] Execute downgrade to free plan when subscription ends

Related design doc
Tasks:

Create<EMAIL_ADDRESS>that would be the purview of the eng runner (& update eng runner related docs)
Update handling of stripe webhook event `customer.subscription.deleted``

Mark Subscription as ended
All users except first admin are marked as revoked
send an email to<EMAIL_ADDRESS>who should monitor the downgrdande, and manually delete connections on poke
subscribe workspace to free plan (via subscribeWorkspaceToPlan fn)

As discussed in the design docs,
Given the need to monitor the downgrades
Given the ~ flakyness of deletions,
The above todo was updated to send an email to<EMAIL_ADDRESS>and that the workspace connections should be manually deleted on poke on reception of the email
<EMAIL_ADDRESS>would be the purview of the eng runner

Getting workspace back to free plan was actually a no op (a workspace with no active subscription is on the free plan)


remove docker-unconfined profile we were not using it

it breaks otherwise on wheezy
ping @ewindisch :(

+1

LGTM

LGTM -- We could just remove 'ptrace' and 'signal' and it would work, but no harm in removing it for now I guess.

cheery picked into #15091


Read coordinates wanted?

I made a simple implementation to get the value at a specific coordinate:
use std::{fs::File, io::BufReader};

use georaster::geotiff::GeoTiffReader;

const DEM_LOCATION: &str = "data/srtm_germany_dtm.tif";

fn main() {
    let img_file = BufReader::new(File::open(DEM_LOCATION).unwrap());
    let mut tiff = GeoTiffReader::open(img_file).unwrap();

    let (lat, lon) = (47.346721, 11.081273 );

    let (origin_x, origin_y) = tiff.origin().unwrap().into();
    let (pixel_size_x, pixel_size_y) = tiff.pixel_size().unwrap().into();

    let x = ((lon - origin_x) / pixel_size_x) as u32;
    let y = ((lat - origin_y) / pixel_size_y) as u32;

    println!("Origin: {origin_x}, {origin_y}");
    println!("Pixel_size: {pixel_size_x}, {pixel_size_y}");
    println!("Coordinates: {x}, {y}");

    println!("Height in Karlsruhe: {}", tiff.read_pixel(x,y));
}

Is this wanted in this crate?
Would like to contribute!
A little bit of misc like interpolating dem values would also be nice to have (maybe in a geotiff_dem wrapper to not pollute the geotiff or guide people to interpolate on rgb data)

A helper function like this definitively fits into georaster. PR very welcom!

In order to handle locations I can either:

just use (f64, 64) (bad, because coordinates can be confused and switched)
define our own struct
use https://crates.io/crates/geo as dependency

I'm for defining our own struct like:
pub struct Coordinate
{
    pub x: f64,
    pub y: f64,
}

impl From<(f64, f64)> for Coordinate {
    fn from(coords: (f64, f64)) -> Self {
        Coordinate {
            x: coords.0,
            y: coords.1,
        }
    }
}

impl From<[f64; 2]> for Coordinate {
    fn from(coords: [f64; 2]) -> Self {
        Coordinate {
            x: coords[0],
            y: coords[1],
        }
    }
}

This is the same as rust-geo, which I don't want to have as a dependency for now, since it's 2D vector only.


Cannot install app on ios device

What App Center service does this affect?
ios release
Describe the bug
I cannot install app on a registered device. In App center, the device shows as provisioned. When I click "Get", is errors and says "Oops, the app cannot be built". The app is built in Azure DevOps and worked until yesterday afternoon.
To Reproduce
Steps to reproduce the behavior:
Select a release
Click "Get"
Expected behavior
The app should install
Smartphone (please complete the following information):

Device: iPhone XR
OS: 12.3.1
Browser Safari

Hi, can you create an intercom ticket on appcenter.ms (? on top right corner or blue button on buttom of screen)? Someone from the dev team will be able to help you.

Experiencing same issue with iPhone XS Max

We are facing same issue.


Block arming if takeoff waypoint is inactive and MIS_TKOFF_REQ is set to1

Describe problem solved by this pull request
Currently PX4 has no pre-arm checks that check to see if a takeoff waypoint is active. It checks to make sure that a mission has a takeoff waypoint, but that's the extent of it . This can be an issue for fixed wings, especially hand launched ones as arming the vehicle without the first waypoint active will not activate launch detection. This will lead to failed takeoffs. This PR adds a check to determine if the takeoff waypoint is active or not.
Describe your solution
I added a check in the prearm checks to determine if the current active waypoint is a takeoff waypoint from the position setpoint. This is also tied to the MIS_TAKEOFF_REQ parameter. My thought process is that if you have this parameter active, then you probably want added protection against potentially arming the vehicle in a non-takeoff state.
Describe possible alternatives
Currently if the position setpoint is not a takeoff setpoint, the vehicle will not arm. This means that you can not arm in "Manual" modes if the parameter is set. This could be changed to allow this check to function in only "Auto" modes.
Test data / coverage
A version of this has been in use on our fixed-wing vehicles for the past 3 months. This version has been ground tested with the parameter active and inactive.
Additional Context
This was added after we had a number of users arming the airplane with a non-takeoff waypoint active.

FYI @TSC21 this builds on the PR you did about a year ago: https://github.com/PX4/Firmware/pull/11531 that added the parameter MIS_TAKEOFF_REQ

I should also mention this is in response to #10657


Allow toggling Activity Bar / Status Bar in Zen Mode

Does this issue occur when all extensions are disabled?: Yes
Version: 1.66.2
Commit: dfd34e8260c270da74b5c2d86d61aee4b6d56977
Date: 2022-04-11T07:49:24.808Z
Electron: 17.2.0
Chromium: 98.0.4758.109
Node.js: 16.13.0
V8: <IP_ADDRESS>-electron.0
OS: Linux x64 5.15.0-25-generic
Steps to Reproduce:

open zen mode
run  toggle activity bar visibility

Some extensions have important function inside activity bar.  Unable to toggle activity bar in Zen mode is unproductive.

At first I thought this was a regression from previous layout work, but I've determined that this is long standing behavior. I agree we can improve here, but it isn't happening immediately.


Code for Cifar_10 One-Class Novelty Detection task

Thank you for sharing with us this outstanding work.I'm really impressed.
May I know if the code for One-Class Novelty Detection task applied on cifar-10 dataset is also available for public.

Thank you for sharing with us this outstanding work.I'm really impressed. May I know if the code for One-Class Novelty Detection task applied on cifar-10 dataset is also available for public.

可以运行了 但是在cifar10的结果巨差

Thank you for sharing with us this outstanding work.I'm really impressed. May I know if the code for One-Class Novelty Detection task applied on cifar-10 dataset is also available for public.

可以运行了 但是在cifar10的结果巨差

能说一下你是怎么运行的吗？


DNS issue - 'Certificate  must be in 'us-east-1' when the AWS_REGION=us-west-2

First thanks for this repo. Really cool idea, and I'd like to use it - thanks for being a good steward of your community by open sourcing this.
On to the question"
When running the npm run dns step after getting certificates properly accepted, I get an odd error.
$ npm run dns                                                                                v6.11.3 | 04:37 pm

><EMAIL_ADDRESS>dns /Users/j/myproj
> AWS_PROFILE=personal-arc AWS_REGION=us-west-2 arc-dns

Found Route53 hosted zone mydomain.com

Please ensure your domain registration is using these nameeservers:
ns-xx.awsdns-x.net.
ns-xx.awsdns-x.co.uk.
ns-xx.awsdns-x.org.
ns-xx.awsdns-x.com.

/Users/j/myproj/node_modules/aws-sdk/lib/request.js:31
            throw err;
            ^

BadRequestException: Invalid certificate ARN: arn:aws:acm:us-west-2:xxxxx:certificate/xxx-xxx-xxx. Certificate must be in 'us-east-1'.
    at Object.extractError (/Users/j/myproj/node_modules/aws-sdk/lib/protocol/json.js:48:27)
    at Request.extractError (/Users/j/myproj/node_modules/aws-sdk/lib/protocol/rest_json.js:45:8)
    at Request.callListeners (/Users/j/myproj/node_modules/aws-sdk/lib/sequential_executor.js:105:20)
    at Request.emit (/Users/j/myproj/node_modules/aws-sdk/lib/sequential_executor.js:77:10)
    at Request.emit (/Users/j/myproj/node_modules/aws-sdk/lib/request.js:683:14)
    at Request.transition (/Users/j/myproj/node_modules/aws-sdk/lib/request.js:22:10)
    at AcceptorStateMachine.runTo (/Users/j/myproj/node_modules/aws-sdk/lib/state_machine.js:14:12)
    at /Users/j/myproj/node_modules/aws-sdk/lib/state_machine.js:26:10
    at Request.<anonymous> (/Users/j/myproj/node_modules/aws-sdk/lib/request.js:38:9)
    at Request.<anonymous> (/Users/----/myproj/node_modules/aws-sdk/lib/request.js:685:12)

npm ERR! Darwin 15.6.0
npm ERR! argv "/Users/jono/.nvm/versions/node/v6.11.3/bin/node" "/Users/jono/.nvm/versions/node/v6.11.3/bin/npm" "run" "dns"
npm ERR! node v6.11.3
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE
npm ERR<EMAIL_ADDRESS>dns: `AWS_PROFILE=personal-arc AWS_REGION=us-west-2 arc-dns`
npm ERR! Exit status 1

Above are the node version and npm version, I'm a bit confused I read here:

Q: Can I use the same certificate in more than one AWS Region?
It depends on whether you’re using Elastic Load Balancing or Amazon CloudFront. To use a certificate with Elastic Load Balancing for the same site (the same fully qualified domain name, or FQDN, or set of FQDNs) in a different Region, you will must request a new certificate for each Region in which you plan to use it. Note that this requires re-validating each name in the certificate for the new Region. To use an ACM certificate with Amazon CloudFront, you must request the certificate in the US East (N. Virginia) region. ACM certificates in this region that are associated with a CloudFront distribution are distributed to all the geographic locations configured for that distribution.

Maybe there is something going on in the background of arc that makes an assumption about zones that don't hold? Or more likely I'm missing something. Any suggestions?

 I forgot about this yes. We need to update the docs to warn about this. API Gateway custom domains can only use certs in us-east-1 currently. (You can still deploy the API Gateway part to any region / only the certs are limited.)
Good news is you also have an easy fix!

Login to the AWS Console
Go to AWS Certificate Manager in us-west-2 and delete the offending certs
Change the region to us-east-1 and generate certs for your domain (eg. mydomain.com and staging.mydomain.com)
Rerun npm run dns and it should setup the API Gateway mapping using the certs from us-east-1 in your us-west-2 API Gateway

LMK how this goes for you!

@brianleroux thanks! Just to confirm, I did step 3 without changing the region back to us-west-2.
I did steps 0-2 and it worked fine, though I don't see anything about staging.mydomain.com  in the output - do I have to manually do something about that?
Step 3 outputs this (again region for dns command is still us-east-1.
Found Route53 hosted zone mydomain.com
...
.../node_modules/aws-sdk/lib/request.js:31
            throw err;

TypeError: Cannot read property 'CertificateArn' of undefined
.../node_modules/@architect/workflows/src/dns/04-create-domain.js:41:96

Next step:
.../node_modules/aws-
sdk/lib/request.js:31
            throw err;
            ^

Error: missing api! undefined not found
    at Error (native)
    at Response._list (.../node_modules/@architect/workflows/src/dns/05-create-mapping.js:65:25)

I think this may have to do with the fact that I only have two domains names issued, *.mydomain.com and mydomain.com. However, the line in questions is:
line 65:
     if (!staging) throw Error(`missing api! ${staging} not found`)

Which makes me believe there is some lack of staging creation going on.

Ok! We're close. Looks like the API Gateway deployments haven't been created yet. (The offending line can't find any.)
Can you make sure you npm run create to generate the deployment code and then re-run npm run dns ?

[!] $ npm run create                                            v6.11.3 | 02:47 pm

><EMAIL_ADDRESS>create /...
> AWS_PROFILE=personal-arc AWS_REGION=us-west-2 arc-create

skip @html code src/html/get-login exists
skip @html worknicer_meraki-production-get-login exists
skip @html worknicer_meraki-staging-get-login exists
skip @tables worknicer_meraki-production-arc-sessions exists
skip @tables worknicer_meraki-staging-arc-sessions exists
skip @scheduled code src/scheduled/log_users_out_of_meraki exists
skip @scheduled ..-staging-log_users_out_of_...exists
skip @scheduled ..-production-log_users_out_of_.. exists
skip @html /login exists
skip @html /login exists
skip @html /login exists
skip @html /login exists

successfully deployed
https://xxx.execute-api.us-west-2.amazonaws.com/staging
https://xxx.execute-api.us-west-2.amazonaws.com/production

But then I get the same error when I run npm run dns. Could it be because of the mismatch of regions? DNS is east, npm run create is west.

oh! ya, try switching the npm run dns to point at us-west-1 now that the certs are created (sorry this is super confusing!)

Doesn't look right, I just replaced it - and it's now re-requesting certs.

ok lemme see here 1s (also if you wanna move to a more real time comms we have a slack! https://architecture-as-text.slack.com/join/shared_invite/MjE2MzU4Nzg0NTY1LTE1MDA2NzgyMzYtODE2NzRkOGRmYw )

AHA
I do have a bug here. It should look for certs in us-east-1 only and it doesn't. Gimme a sec and I'll  push a patch.

Thx for help on this! 💯 🥇 💕


PNG files detected as executables

The bug
When NorMatrix check if executable is created, its detect *.png files as executables files.
To Reproduce

Place a png file on a folder
Launch NorMatrix on it.

Expected behavior
Maybe just ignore PNG files ? I don't know if png are able to cause issues for Marvin, maybe just check if its name is on snake_case
Desktop:

OS: GNU/LINUX - Pop!_OS
Version [21.10]

if you check the permissions for your png, you will see that it has executable permission (ls -l yourpng.png)
i check all file that have the executable permission


Test users v1

Codecov Report

Merging #102 (281c4d0) into main (bf1c199) will increase coverage by 1.14%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##             main     #102      +/-   ##
==========================================
+ Coverage   69.64%   70.78%   +1.14%
==========================================
  Files         239      239
  Lines        5939     5939
==========================================
+ Hits         4136     4204      +68
+ Misses       1803     1735      -68

Impacted Files
Coverage Δ

...t/APIv1/Users/Requests/GetUsersShowRequestV1.swift
100.00% <0.00%> (+100.00%)
:arrow_up:

...APIv1/Users/Requests/GetUsersLookupRequestV1.swift
100.00% <0.00%> (+100.00%)
:arrow_up:

...APIv1/Users/Requests/GetUsersSearchRequestV1.swift
100.00% <0.00%> (+100.00%)
:arrow_up:

...sers/Requests/GetUsersProfileBannerRequestV1.swift
100.00% <0.00%> (+100.00%)
:arrow_up:

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 bf1c199...281c4d0. Read the comment docs.


Adding support for passing TTY to dalli

Setting a TTY can be useful for preventing deadlocks (if the process fails inexplicably, for example).

Sorry, I messed up the PR here. I'll make another commit and fix.

OK, fixed.

Moved to https://github.com/songkick/mega_mutex/pull/4.


Add Http Data To All Logging Events

Hello, this package adds a new logging event for each HTTP request that occurs. I was wondering if it's possible to add the HTTP logging to all logging events, so we can have the HTTP data available to us. So if I log some data, Log.Information("Testing"), the HTTP data gets added to it too.
Thanks

Hi,
Sorry I don't think we'd want to do this as this would generate heavy events.
The usual approach is to have "one fat event" with the http specific data, and have a correlation id shared across all events of that same HTTP request, so you can get to that data somehow.
Closing it, but happy to discuss it 👍


[Event Request] Codeunit 5896 "Calc. Inventory Adjmt. - Order" OnBeforeFindItemLedgEntryCalcActualMaterialCosts

I am working on a solution for a client dealing with sharing manufacturing costs across multiple production order lines and need an events for OnBeforeFindItemLedgEntryCalcActualMaterialCosts

The variables needed are:
Var	Name	DataType	Subtype	Length
Yes	InvtAdjmtEntryOrder	Record	Inventory Adjmt. Entry (Order)
Yes	ItemLedgEntry	Record	Item Ledger Entry

This would be called in the CalcActualMaterialCosts function before the Find so filters could be changed to get all the lines instead of the single line.

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability.

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability.


Compare image issue

Hey:
Thaknks for creating this. I'm trying to get this to work for the first time. I took a baseline image and now i switched to test mode. It takes both the baseline and test image and they look the same, but when it runs the compare images in test mode, it errors
ValueError: could not convert string to float:

Wondering if you can help out?
thanks

You need to install Imagemagick as stated in the readme. If you already installed it, you probably need to add imagemagick installation folder to your PATH environment variable.

thank you all. I had installed Imagemagick and add the folder location to my PATH Env variable but i did not reboot. After reboot, I'm good to go.
One quick question i was able to capture image and compare, working great. Are there any functions to compare regions and/or elements?
thanks again

@y2j44 You can capture an element in a page using the capture element keyword ( refer ReadMe). Eg: capture element
Feel free to raise any feature requests that you feel can add value. There are some tasks in Todo like making this seamless when run using pabot. Feel free to collaborate

that's awesome. thanks so much!


[Aborea] bugfixes & improvements

Submission Checklist
Required

[X] The pull request title clearly contains the name of the sheet I am editing.
[X] The pull request title clearly states the type of change I am submitting (New Sheet/New Feature/Bugfix/etc.).
[X] The pull request makes changes to files in only one sub-folder.
[X] The pull request does not contain changes to any json files in the translations folder (translation.json is permitted)

Changes / Description

Fix irrer Flugweg
Add calculation armor in attackmacro
Fix darkmode

Character Sheet Info Roll20 Internal Use only.


Treat ENV['RESQUE_TERM_TIMEOUT'] as a float

As reported in https://github.com/nevans/resque-pool/issues/162, setting RESQUE_TERM_TIMEOUT in the environment results in a crash on exit because the number is treated as a string.
This is overriding the resque gem's worker.initialize function, which does correctly treat it as a float.

Could we please have this merged and a new version published?
This is being a problem since resque 1.27.3.

@nevans Could we get this merged?  This repo hasn't been touched since May 2016 and it would be nice to get some of these fixes out.

lolz, just submitted this myself same PR today: https://github.com/nevans/resque-pool/pull/169
ping @nevans

sorry for enormous stall. I merged #165 instead.


DLL error on OSX and PostgreSQL

Trying out the diesel_demo on an OSX 10.11.4 laptop running postgresql.
Everything works up to the migration:
$ diesel migration run
thread '<main>' panicked at 'Error creating timestamp helper functions for Pg: DatabaseError("ERROR:  could not load library \"/usr/local/lib/postgresql/plpgsql.so\": dlopen(/usr/local/lib/postgresql/plpgsql.so, 10): Symbol not found: _DatumIsReadWriteExpandedObject\n  Referenced from: /usr/local/lib/postgresql/plpgsql.so\n  Expected in: /usr/local/opt/postgresql/bin/postgres\n in /usr/local/lib/postgresql/plpgsql.so\n")', ../src/libcore/result.rs:785
note: Run with `RUST_BACKTRACE=1` for a backtrace.
$ otool -l `which diesel` | grep libpq
 name /usr/local/opt/postgresql/lib/libpq.5.dylib (offset 24)

As you can see diesel is linked to libpq.5.dylib but is looking for plpgsql.so (which would make sense on linux but not osx).  I can only assume somewhere the path is hardcoded for a linux install.

Things were configured wrong on my side - fixed.

For anyone running into this in the future, this is caused by having postgres 9.5 installed, but pointed at  a data directory for 9.4 (likely because you haven't run pg_upgrade yet)

@sgrif can you show me how to check what data directory postgres is pointing to?


RFC: Add support for database read replicas

Introduction
In high traffic websites, being able to split read database traffic to a replica/slave (or a set of them) would help to speed up the overall website response time by ensuring that writes and reads are handled by the appropriate database servers.
SilverStripe's DBAL does already support the ability to have multiple connections open, but the ability to control read/write direction would (probably) be a small change to implement different connection types in various places.
Requirements

User defines read-only database connection environment variables, e.g. SS_DATABASE_READ_SERVER="my-read-replica.server" etc
SQLSelect runs the execute method on a read only connection name, if it exists
$connection argument would need to be passed through a little more than it is at the moment (to facilitate the above)
DB::query() calls are re-written to use SQL* classes (otherwise we cannot detect the appropriate connection to use, and the default will be used [write])
As above, rewrite Permission::permissions_for_member to use the DBAL
The connection detection in SQLSelect should both:

Be automatic, assuming read DB environment variables exist (other option is to look for a default_read connection)
Provide a public API to set the connection to use, in cases where you are, for example, running a high number of concurrent reads and writes and you do not want to want to lose consistency

I've run a very quick test on this idea. Mostly it works correctly, however recursive publishing (of pages) causes problems with primary key integrity constraint failures. This is probably due to a high I/O rate and loss of data consistency during replication (noted above).
It also highlights a few areas using DB::query() that can't be diverted to a slave unless rewritten (also noted above).
Other options

This could be implemented for the frontend only, leaving the admin area to use the master at all times (less likely to affect performance by doing this)
Public API or configuration options could be added to allow user code to, for example, set the connection name for certain operations

It's worth noting that @dhensby is considering options for a DBAL switch, and that both Illuminate and Doctrine support this already.
Also - it's pretty easy to test this with Docker.

Relevant links

Mailing list discussion - related

Wanted to comment an explicit +1 on this issue, being able to redirect reads to a dedicated read replica(s) would have a big benefits for some larger SilverStripe websites.
As part of the requirements I would also add:

ability to define an arbitrary number of database servers and mark them as supporting reads/writes/both.
sort database servers by priority, or give them weightings when determining which one to use for the query.
if a connection fails, attempt to use another applicable database server before bailing out.

From my tests when I raised this I think the issue was that writes would happen then start reading immediately from the read connection, and fail because the replication hadn't happened yet. If this gets implemented we'd need to ensure that writes would continue to use the read connection for the remainder of the request lifetime, which should prevent that issue from happening. cc @ScopeyNZ


docs: how to sign the CLA

fixed in https://github.com/KusionStack/kusionstack.io/commit/0087a481975d7845ebb9bb857bacf92725391127


add your logo in design/sketch section

Create a folder of yours in the design/sketch section and add your logo/name_logo in that folder.

@shubhajeet1207 please assign me this issue !

@spyMonk12 it is open for everybody, you don't need to claim this issue. Just go ahead and work on it.


[CT-504] Intermittent test failure in 'selected_resource' test.

Pull request #5001 added a selected resource feature for the context and a test. We are seeing intermittent failures with the error message:

16:08:01  Completed with 2 errors and 0 warnings:
16:08:01
16:08:01  Compilation Error in model model2 (models/model2.sql)
16:08:01    dbt was unable to infer all dependencies for the model "model2".
16:08:01    This typically happens when ref() is placed within a conditional block.
16:08:01
16:08:01    To fix this, add the following hint to the top of the model "model2":
16:08:01
16:08:01    -- depends_on: {{ ref('model1') }}
16:08:01
16:08:01    > in model model2 (models/model2.sql)
16:08:01    > called by model model2 (models/model2.sql)
16:08:01
16:08:01  Compilation Error in snapshot cc_all_snapshot (snapshots/my_snapshot.sql)
16:08:01    dbt was unable to infer all dependencies for the model "cc_all_snapshot".
16:08:01    This typically happens when ref() is placed within a conditional block.
16:08:01
16:08:01    To fix this, add the following hint to the top of the model "cc_all_snapshot":
16:08:01
16:08:01    -- depends_on: {{ ref('model2') }}
16:08:01
16:08:01    > in snapshot cc_all_snapshot (snapshots/my_snapshot.sql)
16:08:01    > called by snapshot cc_all_snapshot (snapshots/my_snapshot.sql)

Also having a whole separate file for it in core/dbt/selected_resource.py is kind of overkill. It should be in some other file. In addition we should try hard to implement it in a way that doesn't use a global file variable, because they are a bad idea in general (despite the fact that we have a number of them) and they all need to be reset for tests to run properly (and quite possibly any persistent server code).

@gshank This came up in BLG today.  We're going to point this with an AC of "make the intermittent errors stop" but not to avoid globals or change the code to live in another place.  If you still feel strongly about those issues could you please open new tickets for them?

Let's create a ticket for the refactor and then when the time comes we can weigh the refactor vs fixing the test

@gshank could you close this out and open a new ticket with the work to make this not global anymore


error handling in OnNodeAdded

PR #196 added code in OnNodeAdded which merely logs warnings when things go wrong (https://github.com/intel/pmem-CSI/pull/196#discussion_r298898414).
We need to expose those failures as errors that are more visible to the cluster admin, ideally such that our current "is PMEM-CSI healthy" checks detect the issue, and PMEM-CSI needs to recover from those errors automatically.

One possible solution would be to let OnNodeAdded return an error. That could be returned to the node which wanted to add itself, and then the retry loop there will ensure that a) the problem is visible (because the node does not become ready) and b) the problem eventually fixes itself.
Whether OnNodeAdded then gets called before or after making data structure changes is to be determined.


Problem while goverder sync

govendor fetch -v +external
Then
govendor sync
Error: Remotes failed for:
Failed for "github.com/go-openapi/jsonpointer" (failed to get ignore files): open /Users/nileshsalpe/projects/gocode/.cache/govendor/github.com/go-openapi/runtime/vendor/github.com/go-openapi/jsonpointer: no such file or directory
Failed for "github.com/go-openapi/spec" (failed to get ignore files): open /Users/nileshsalpe/projects/gocode/.cache/govendor/github.com/go-openapi/runtime/vendor/github.com/go-openapi/spec: no such file or directory
Failed for "gopkg.in/mgo.v2/bson" (failed to get ignore files): open /Users/nileshsalpe/projects/gocode/.cache/govendor/github.com/go-openapi/runtime/vendor/gopkg.in/mgo.v2/bson: no such file or directory
Failed for "gopkg.in/mgo.v2/internal/json" (failed to get ignore files): open /Users/nileshsalpe/projects/gocode/.cache/govendor/github.com/go-openapi/runtime/vendor/gopkg.in/mgo.v2/internal/json: no such file or directory
All are present in $GOPATH

I have delete $GOPATH/. cache folder and tried to fetch again
Fetch should get from remote and update my vendor.json

+external means libraries you have in your GOPATH but not in your vendor folder.  Are you trying to fetch (update from remote) the libraries you have vendored (use +vendor)?  Or that you have vendored but aren't yet in your vendor folder (use +missing)?

I am also getting
govendor status
The following packages are missing or modified locally:
github.com/go-openapi/spec
gopkg.in/mgo.v2/bson
gopkg.in/mgo.v2/internal/json
but they are present in $GOPATH


[Usage]: Mutiple-GPU usage with Fastapi and uvicorn not working

I am facing an error when attempting to utilize multiple GPUs with a FastAPI backend. The error arises during the integration of the multiple GPU code into the FastAPI backend API. Interestingly, the same code functions correctly when executed independently for multiple GPUs. I am simply loading model after loading libraries.
LLM(model=model, max_model_len=16000, tensor_parallel_size=4)
TypeError: cannot pickle '_thread.lock' object
Error Traceback
    self.llm = LLM(model=model, max_model_len=16000, tensor_parallel_size=4)
  File "/usr/local/lib/python3.8/dist-packages/vllm/entrypoints/llm.py", line 109, in __init__
    self.llm_engine = LLMEngine.from_engine_args(engine_args)
  File "/usr/local/lib/python3.8/dist-packages/vllm/engine/llm_engine.py", line 391, in from_engine_args
    engine = cls(*engine_configs,
  File "/usr/local/lib/python3.8/dist-packages/vllm/engine/llm_engine.py", line 126, in __init__
    self._init_workers_ray(placement_group)
  File "/usr/local/lib/python3.8/dist-packages/vllm/engine/llm_engine.py", line 304, in _init_workers_ray
    self._run_workers("init_model",
  File "/usr/local/lib/python3.8/dist-packages/vllm/engine/llm_engine.py", line 1041, in _run_workers
    driver_worker_output = getattr(self.driver_worker,
  File "/usr/local/lib/python3.8/dist-packages/vllm/worker/worker.py", line 94, in init_model
    init_distributed_environment(self.parallel_config, self.rank,
  File "/usr/local/lib/python3.8/dist-packages/vllm/worker/worker.py", line 275, in init_distributed_environment
    cupy_utils.init_process_group(
  File "/usr/local/lib/python3.8/dist-packages/vllm/model_executor/parallel_utils/cupy_utils.py", line 90, in init_process_group
    _NCCL_BACKEND = NCCLBackendWithBFloat16(world_size, rank, host, port)
  File "/usr/local/lib/python3.8/dist-packages/cupyx/distributed/_nccl_comm.py", line 70, in __init__
    self._init_with_tcp_store(n_devices, rank, host, port)
  File "/usr/local/lib/python3.8/dist-packages/cupyx/distributed/_nccl_comm.py", line 88, in _init_with_tcp_store
    self._store.run(host, port)
  File "/usr/local/lib/python3.8/dist-packages/cupyx/distributed/_store.py", line 100, in run
    p.start()
  File "/usr/lib/python3.8/multiprocessing/process.py", line 121, in start
    self._popen = self._Popen(self)
  File "/usr/lib/python3.8/multiprocessing/context.py", line 224, in _Popen
    return _default_context.get_context().Process._Popen(process_obj)
  File "/usr/lib/python3.8/multiprocessing/context.py", line 284, in _Popen
    return Popen(process_obj)
  File "/usr/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 32, in __init__
    super().__init__(process_obj)
  File "/usr/lib/python3.8/multiprocessing/popen_fork.py", line 19, in __init__
    self._launch(process_obj)
  File "/usr/lib/python3.8/multiprocessing/popen_spawn_posix.py", line 47, in _launch
    reduction.dump(process_obj, fp)
  File "/usr/lib/python3.8/multiprocessing/reduction.py", line 60, in dump
    ForkingPickler(file, protocol).dump(obj)
TypeError: cannot pickle '_thread.lock' object

How would you like to use vllm
No response

This is a bug of cupy, and we plan to remove cupy dependency with https://github.com/vllm-project/vllm/pull/3442 . Please stay tuned, or you can have a try using docker image built during CI of that PR, e.g. docker pull us-central1-docker.pkg.dev/vllm-405802/vllm-ci-test-repo/vllm-test:a3c2340ae36ce8ee782691d30111377eaf7ae6ce .
Feedback is welcome!

@youkaichao Thanks. I will also give it a try as well.
I was having an issue with fastapi and uvicorn command. I have no idea what is relation of --reload flag with cupy but that was causing the issue
I was using the following command:
 uvicorn api.main:app --reload --port 8080 --host <IP_ADDRESS>

But it was causing the issue. I removed --reload flag and now error is fixed. Working command is:
uvicorn api.main:app --port 8080 --host <IP_ADDRESS>

Glad you figured it out. And do have a try on our new docker image and give feedback!


Convert codebase to JavaScript

Admittedly, most of the reason I don't come back to maintaining this project is that I started it in CoffeeScript in a time before I knew JavaScript well. If it was in JavaScript I'd probably tackle cleaning up the more pesky bits of this code base. Instead, I've been focused on other projects.
It would be super cool to have the code base be modernized.

You can just transpile the coffeescript to javascript - manually with the coffee compiler or with some online tool


Add take screenshots option

Configurations in MonkeyConfig:

TakeScreenshots: Take screenshots each step if true
ScreenshotsDirectory: Directory path to save screenshots. Default save path is Application.persistentDataPath + "/TestHelper.Monkey/Screenshots/".
ScreenshotsFilenamePrefix: Prefix of screenshots filename. Default prefix is CurrentTest.Name when run in test-framework context. Using caller method name when run in runtime context.

works on my machine...


Documentation Tip: Search Structurally @Provides

Hello, thanks for dagger, which is great.
A co-worker of mine who was unfamiliar with it was confused all the time from where those @Inject fields come from.
To make his life easier, here is a structural search pattern that people can use, it's quite useful

Action Search Structurally (or Edit > Find > Search Structurally)
Enter the following template
class $Class$ {
  @Provides( )
  $MethodType$ $MethodName$($ParameterType$ $ParameterName$);
}

In Edit variables, edit $MethodName$ like this

Also edit $ParameterName$

Now when you serach Search Structurally, you get

Save it as template named Dagger @Provides so you can use it next time from (Copy from existing template)
Hope that helps!

This is amazing!
We actually have an IntelliJ plugin which is supposed to provide this functionality as well: https://github.com/square/dagger-intellij-plugin. Sadly it's fallen a bit out of favor with regard to upkeep, but we have plans to revive it and restore it to its former glory.


TypeError: htmlMode.startState is not a function

With this Code:
  <script>

   var editor = CodeMirror.fromTextArea(document.getElementById("code"), {
     lineNumbers: true,
     extraKeys: {"Ctrl-Space": "autocomplete"},
     mode: "text/html"
   });

 </script>

i get in firefox this error message
TypeError: htmlMode.startState is not a function
but why ?:D I include all needed Javascripts.
Thanks Fabian

Did you include the XML, JavaScript, and CSS modes? These are dependencies of the htmlmixed mode.

yes😊

Well, it works in the demo, so compare your setup with the situation in the demo to figure out what is going wrong.
Closing, but feel free to add comments or reopen if you've isolated an actual bug.

i try use the php mode  and have this error
php.js:163 Uncaught TypeError: htmlMode.indent is not a function  ....
any idea?

@marijnh hi! Can you please fix wrong regex:
http://codemirror.net/mode/htmlmixed/
Wrong:
/^text/(x-)?scss$/
Correct:
/^text\/(x-)?scss$/

Thanks!

i try use the php mode and have this error
php.js:163 Uncaught TypeError: htmlMode.indent is not a function ....
any idea?

+1

Could you post an example setup that has this issue?

@TeaWeb & @CharlyJazz
Look @ this example https://github.com/codemirror/CodeMirror/blob/master/demo/html5complete.html
htmlmixed seems to rely on other needed addons ;)


train_moco_dev.py

Hi,
thank you for your hard work.
I can't find the file "train_moco_dev.py" that is called in the scripts.
Best

maybe this will help
https://bit.ly/3XQLHlH
you may need to install the c compiler


RFC BibClassify in Invenio 2

BibClassify is an Invenio legacy module that given some publication metadata (e.g. title and abstract) or directly a PDF, tries to extract the keywords of the document (matching a given static taxonomy). The current implementation is purely statistical. The keywords are typically used, e.g. in the context of INSPIRE, to aid catalogers understanding core documents from non core one.
Today, we have the chance to reimplement this module in terms of machine learning.
@glouppe

Just my five cents:
I'm thinking there ought to be existing tools out there which we can used nowadays, and thus this module can be simplified to only dealing with the interface between Invenio and those tools?
Also, I see this module could be useful many different places in Invenio. E.g. in deposit it could be used to extract metadata.
Other properties besides keywords that could be very interesting to extract (just as use cases for the module):

Language
Copyright
License
Metadata (title, authors, ...)
Grants
Subject

Also, the ML tools can be both local/remote. E.g. OpenAIRE has a service to extract grant information from text.

I agree that we should use/improve/contribute to existing machine learning libraries instead of writing our own.
That being said, it would be worth defining the scope of "bibclassify". From a machine learning point of view, extracting representative keywords is a quite different task from parsing metadata (== docextract?), which is itself quite different from guessing the subject of paper given metadata.
In any case, all are nice machine learning problems that I would be glad to tackle, depending on our list of priorities.

From a machine learning point of view, extracting representative keywords is a quite different task from parsing metadata (== docextract?),

Sure. bibclassify is not about metadata extraction, but possibly about using available metadata (such as title and abstract which are very verbose) to be used instead of the PDF source.

Yeah I agree we should focus on bibclassify main task of extracting keywords.  Perhaps a RFC for an extractor could be good !
The main problem with the current bibclassify is that it needs a thesaurus. The main consequence is the complexity of getting it working on general purpose repository or with a repository hosting documents in different languages.
It would then be cool if the new bibclassify could work in a way where it could "learn" to recognize keywords. Ideally in a multilingual environment.
If bibclassify could have like a global view of a repository it would be a big plus. For example if I have two universities in medical area,  it would be efficient to determine most used keywords to try to define their main field of competencies.
It would be awesome !

The main problem with the current bibclassify is that it needs a thesaurus.

Perhaps we could support a simple "controlled vocabulary", but in practice I think this would probably quickly lead to working with full-scale ontologies.  Soon after starting with a controlled vocabulary, people would probabyl ask "How do I define a synonym for my controlled vocabulary term?" or "How do I defined an alternative term for this expression?".  Perhaps we could just facilitate initial ontology building, e.g. offer populating it from the list of frequent keywords that papers already have.  Just an example.

If bibclassify could have like a global view of a repository it would be a big plus. For example if I have two universities in medical area, it would be efficient to determine most used keywords to try to define their main field of competencies.

Considering that the system contains papers published by the researchers of these two universities, and considering that each paper has a list of keywords, then asking for the field of competency of each university is just another "search summary page", like the author pages.  So the "global view of the repository" use case is just an extension of search, as it were, simply building upon the powers of BibClassify, that should properly populate the papers' keywords with proper terms in the first place.

Perhaps we could support a simple "controlled vocabulary", but in practice I think this would probably quickly lead to working with full-scale ontologies. Soon after starting with a controlled vocabulary, people would probabyl ask "How do I define a synonym for my controlled vocabulary term?" or "How do I defined an alternative term for this expression?". Perhaps we could just facilitate initial ontology building, e.g. offer populating it from the list of frequent keywords that papers already have. Just an example.

It could be a solution, but I still imagine a perfect world were, the basic ontology could be generated automatically, and then involve people to complete or guide it, then let the code improve it continuously in a supervised learning fashion.

Considering that the system contains papers published by the researchers of these two universities, and considering that each paper has a list of keywords, then asking for the field of competency of each university is just another "search summary page", like the author pages. So the "global view of the repository" use case is just an extension of search, as it were, simply building upon the powers of BibClassify, that should properly populate the papers' keywords with proper terms in the first place.

Perfect :+1:

Superseded by Invenio 3.  https://github.com/inveniosoftware/invenio-classifier


feature: Evaluate & introduce if a new scheme is required for CCA

Need to check whether CCA Needs a new Scheme ?
If required, this issue tracks introducing one!

Is this a duplicate of https://github.com/veraison/services/issues/54 and https://github.com/veraison/services/issues/53?

The changes for introducing new scheme will be handled vi #54
Closing this issue.


[Example] ggml: add gemma support

Hello, I am a code review bot on flows.network.
It could take a few minutes for me to analyze this PR. Relax, grab a cup of coffee and check back later. Thanks!


Set up caching PyPI deps in GHA

Ref https://github.com/jazzband/pip-tools/issues/1375#issuecomment-813212856
Changelog-friendly one-liner: Made GHA workflows faster by enabling pip cache
Contributor checklist

[ ] Provided the tests for the changes.
[x] Gave a clear one-line description in the PR (that the maintainers can add to CHANGELOG.md on release).
[ ] Assign the PR to an existing or new milestone for the target version (following Semantic Versioning).

@webknjaz It would be great to follow patterns that we've established in other Jazzband repos, e.g. the pip cache dir should not be hardcoded here. Instead use pip cache dir to get it, like in contextlib2. Thank you!

@jezdez got it, thanks for the feedback!

@jezdez got it, thanks for the feedback!
I think I copied this from one of my projects where pip cache dir is not a thing because it's old so I didn't bother overcomplicating it there. But I see the value of having it identified dynamically.

Gotcha, we switched to that CLI call only a bit ago when pip gained this subcommand, so no worries!

https://github.com/jazzband/pip-tools/pull/1389

pip can now be cached via actions/setup-python to save a lot of config:
https://github.com/actions/setup-python#caching-packages-dependencies
Please see https://github.com/jazzband/pip-tools/pull/1571 for an alternative.


:bomb: release 1.3.3

Great!
Please visit https://github.com/tinkoff-ai/etna/releases/edit/1.3.3 to describe release notes!
Also you can find publishing task here https://github.com/tinkoff-ai/etna/actions/workflows/publish.yml

Codecov Report

Merging #312 (60672a6) into master (0ec3638) will decrease coverage by 33.12%.
The diff coverage is n/a.

@@             Coverage Diff             @@
##           master     #312       +/-   ##
===========================================
- Coverage   87.75%   54.63%   -33.13%
===========================================
  Files          96       96
  Lines        4737     4737
===========================================
- Hits         4157     2588     -1569
- Misses        580     2149     +1569

Impacted Files
Coverage Δ

etna/commands/__init__.py
0.00% <0.00%> (-100.00%)
:arrow_down:

etna/commands/backtest_command.py
0.00% <0.00%> (-96.43%)
:arrow_down:

etna/commands/forecast_command.py
0.00% <0.00%> (-92.00%)
:arrow_down:

etna/commands/__main__.py
0.00% <0.00%> (-87.50%)
:arrow_down:

etna/commands/resolvers.py
0.00% <0.00%> (-80.00%)
:arrow_down:

etna/analysis/outliers/density_outliers.py
22.72% <0.00%> (-75.00%)
:arrow_down:

etna/transforms/statistics.py
27.50% <0.00%> (-71.67%)
:arrow_down:

etna/transforms/filter.py
28.57% <0.00%> (-71.43%)
:arrow_down:

etna/analysis/outliers/median_outliers.py
25.00% <0.00%> (-70.84%)
:arrow_down:

etna/datasets/datasets_generation.py
26.47% <0.00%> (-70.59%)
:arrow_down:

... and 56 more

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 0ec3638...60672a6. Read the comment docs.

Failed semver 😢


Conditions for BackendPolicy

Currently, BackendPolicy only has ConditionNoSuchBackend defined. There are other ways a backendpolicy may be invalid though:

BackendRef is unknown/unsupported type
Certificate ref is unknown/unsupported type, or does not exist

One other issue is that, unlike routes and gateways which all point back to a single controller eventually (via class), there is no controller association with BackendPolicy. How do we manage multiple controllers and BackendPolicy?

Agree that these would be good conditions to add. Unfortunately the unknown/unsupported type conditions are going to be implementation specific (one implementation may support a type of backend that another does not). BackendPolicy is certainly one of our least refined resources at this point, and status is rather difficult to solve.
The way we've currently defined it, BackendPolicy refers to backends. Controllers would check to see if a BackendPolicy applied to a backend they were processing, and the config in a BackendPolicy was intended to be entirely portable. When we added status here, the initial solution was for implementation-specific messages to be added on the Route or Gateway level.
Unfortunately, there are a lot of different ways we could group these conditions, by backend, route, gateway, controller, or implementation. I think the best option might be to group conditions by GatewayClass. If an implementation is using a BackendPolicy for a given class, it would add conditions to status. This feels quite relevant to https://github.com/kubernetes-sigs/gateway-api/issues/591.

@robscott Do you think reference policy needs these enhancement or should status conditions be part of the specific reference policies?
In my view, some common ground would be helpful.

Thanks for following up on this @hbagdi! I've created #738 to track the equivalent of this going forward, and I think we can safely close this one now. Feel free to reopen if not.
/close


feat: can use scenarioWidgetBuilder when snapshot

Overview
Snapshot now has a Builder for scenario
Problem
PlaybookGallery has scenarioWidgetBuilder but Snapshot does not
If you want to give a specific change to a Snapshot, there is no way to do so.
Solution
We have added the ability to specify scenarioWidgetBuilder in Snapshot.

LGTM


Unable to log-in after dump and restore

Gitea version (or commit ref): Going from <unknown, didn't check> to v1.14.1 on TrueNAS
Git version: 2.31.1
Operating system: TrueNAS Community Plugin on TrueNAS 12.0 U4
Database (use [x]):

[x] PostgreSQL
[ ] MySQL
[ ] MSSQL
[ ] SQLite

Can you reproduce the bug at https://try.gitea.io:

[ ] Yes (provide example URL)
[x] No

Log gist:

Description
Hi Gitea team.
I was running the Gitea Community plugin within TrueNAS.  I didn't check versions prior to reinstall.  I used the dump command, as per https://docs.gitea.io/en-us/backup-and-restore/, to create a backup of the installation.
I installed a clean TrueNAS-12.0-U4, and installed a clean Gitea plugin.  I tried multiple methods, from first configuring Gitea and then restoring, to after install stopping the service and immediately restoring. I had significant problems restoring the dump.  With the PostgreSQL restore flooding the terminal, it was hard to see any errors.  Even setting ON_ERROR_STOP, didn't show errors.  After everything (app.ini, Data, Logs, Repos and Database) was moved to correct locations, I could not log in.
Inspecting the DB didn't show any users.  I opened the SQL backup and tried to manually run the INSERT to add the user.  This failed with:
ERROR: null value in column "keep_activity_private" violates not-null constraint
Query with details removed:
INSERT INTO "user" ("id", "lower_name", "name", "full_name", "email", "keep_email_private", "email_notifications_preference", "passwd", "passwd_hash_algo", "must_change_password", "login_type", "login_source", "login_name", "type", "location", "website", "rands", "salt", "language", "description", "created_unix", "updated_unix", "last_login_unix", "last_repo_visibility", "max_repo_creation", "is_active", "is_admin", "is_restricted", "allow_git_hook", "allow_import_local", "allow_create_organization", "prohibit_login", "avatar", "avatar_email", "use_custom_avatar", "num_followers", "num_following", "num_stars", "num_repos", "num_teams", "num_members", "visibility", "repo_admin_change_team_access", "diff_view_style", "theme", "keep_activity_private") VALUES (5,'test','test','','',false,'','','',false,0,0,'',1,'','','jmE8n9yvnY','BHCtCK1XQc','','',1602655076,1614569971,0,false,-1,true,false,false,false,false,false,false,'3','',true,0,0,0,17,1,1,0,true,'','',NULL);
Changing the final NULL value to false succeeded the insert.
I believe there is therefor an issue with the DUMP command, and the specific 'user' table and 'keep_activity_private' column. Either the schema changed somewhere along the line, and the NULL values was inserted when the column was inserted, or the dump function is incorrectly storing the value.

Following the restore, and fixing the SQL script, the stored SSH key didn't work.  Removing the key from the Web UI and re-adding it, fixed it.

After restored, you should run both Resynchronize pre-receive, update and post-receive hooks of all repositories. and Regenerate ssh keys if you are using openssh. Because the location is changed.

Regarding the SSH keys.  Sure.
Regarding hooks.  I did run the following sequence:
su git
gitea admin regenerate hook --c /usr/local/etc/gitea/conf/app.ini.
It ran successfully, but I was still unable to log on.  I had to specify the config path, as it looks like the plugin uses non default paths.  The problem is that the users, inserted by the first segment of the SQL database script, are not in the DB, resulting in failing login attempts.

For reference, Gitea was both prior to the TrueNAS install and afterwards, installed using the community plugin.  All, even my mounted data directories had exactly the same structure.

On the new installation, I made another dump.  This time, the entries did contain false/true values instead of null.  Might I suggest looking at the SQL database deployment script, and adding a default value of false to the column?

Dumps prior to 1.14 don't include a copy of the version table. So on startup migrations are not run.
We need to know what version you originally dumped from in order to tell you what that version table should be so that prior to running gitea you can set it properly and get the dB migrations to run.

Like I stated in the original post, I didn't check the version prior to migrating, as didn't expect an issue will arise.  I am unable to check the previous version, as the machine is completely wiped.  As the version is not in the dumps, it is now lost.
The best I can do is narrow it down to: the installation of the Gitea server was less than a year old.
You can close this issue if you feel this is not going anywhere.
I managed to recover the DB by changing the NULL values in the SQL script inside of the dump to FALSE and all is working fine now.
My suspicion is that at some point, "keep_activity_private" was added as an additional column in the database (Postgres in this instance) during a version upgrade of Gitea, but without a default value in the SQL upgrade script, NULL values gets populated, instead of a TRUE/FALSE.  From the version history of the SQL deployment script, you should be able to see when the column was introduced, whether it has a default value for upgrades and whether it now has a default value.

It is probably possible to work out what version of Gitea it was from the schema. Especially if you can give us some sort of date of when it was installed. Almost all gitea versions have some sort of change of the schema so by looking at what the changes were between versions you should be able to work it out.


.osx: chmod error

Just got this when running my .osx file, wondering if anyone else has had this?
chmod: Unable to change file mode on /System/Library/CoreServices/Search.bundle/Contents/MacOS/Search: Operation not permitted

Is that in relation to this line (i.e. did you uncomment this)?
https://github.com/mathiasbynens/dotfiles/blob/e7ef66da4f6a077261286df3729d823a1d39e04b/.osx#L516-L517

Cheers @mathiasbynens looks like I have some updates to make!


Gradle 2.14.1

Gradle 2.14.1 is available now.
This pull request updates Gradle Wrapper files in the repository.
This pull request is created by Gradle Update.

Outdated


projects:ad355xr_iio: Release AD355XR IIO application

Release AD355XR IIO application.
Update mbedignore to add entry for ad355xr_iio

Hi all, Is there any comments on this PR?


Revert "Fixed issue where ConfigNode might recover incorrectly under SimpleConsensus"

Reverts apache/iotdb#11969

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (a544517) 49.22% compared to head (3cde922) 49.22%.

Additional details and impacted files
@@            Coverage Diff            @@
##             master   #11987   +/-   ##
=========================================
  Coverage     49.22%   49.22%
+ Complexity    26078    26074    -4
=========================================
  Files          2931     2931
  Lines        183563   183553   -10
  Branches      22014    22014
=========================================
+ Hits          90353    90356    +3
+ Misses        93210    93197   -13

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


Interactive Graph not appearing when baseURL = "/"

Describe the bug
The Interactive Graph does not appear when baseURL = "/" (see config below, and additional context at the bottom for my initial reasoning why).
To Reproduce
Steps to reproduce the behavior:

Set up the default quartz repo (default pages) with your config.toml as

baseURL = "/"
relativeURLs = true
disablePathToLower = false

Run hugo-obsidian and hugo, then check any page to see interactive graph not working (but everything else works)

Expected behavior
Interactive graph should appear and function along with everything else.
Screenshots

Desktop (please complete the following information):

Device: MacBook Pro 2021 16
OS: MacOS Monterey
Browser Chrome

Additional Context
I've traced this to at least partially differences in the baseURL being prepended to some content being loaded such as the main note index.html file, but not to others.
This main call looks correct, and loads the note CJK + Latex Support (测试):

ryanwwest.com/notes/CJK-+-Latex-Support-测试
/ryanwwest.com/js/full-text-search.e6e2e0c213187ca0c703d6e2c7a77fcd.min.js
(several other files also load correctly , e.g. CSS styling looks good)

These GET calls fail with a 404 (I think because they don't have ryanwwest.com prepended):

/etc/nginx/html/styles/_dark_syntax.bec558461529f0dd343a0b008c343934.min.css
/styles/_dark_syntax.bec558461529f0dd343a0b008c343934.min.css
/indices/linkIndex.24b3c529ddef2b7a2be051f2a730940a.min.json
/indices/contentIndex.2474ab0c4aa95bedcaffe8ea20dbf3b0.min.json
/js/router.9d4974281069e9ebb189f642ae1e3ca2.min.js

(mostly unchanged) repo: https://github.com/ryanwwest/quartz/commit/c664f850f2e0d67533b9152e4e7b41afe25a8201

This issue should be fixed in Quartz 4. I'll be closing it for now but please reopen this issue if this persists in the new version.


Use Arbitrary Counter as Timeline

I want to be able to use a counter (that represents an arbitrary thing, not just dates) as the basis for events. For example,
5-20: Event 1
90-150: Event 2
45-68: Event 3
etc.
When I tried this in the live example, it treated it like a percentage and only went up to 100.
It won't let me zoom out any more

Thank you for your thoughtful and considered response.

I can see how this could be useful, but it's not really the direction I'm going with markwhen at the moment.

Fair enough. I understand.

You should have been able to scroll more to the right.

Yes, I can scroll to the right now. I didn't think to do that. Thanks.
It would be nice to zoom out and see all the events in one screen. Perhaps put it on the backlog as a feature request?
The use case I had in mind is one where events from multiple parallel threads are being described in an embedded system where they take milliseconds to complete in a certain sequence. Sort of like a sequence diagram.
Incidentally, when I used ms as units, everything collapsed to a single dot.
If the X-axis was treated merely as a number (not a date), then I think all this would work.
Anyway, thanks for making this awesome tool. I will close this issue.

at least until there is a "relative" mode

Yes! This is exactly what I was trying to articulate, albeit, inelegantly.
Units don't matter. I just want to illustrate  events occuring relative to one another.


shield bug

What version of ViaVersion are you using? Type /ver viaversion
What version of Spigot are you using? Type /ver
What plugins are you using? Type /plugins
Are you using any additional software like BungeeCord? If so, what software and version? (Please list your plugins as well)
How does this error happen? login? Using an item?
Is there an error in the console? Use pastebin.com. Is there a kick message?

Version of ViaVersion: 0.6.3
Version of spigot: 1.8.8
I'm using bungeecord
I was playing in my 1.8.8 survival world with ViaVersion and I (1.9 client) saw another guy with a shield in his second hand (1.8 client).
Could this be a bug in your plugin or not?
I'm not sure if it is caused  by your plugin but I report it so you can look at it :)
There are also no errors in the console.

This is not a bug, this is a feature. This way 1.9 players can tell if 1.8 players are blocking.


[Feature] Graphing Calculator

Description
Equipped with a graphical display, these calculators are commonly used in mathematics and science for graphing functions and equations.
Screenshots

Checklist

[X] I have checked the existing issues.
[X] I follow Contributing Guidelines of this project.
[X] I am a IWOC'24 contributor.
[ ] I am a JWOC'24 contributor.
[ ] I am a SWOC'24 contributor.

Code of Conduct

[X] I agree to follow this project's "Code of Conduct".

Go ahead @AbhineshJha


Renamed classes

I'm creating a profile in describo to drive the UI from schema.org. In that process I rename all instances of MediaObject to File so the user can't add / associate a type of MediaObject; rather, they only get the option to add / associate a File. However, the RO-crate context has an entry for File and MediaObject.
So:

should I actually add File as an option to any location a user can use MediaObject (ie they could choose to add a File or a MediaObject)?
or
should the crate context only list File?

I guess this holds true for other examples that have been renamed but I haven't come across any myself.

I think we only keep MediaObject because it is in the original context - it's not deleted.
https://github.com/ResearchObject/ro-crate/blob/master/docs/1.1/context.jsonld#L603
Perhaps it should be deleted? This could also help JSON-LD flattening so it does not accidentally pick the other one, and our spec do say it is renamed.
The renames from PCDM are only there in the renamed variant:
          "RepositoryCollection": "http://pcdm.org/models#Collection",
          "RepositoryObject": "http://pcdm.org/models#object",

In addition Journal is renamed from Periodical, but it is also there natively:
          "Journal": "http://schema.org/Periodical",
          "Periodical": "http://schema.org/Periodical",

My code is renaming classes so MediaObject cannot be added via describo but File can. That said, when flattening it could come out as either as you rightly point out.
You mention Journal being renamed. I didn't know that. Is there an authoritative list of these renames in the documentation that I can consult?


Can't create a Many to Many Relationship

Laravel Version: 5.5
Voyager Version: 1.0
PHP Version: 7.1
Database Driver & Version:
Mysql 5.7.19

Description:
Can't establish a Many to Many relationship using the interface.
Steps To Reproduce:

Create the tables with the model option set to YES.
Create the breads.
When I go and try to create a BELONGS TO MANY relationship, I get:

"Model Class does not exist. Please create model, before creating the relationship."
What am I missing?
I can setup the schema and the models on a Many to Many relationship.
Would that help?
Will Voyager know about this database and model setup? Or do I still need to create the relationship in Voyager?
Thank you so much.

You can watch this video. You must create model manually.
https://www.youtube.com/watch?v=gnSJ0Z2Fmso

Brilliant! Thank you so much.
While I did had the Model created, I wasn't put in the namespace properly.
The video did should that I had to add App\ and that seems to work.
Now, when I click Browse Bread (to be able to add records) I get:
SQLSTATE[42S02]: Base table or view not found: 1146 Table
'uxkit.kit_elements' doesn't exist (SQL: select * from kit_elements order
by created_at desc)
Interesting, because, somehow, it seems to look for table 'kit_elements'
(with an s at the end), however, the table name is 'kit_element' (no s at
the end). I had a look into the code, here and there, and I don't find
where did I put that s.
Perhaps it's an easy and quick suspicion for you?
Of course, I reckon this is taking much of your time than what it should,
so it's ok, if you don't have the time to look specifically into my case.
Thank you, again, for your time.
Marcio
On Sat, Sep 23, 2017 at 6:54 PM, Evren Doğan<EMAIL_ADDRESS>wrote:

You can watch this video. You must create model manually.
https://www.youtube.com/watch?v=gnSJ0Z2Fmso
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/the-control-group/voyager/issues/1843#issuecomment-331658407,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AeWNEZ3pIY2S44CSxQp0Rbrbj5e3QyUxks5slUXWgaJpZM4Phn9m
.

I think I find it.
I'm fairly new to Laravel. And it seems to be a framework behaviour.
https://stackoverflow.com/questions/23943663/how-does-laravel-find-plural-of-models
Cheers,
Marcio
On Sat, Sep 23, 2017 at 11:54 PM, Marcio Machado <
<EMAIL_ADDRESS>wrote:

Brilliant! Thank you so much.
While I did had the Model created, I wasn't put in the namespace properly.
The video did should that I had to add App\ and that seems to work.
Now, when I click Browse Bread (to be able to add records) I get:
SQLSTATE[42S02]: Base table or view not found: 1146 Table
'uxkit.kit_elements' doesn't exist (SQL: select * from kit_elements order
by created_at desc)
Interesting, because, somehow, it seems to look for table 'kit_elements'
(with an s at the end), however, the table name is 'kit_element' (no s at
the end). I had a look into the code, here and there, and I don't find
where did I put that s.
Perhaps it's an easy and quick suspicion for you?
Of course, I reckon this is taking much of your time than what it should,
so it's ok, if you don't have the time to look specifically into my case.
Thank you, again, for your time.
Marcio
On Sat, Sep 23, 2017 at 6:54 PM, Evren Doğan<EMAIL_ADDRESS>wrote:

You can watch this video. You must create model manually.
https://www.youtube.com/watch?v=gnSJ0Z2Fmso
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/the-control-group/voyager/issues/1843#issuecomment-331658407,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AeWNEZ3pIY2S44CSxQp0Rbrbj5e3QyUxks5slUXWgaJpZM4Phn9m
.

Hm.
Now when I go to create, after the relationship is setup, I get the table name appearing twice...

...table or view not found: 1146 Table 'uxkit.kit_element_kit_element'

"kit_element" appears twice.

Found the issue.
Apparently, some name conventions should be in place.
You relationship table name should have a specific structure. And the same goes for their fields.
Would be nice to validate those, or, hint those somehow.
Cheers,
Marcio

@marcio-machado-k  you're welcome. :) You can change table name in your model file. Laravel can detect table name automatically but if you use laravel with other languages(not english), you must change it with hand.
``
<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

class Flight extends Model
{
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'my_special_table_name';
}
``

I couldn't (quickly) find the reference in the official docs, but I know it's there.  Instead I present to you this summary guide of laravel best practices.  I reference it all the time


Refinement and dense Matrix for element stiffness.

Closes #174  Closes #176

Codecov Report

Merging #177 (b775ae7) into main (09ea297) will decrease coverage by 0.10%.
The diff coverage is 100.00%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
@@            Coverage Diff             @@
##             main     #177      +/-   ##
==========================================
- Coverage   90.19%   90.10%   -0.10%
==========================================
  Files          40       40
  Lines        1061     1061
==========================================
- Hits          957      956       -1
- Misses        104      105       +1

Impacted Files
Coverage Δ

src/Elements/Tetrahedron.jl
100.00% <100.00%> (ø)

src/Materials/IsotropicLinearElastic.jl
100.00% <100.00%> (ø)

src/Materials/SVK.jl
100.00% <100.00%> (ø)

... and 1 file with indirect coverage changes
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Issue #162 - CODEOWENERS

This pull request updates the CODEOWNERS file to reflect the changes in GhostBSD GitHub Members levels.

Related to ghostbsd/issues#162


rosdep: adding python-parso-pip entry

Adds a rodep entry for Parso: A Python Parser.

This package has debs for Ubuntu Bionic and Debian Buster.
Can you please drop the -pip suffix from the key and update the rules to reflect it so that we can use the deb for these disctributions?
Thanks!

Okay, let's use pip for the last LTS.


Use tiddlywiki's sidebar breakpoint in streams/styles

At the moment streams uses fixed values in the styles tiddler:
@media only screen and (max-width: 600px)
It would be ideal to use the default sidebar breakpoint value stored in
$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint
for better compatibility and customization.

@postkevone interesting idea. The problem is of course that the config tiddler you mentioned is theme specific so wont work for someone with a heavily customized theme.
A more flexible option might be to introduce a new config tiddler to control the width used in that media query.

You are right, perhaps the best solution is to have a config tiddler inside streams itself