Allow for passing header text as text in plugin not only file

For multi module Maven project I would like to have possibility to configure in parent project plugin with licence text definition which can be inherited without relative path to licence file and be able to use this configuration from any subprojects. Now when I'm building subproject and configuration was in parent pom I'm getting error that licence file can't be found. Licence file path is relative (and can't be absolute) so execution from different places will not work.
Solution would be to add parameter by which we could pass license text like
my text line 1\nmy text line 2
It doesn't need to pass html tags through this parameter which probably would make it difficult.
Example setup:
--parent project (build works from here)
|--sub-project1 (build not works from here)
|--sub-project2 (build not works from here)
|--copyright.txt
pluing configuration on parent project pom
        <plugin>
            <groupId>com.mycila</groupId>
            <artifactId>license-maven-plugin</artifactId>
            <configuration>
                <licenseSets>
                    <licenseSet>
                        <header>copyright.txt</header>
                        <excludes>
                            <exclude>**/README</exclude>
                            <exclude>**/*.groovy</exclude>
                            <exclude>**/pom.xml</exclude>
                            <exclude>**/resources/**</exclude>
                            <exclude>**/.helmignore</exclude>
                            <exclude>**/*.yml</exclude>
                            <exclude>**/*.yaml</exclude>
                            <exclude>**/*.json</exclude>
                            <exclude>**/*.tpl</exclude>
                        </excludes>
                    </licenseSet>
                </licenseSets>
            </configuration>
            <executions>
                <execution>
                    <goals>
                        <goal>check</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>

You already can. You can use the aggregate option to true and inherited maven option of the plugin to false.

you can even use inlineHeader option.


temp: test dns fix

Pull Request Test Coverage Report for Build<PHONE_NUMBER>0
Details

0 of 0   changed or added relevant lines in 0 files are covered.
49 unchanged lines in 15 files lost coverage.
Overall coverage increased (+0.006%) to 58.928%

Files with Coverage Reduction
New Missed Lines
%

sweep/fee_bumper.go
1
92.2%

lnwallet/test/test_interface.go
1
78.65%

queue/gc_queue.go
2
96.51%

htlcswitch/mailbox.go
2
93.55%

contractcourt/htlc_timeout_resolver.go
2
89.27%

htlcswitch/switch.go
2
83.32%

discovery/syncer.go
2
86.0%

discovery/sync_manager.go
2
91.3%

lnrpc/websocket_proxy.go
2
76.87%

watchtower/wtdb/range_index.go
3
96.12%

Totals

Change from base Build<PHONE_NUMBER>3:
0.006%

Covered Lines:
133421

Relevant Lines:
226413

💛  - Coveralls


Error when using a single TabScreen: Bad output range

Current behaviour
When there is only one TabScreen, this error is thrown: Bad output range
Expected behaviour
When there is only one TabScreen, only this one page is to be shown
How to reproduce?
https://snack.expo.dev/@edcaron/react-native-paper-tabs-single-page
Preview

What have you tried so far?
adding one more page works
Your Environment

software
version

android
10

react-native
0.71.8

react-native-paper
5.9.1

node
x.x.x

npm or yarn
x.x.x

expo sdk
<IP_ADDRESS>

Please provide a snack

@RichardLindhout
https://snack.expo.dev/@edcaron/react-native-paper-tabs-single-page
it was already on the issue description, on the 'How to reproduce?' section

Oops sorry, looking into it!

Fixed, thanks for your snack!


Linter for azure blueprints

I think this is just a quick question, but there is any way to validate azure blueprints?

This does not exist today unfortunately.


Duplicate Symbol resulting in link error

duplicate symbol OBJC_CLASS$_SQLiteResult in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLiteResult.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLiteResult.o)
duplicate symbol OBJC_METACLASS$_SQLiteResult in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLiteResult.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLiteResult.o)
duplicate symbol OBJC_IVAR$_SQLiteResult.status in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLiteResult.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLiteResult.o)
duplicate symbol OBJC_IVAR$_SQLiteResult.message in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLiteResult.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLiteResult.o)
duplicate symbol OBJC_IVAR$_SQLite.appDBPaths in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLite.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLite.o)
duplicate symbol OBJC_IVAR$_SQLite.openDBs in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLite.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLite.o)
duplicate symbol OBJC_CLASS$_SQLite in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLite.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLite.o)
duplicate symbol OBJC_METACLASS$_SQLite in:
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/react-native-sqlite-storage/libreact-native-sqlite-storage.a(SQLite.o)
/Users/michael/Library/Developer/Xcode/DerivedData/owlbrite-belmscpdkunkpqgwiuzibascgluk/Build/Products/Debug-iphonesimulator/libSQLite.a(SQLite.o)
ld: 8 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Trying to figure out how to fix this.. Can't build :(

I had run react-native link
This broke me. I ran react-native unlink react-native-sqlite-storage and then it compiled again


Question: Polymorphic Relationship Example

This package looks amazing, I haven't fully played with it too much but wanted to ask about polymorphic relationships.
Lets say I have Pages, Posts, and Comments. I want to make an API end point for comments that can pull the comments for a specific page or post with additional filters.
Is the recommended method to be similar to:
https://github.com/mohammad-fouladgar/eloquent-builder/issues/28#issuecomment-516116144
Where if I have two filters: polymorphic_type and polymorphic_key I should do something like this in my comments controller, or would there be a better way?
(Code may not actually work; just trying to figure out the best way to go about this)
//API\Comments.php
public function index(Request $request)
{
    $filters = $request->get('filters');
    if(isset($filters['polymorphic_type']) && isset($filters['polymorphic_key'])) {
        $polymorphic = (new $filters['polymorphic_type'])->findOrFail($filters['polymorphic_key');
        $comments = $polymorphic->comments()->getQuery();
    }else{
        $comments = Comment::class;
    }

    $result = EloquentBuilder::to(
                $comments,
                $request->all('filters')
    )->paginate(10);
    return response()->json($result);
}

Hi Dear @sniper7kills ,
I read your problem. it's solvable,.But, please let me to find a suitable solution.
Thanks.

Hi @sniper7kills ,
I'm sorry for delay.
You can make a filter as CommentableFilter to your comment model:
<?php

namespace App\EloquentBuilders\Comment;

use Fouladgar\EloquentBuilder\Support\Foundation\Contracts\Filter;
use Illuminate\Database\Eloquent\Builder;

class CommentableFilter extends Filter
{
    /**
     *  Apply Commentable filter to the query builder
     *
     * @param Builder $builder
     * @param mixed   $value
     *
     * @return Builder
     */
    public function apply(Builder $builder, $value): Builder
    {
       // You should control your logic in here
       // Simple usage:
        return $builder->where(function ($query) use($value) {
                $query->where('commentable_id', $value['key'])
                      ->where('commentable_key',$value['type']);
               });
    }
}

Next:
// Get: api/comments?filters[commentable][key]=1&filters[commentable][type]=post

$result = EloquentBuilder::to(Comment::class,$request->filters)
       ->with('commentable') // optional
       ->paginate();

    return response()->json($result);

I hope this answers your questions.

That is much cleaner than what I was thinking of doing!
Thanks so much for the reply!

Because I have multiple Many-To-Many polymorphic models I thought I'd share what I ended up doing for posterity.
This example is based off of Posts, Videos and Tags.
//type = what we want to get
//id = id of what we currently have

// Requesting Tags from Post/Video
// http://<IP_ADDRESS>/api/tags
$filters = ['polymorphic' => ['polymorphic_type' => 'Tag', 'polymorphic_id' => {POST_OR_VIDEO_ID}]];

// Requesting Posts from Tag
// http://<IP_ADDRESS>/api/posts
$filters = ['polymorphic' => ['polymorphic_type' => 'Post', 'polymorphic_id' => {TAG_ID}, 'polymorphic_inverse'=true]];

// Requesting Videos from Tag
// http://<IP_ADDRESS>/api/videos
$filters = ['polymorphic' => ['polymorphic_type' => 'Video', 'polymorphic_id' => {TAG_ID}, 'polymorphic_inverse'=true]];

This is where all the logic goes instead of duplicating code or needing multiple copies of the same filters
<?php

namespace App\EloquentFilters;

use Fouladgar\EloquentBuilder\Support\Foundation\Contracts\Filter;
use Illuminate\Database\Eloquent\Builder;

class Polymorphic extends Filter
{
    public $filtered = null;
    protected $modelNamespace = 'App\\';

    public function normal(Builder $builder, $value): Builder
    {
        switch($value['polymorphic_type']) {
            //Getting other models Based on a Tag
            case 'Tag':
                return $builder->join('tagables',function($join) use($value) {
                    $join->on('id','=','tagbles.tagable_id')
                        ->where('tagables.tagable_type', $this->filtered)
                        ->where('tagables.tag_id', $value['polymorphic_id']);
                });
                break;
            //OTHER CASES....
            default:
                return $builder;
        }
    }

    public function inverse(Builder $builder, $value): Builder
    {
        switch($this->filtered) {
            //Getting Tags
            case 'Tag':
                return $builder->join('tagables',function($join) use($value) {
                    $join->on('id','=','tagables.tag_id')
                        ->where('tagables.tagable_type', $value['polymorphic_type'])
                        ->where('tagables.tagable_id', $value['polymorphic_id']);
                });
                break;
            //OTHER CASES....
            default:
                return $builder;
        }
    }

    public function apply(Builder $builder, $value): Builder
    {
        if(key_exists('polymorphic_inverse',$value) && $value['polymorphic_inverse']){
            $value['polymorphic_type'] = $this->modelNamespace.$value['polymorphic_type'];
            return $this->inverse($builder,$value);
        }
        return $this->normal($builder,$value);
    }
}

Here is the filter for Tag's; And we assume that Tags can not contain other Tags....
<?php

namespace App\EloquentFilters\Tag;

use Illuminate\Database\Eloquent\Builder;
use App\EloquentFilters\Polymorphic;

class PolymorphicFilter extends Polymorphic
{
    public $filtered = 'Tag';

    public function apply(Builder $builder, $value): Builder
    {
        return parent::apply($builder,$value);
    }
}

Here is the Post Polymorphic filter; but the Video's Should be the same.
<?php

namespace App\EloquentFilters\Post;

use Illuminate\Database\Eloquent\Builder;
use App\EloquentFilters\Polymorphic;
use App\Post;

class PolymorphicFilter extends Polymorphic
{
    public $filtered = Post::class;

    public function apply(Builder $builder, $value): Builder
    {
        return parent::apply($builder,$value);
    }
}

@sniper7kills  thank you for your sharing :+1:
I think, strategy and abstract factory pattern can resolve this issue for make the code cleaner.

You were right; I've updated my previous comment with my updated code.
It still probably doesn't fit best practices; but its a vast improvement over the switch // if/else I was using before.

Well done.  Keep going on 👍✨

Well done.  Keep going on 👍✨


[$2000] Task description label stays on top

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

Action Performed:

Click on FAB -> Click Assign Task
Add some Title & Description -> Click Next
On Confirm Task screen, Click on Description to update description
Clear description -> Click on Next button
You will now again be on Confirm Task page (with Empty Description)
Click back button -> See Description label floating

Expected Result:
Description label should be placed inside textfield if it’s empty
Actual Result:
Description label is floating over textfield (as it has some text in it, but there is no data inside textfield )
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:

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

[ ] Android / native
[ ] Android / Chrome
[x] iOS / native
[ ] iOS / Safari
[ ] MacOS / Chrome / Safari
[ ] MacOS / Desktop

Version Number: 1.3.36-3
Reproducible in staging?: y
Reproducible in production?: y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
https://github.com/Expensify/App/assets/43996225/91866ac9-8efd-4fb7-9ad1-7975593d7a3e
https://github.com/Expensify/App/assets/43996225/f0e78869-706e-4ab0-aa5f-df782aaf7e49
Expensify/Expensify Issue URL:
Issue reported by: @DinalJivani
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1688400346545699
View all open jobs on GitHub
Upwork Automation - Do Not Edit

Upwork Job URL: https://www.upwork.com/jobs/~017f8f2919130b85b3
Upwork Job ID:<PHONE_NUMBER>441887744
Last Price Increase: 2023-07-26

Yes thx for pinging me, I will look in a few hours into this!

Looking into it now

I do think I found a clean solution (note: I am the author of the original PR that caused the regression 😅 ):
Proposal
Please re-state the problem that we are trying to solve in this issue.
In our code we use uncontrolled and controlled TextInputs (i.e. providing a value prop or not). A recent change to our BaseTextInput component caused a regression where a controlled component wouldn't deactivate its label when the prop value has been reset to being empty (and the text input blurred).
What is the root cause of that problem?
Currently we are deciding on whether to deactivate the label based on two criteria:

The text input isn't focused anymore
We capture whether we have an input value in a ref, when TextInput#onChangeText gets called

In the second criteria lies the root cause. When we update the TextInputs value by the value prop onChangeText won't get called. Hence, when clearing the input with the value prop, the hasValueRef is still true.
What changes do you think we should make in order to solve the problem?

Right now we have a useEffect that only triggers when the focus of the text input changes.
We extend that useEffect to also run when the value prop changes. When we detect that the value prop is empty and we have no focus, we will deactivate the label.
Before we were thinking we can't use the value prop in the useEffect because we wouldn't know whether the component is controlled or not, and thus could break the behaviour for uncontrolled text inputs. We can however add a simple check whether the component is controlled or not. The final result will look like this:
// We capture whether the input has a value or not in a ref.
// We need this information in case the component
// is uncontrolled (i.e. no value prop is supplied)
const hasValueRef = useRef(initialValue.length > 0);

const isControlled = props.value !== undefined && props.value !== null;
const inputValue = props.value || '';

// Activate or deactivate the label when either focus changes, or for controlled
// components when the value prop changes:
useEffect(() => {
    const hasValue = isControlled ? inputValue.length > 0 : hasValueRef.current;
    if (hasValue || isFocused) {
        activateLabel();
    } else if (!hasValue && !isFocused) {
        deactivateLabel();
    }
}, [activateLabel, deactivateLabel, inputValue, isControlled, isFocused]);

This change also makes the code cleaner as now we can get rid of this useEffect:
https://github.com/Expensify/App/blob/a6ae94d9a74fa7d1268a5aa7154405230c83c369/src/components/TextInput/BaseTextInput.js#L171-L182
What alternative solutions did you explore? (Optional)
I had a look at the previous two proposals. Here are my notes (please note that they are meant completely judge free, we are just striving for the best possible solutions, and your guys' proposals were a great help in finding the final solution I came up with, so big thanks here 🙌 )

@ginsuma Proposal: The proposal didn't really worked in my testing for fixing the issue, as setValue which gets called from onChangeText doesn't gets called necessarily when the value prop gets changed from the outside.
@kushu7 Proposal: I think this could work, however it would leave other cases unhandled. Also giving a base text input knowledge about the current navigation focus feels somehow wrong and adds too much outside knowledge to a simple component in my opinion.

@hannojg has given some great context above on the origin story. I'm not sure if we should just assign Hanno to see it through at this point? Thoughts @abdulrahuman5196 ?

If we want group input, let's feel inclined to post on the ongoing slack thread here (and post to channel)
https://expensify.slack.com/archives/C049HHMV9SM/p1688400346545699

just dm'ed @abdulrahuman5196 and hoping for some eyes on this soon!

On @hannojg 's proposal here https://github.com/Expensify/App/issues/22204#issuecomment-1623242605
The root cause is correct, we are not deactivating label on value prop being empty.
But on the changes proposed, why do we need to know if a component is controlled or not? We only have 2 basic cases right? Text has any one value(from controlled or uncontrolled value) and is focused we activate label(move it to top).
if the both become false we will deactivate label.
At end of day, it just the value and focus state which decides label status, not sure why we need to if its controlled or not? Am I missing something?

const isControlled = props.value !== undefined && props.value !== null;

And I find this condition issueful, but even props.value could be passed null on initial value from parent component.

@abdulrahuman5196 Having form inputs to be controlled or not controlled is something the developer has to actively decide when developing with react. Its like when you need to choose which type a variable has to be.
When adding a input somewhere the developer has to actively decide "do i want this to be controlled, or not".
This is also mentioned in the docs.
Also, if you pass null or undefined to the value prop of a input, you are telling react (native), that you want this input to be uncontrolled. Its like you aren't setting a value prop at all.
Try creating a input in a react component with an initial value of undefined, and then change that value later on to a string value (setState, useState). React will throw a developer warning, informing you that its a anti-pattern to switch from a uncontrolled input to a controlled input.

@hannojg I think you had misunderstood the question.
For this particular issue as per your proposal, i am not sure you need to know if a component is controlled or not to solve this issue.
for example

const hasValue = isControlled ? inputValue.length > 0 : hasValueRef.current;

here we can just consider hasValue to be true if one of the inputValue.length > 0 : hasValueRef.current; is true. Since i think we will have a issue mentioned below.

const isControlled = props.value !== undefined && props.value !== null;

And I am not sure if this statement will be correct always. For case, I can treat the input controlled by having passing value prop. But I could pass null as a value itself to TextInput

@abdulrahuman5196 you are right, we maybe can get rid of the isControlled check, and just use the value for comparison.
Will check that later today.
When it comes to passing null to an input, this is something we will never do, as it's also an incorrectness that will generate a warning by react:

Warning: `value` prop on `input` should not be null. Consider using an empty string to clear the component or `undefined` for uncontrolled components.

Any update @hannojg

@michaelhaxhiu There hasn't been any updates from @hannojg . Should we increase bounty to get more proposals or wait for some more time?

Exactly my thought.

@abdulrahuman5196 I updated my proposal to get rid of the isControlled variable.
I think the vase with the value being null can be neglected as technically we never do this anywhere, and If we would ew would get an error.

@kushu7 sure, will send in the next hours, hold on!

@kushu7 @abdulrahuman5196 After looking again very careful into this, i came to the following conclusion. Detecting in our BaseTextInput component whether it is used as a controlled or uncontrolled component is legitimate.
I will post two diffs, the first one is using the isControlled detection, the second one isn't using it. However, we need more code to express the same behaviour when not using the detection. And in addition i think it makes the code harder to think about/to understand. Please see yourself:
Proposal 1: Using `isControlled` detection

In react and react native the input components have a built-in distinguish between controlled and uncontrolled components. Thus, when we write a abstraction on top of their input components, we have to also take this information also into account. Thats why in my humble opinion its okay to use this info in the TextInput. Testing for a controlled component by `props.value !== undefined` is accurate and in accordance with the react documentation and their code.

diff --git a/src/components/TextInput/BaseTextInput.js b/src/components/TextInput/BaseTextInput.js
index 68c09e3a7f..e5c72ff9c7 100644
--- a/src/components/TextInput/BaseTextInput.js
+++ b/src/components/TextInput/BaseTextInput.js
@@ -22,8 +22,8 @@ import PressableWithoutFeedback from '../Pressable/PressableWithoutFeedback';
 import withLocalize from '../withLocalize';

 function BaseTextInput(props) {
-    const inputValue = props.value || props.defaultValue || '';
-    const initialActiveLabel = props.forceActiveLabel || inputValue.length > 0 || Boolean(props.prefixCharacter);
+    const initialValue = props.value || props.defaultValue || '';
+    const initialActiveLabel = props.forceActiveLabel || initialValue.length > 0 || Boolean(props.prefixCharacter);

     const [isFocused, setIsFocused] = useState(false);
     const [passwordHidden, setPasswordHidden] = useState(props.secureTextEntry);
@@ -168,34 +168,22 @@ function BaseTextInput(props) {
         [props.autoGrowHeight, props.multiline],
     );

-    useEffect(() => {
-        // Handle side effects when the value gets changed programatically from the outside
-
-        // In some cases, When the value prop is empty, it is not properly updated on the TextInput due to its uncontrolled nature, thus manually clearing the TextInput.
-        if (inputValue === '') {
-            input.current.clear();
-        }
-
-        if (inputValue) {
-            activateLabel();
-        }
-    }, [activateLabel, inputValue]);
-
-    // We capture whether the input has a value or not in a ref.
-    // It gets updated when the text gets changed.
-    const hasValueRef = useRef(inputValue.length > 0);
+    // We need this information in case the component
+    // is uncontrolled (i.e. no value prop is supplied)
+    const hasValueRef = useRef(initialValue.length > 0);
+    const inputValue = props.value || '';
+    const isControlled = props.value !== undefined;
+    const hasValue = isControlled ? inputValue.length > 0 : hasValueRef.current;

-    // Activate or deactivate the label when the focus changes:
+    // Activate or deactivate the label when either focus changes, or for controlled
+    // components when the value prop changes:
     useEffect(() => {
-        // We can't use inputValue here directly, as it might contain
-        // the defaultValue, which doesn't get updated when the text changes.
-        // We can't use props.value either, as it might be undefined.
-        if (hasValueRef.current || isFocused) {
+        if (hasValue || isFocused) {
             activateLabel();
-        } else if (!hasValueRef.current && !isFocused) {
+        } else if (!hasValue && !isFocused) {
             deactivateLabel();
         }
-    }, [activateLabel, deactivateLabel, inputValue, isFocused]);
+    }, [activateLabel, deactivateLabel, hasValue, isFocused]);

     /**
      * Set Value & activateLabel
@@ -209,9 +197,15 @@ function BaseTextInput(props) {
         }

         Str.result(props.onChangeText, value);
+
+        // In case the text input is uncontrolled we need to update
+        // the info whether we have a value AND need to eventually
+        // activate the label:
         if (value && value.length > 0) {
             hasValueRef.current = true;
-            activateLabel();
+            if (!isControlled) {
+                activateLabel();
+            }
         } else {
             hasValueRef.current = false;
         }

Proposal 2: Not using detection

In this case we have to reset the `hasInputValueRef` when we externally clear the value that we pass as prop:

diff --git a/src/components/TextInput/BaseTextInput.js b/src/components/TextInput/BaseTextInput.js
index 68c09e3a7f..90947ad75d 100644
--- a/src/components/TextInput/BaseTextInput.js
+++ b/src/components/TextInput/BaseTextInput.js
@@ -22,8 +22,8 @@ import PressableWithoutFeedback from '../Pressable/PressableWithoutFeedback';
 import withLocalize from '../withLocalize';

 function BaseTextInput(props) {
-    const inputValue = props.value || props.defaultValue || '';
-    const initialActiveLabel = props.forceActiveLabel || inputValue.length > 0 || Boolean(props.prefixCharacter);
+    const initialValue = props.value || props.defaultValue || '';
+    const initialActiveLabel = props.forceActiveLabel || initialValue.length > 0 || Boolean(props.prefixCharacter);

     const [isFocused, setIsFocused] = useState(false);
     const [passwordHidden, setPasswordHidden] = useState(props.secureTextEntry);
@@ -168,34 +168,29 @@ function BaseTextInput(props) {
         [props.autoGrowHeight, props.multiline],
     );

-    useEffect(() => {
-        // Handle side effects when the value gets changed programatically from the outside
-
-        // In some cases, When the value prop is empty, it is not properly updated on the TextInput due to its uncontrolled nature, thus manually clearing the TextInput.
-        if (inputValue === '') {
-            input.current.clear();
-        }
+    // We need this information in case the component
+    // is uncontrolled (i.e. no value prop is supplied)
+    const hasValueRef = useRef(initialValue.length > 0);
+    const inputValue = props.value || '';
+    const hasValue = inputValue.length > 0 || hasValueRef.current;

-        if (inputValue) {
+    // Activate or deactivate the label when either focus changes, or for controlled
+    // components when the value prop changes:
+    useEffect(() => {
+        if (hasValue || isFocused) {
             activateLabel();
+        } else if (!hasValue && !isFocused) {
+            deactivateLabel();
         }
-    }, [activateLabel, inputValue]);
-
-    // We capture whether the input has a value or not in a ref.
-    // It gets updated when the text gets changed.
-    const hasValueRef = useRef(inputValue.length > 0);
+    }, [activateLabel, deactivateLabel, hasValue, isFocused]);

-    // Activate or deactivate the label when the focus changes:
+    // When the value prop gets cleared externally, we need to deactivate the label:
     useEffect(() => {
-        // We can't use inputValue here directly, as it might contain
-        // the defaultValue, which doesn't get updated when the text changes.
-        // We can't use props.value either, as it might be undefined.
-        if (hasValueRef.current || isFocused) {
-            activateLabel();
-        } else if (!hasValueRef.current && !isFocused) {
-            deactivateLabel();
+        if (props.value === undefined || props.value > 0) {
+            return;
         }
-    }, [activateLabel, deactivateLabel, inputValue, isFocused]);
+        hasValueRef.current = false;
+    }, [props.value]);

     /**
      * Set Value & activateLabel
@@ -209,9 +204,13 @@ function BaseTextInput(props) {
         }

         Str.result(props.onChangeText, value);
+
         if (value && value.length > 0) {
             hasValueRef.current = true;
-            activateLabel();
+            // When the componment is uncontrolled, we need to manually activate the label:
+            if (props.value === undefined) {
+                activateLabel();
+            }
         } else {
             hasValueRef.current = false;
         }

Reviewing today

@abdulrahuman5196 any update on this? It's at week 4 and so it's important we make progress, this will get highlighted in the weekly update in #expensify-open-source

I'm adding the Engineering label for hopes of getting eyes internally too. Maybe @hayata-suenaga can help us confirm if @hannojg proposal will work so he can get moving on it 🙏

Sorry for the delay. Will close our my end of proposals in my morning.

I'll wait for @abdulrahuman5196 to choose a proposal

thank you. Starting the day now. Just closing out a deployment blocker PR and will start review in 2 hours.

Reviewing now.

@kushu7 's proposal here https://github.com/Expensify/App/issues/22204#issuecomment-1620611235.
Main solution was brought in after @hannojg 's proposal and its more like a code optimization, so I wouldn't be able to consider it as a separate proposal.
Alternate solution was their first solution. But it tries to solve the problem from focus perspective which wouldn't provide a generalized solution for this issue. So I am not inclined on the same.

@hannojg 's proposal here https://github.com/Expensify/App/issues/22204#issuecomment-1623242605 targeted a generalized solution and it looks good and works well.
@hannojg  another point is still i am not convinced if we should bring in logic of controlled, i think the way in current proposal might be good way to start. And I won't be able to check on the code diff provided here, since code diffs are left for PR phase. Maybe during PR we can discuss more on the same.
🎀 👀 🎀
C+ Reviewed
cc: @hayata-suenaga

Will create a PR later today!

@hannojg Any update on PR?

PR is up @abdulrahuman5196 @muttmuure

https://github.com/Expensify/App/pull/24199

@abdulrahuman5196 could you check the PR?

We have been waiting on @hannojg to solve merge conflicts
cc: @michaelhaxhiu @hayata-suenaga

This isn't done yet, but it's progressing. I'm preparing to go OOO by end of the week for my sabbatical, so I'm going to remove my assignment and leave this with @muttmuure.
Next steps are similar to before, but we are closer :)

@hannojg is going to complete the internal PR to solve this.
After that's done, we'll process payment to the C+ ($1000 for @abdulrahuman5196) and Bug reporter ($250 for @DinalJivani)

PR is resolved and working now 👍

The PR that introduced the bug has been identified. Link to the PR:

https://github.com/Expensify/App/pull/20186

The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake. Link to comment:
A discussion in #expensify-bugs has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner. Link to discussion:

https://github.com/Expensify/App/pull/20186#issuecomment-1755758238

Determine if we should create a regression test for this bug.
If we decide to create a regression test for the bug, please propose the regression test steps to ensure the same bug will not reach production again.

No. Not beneficial to add regression test for this minor bug

seems we don't need regression test
are we paying for payment?

@muttmuure Gentle ping on payment processing. Waiting for over a week.

Looking now

$1000 - C+ @abdulrahuman5196

Invited to Upwork job

@muttmuure  accepted

@muttmuure
Reporting bonus is pending here

Invited!


Allow adding an arbitrary user message to toast and tray

Extends the userMessages framework so any arbitrary toast/tray message can be added for display.
Previously only an API error or a failed login could generate a message.
This will be useful to push toast notification when async events start (e.g. restarting a VM) or for other short term messages (e.g. trying to jump to a page you don't have permissions for).

No screenshots since the toats and tray notification are unchanged.
#784 uses this to send toast notification when a user gets booted to the main list pages when they try to directly access VM create or VM edit.


Logstash Crashing GeoIP Volume Location

Describe the bug
Logstash crashes due to the volume path in the docker-compose.yml for GeoIP. According to that error it is looking in the path /usr/share/GeoIP/, but the volume is mounted to /usr/share/logstash/GeoIP/
https://github.com/3ilson/docker-pfelk/blob/651a902cfe7a22b637046d6938d3a0d3a996c442/docker-compose.yml#L102
[ERROR] 2020-04-08 22:00:03.265 [Converge PipelineAction::Create<main>] geoip - Invalid setting for geoip filter plugin:,
,
  filter {,
    geoip {,
      # This setting must be a path,
      # File does not exist or cannot be opened /usr/share/GeoIP/GeoLite2-City.mmdb,
      database => "/usr/share/GeoIP/GeoLite2-City.mmdb",,
.,
    },
  },

Changing this to be /usr/share/GeoIP/:/usr/share/GeoIP/ fixes the issue but would like to understand if that is not the intention.
To Reproduce
Steps to reproduce the behavior:
Follow the README.md on a fresh install.
Operating System (please complete the following information):

OS (printf "$(uname -srm)\n$(cat /etc/os-release)\n"): Ubuntu 18.04.4 LTS
Version of Docker (docker -v): 19.03.8
Version of Docker-Compose (docker-compose -v): 1.24.1

Elasticsearch, Logstash, Kibana (please complete the following information):

Version of ELK (cat /docker-pfelk/.env) Latest zip - afb6bec16f8c6870626b315cc8b52a7c5f8d2aad

**Service logs

docker-compose logs pfelk01
docker-compose logs pfelk02
docker-compose logs pfelk03
docker-compose logs logstash
docker-compose logs kibana

logstash.txt
Additional context
Add any other context about the problem here.

@mmohoney - Awe....My last update dorked up all the paths.... I'm fixing them now

@mmohoney - All paths were updated and corrected.  I just installed a fresh instance without any issues. I apologize for the inconvenience.  Please give it another try (you'll need to download the pfelkdocker.zip that contains all the updated *.conf files).

Once you have verified that it works, please close this issue.

@a3ilson just stood up a new install successfully 👍 . I figured the paths needed updating as I had done that to get my install working earlier too.

Great/thanks!

I can open a new issue if you like, but as far as the dashboards, anything special besides using the pf-* index pattern and the files under the Dashboard folder? When I bring in the latest dashboard, most tiles say - "Could not locate that index-pattern-field (id: event.action.keyword)" and the like.

Should note, I have a manual install that I stood up in November with working dashboards but figured I would try Docker since I have a ton of other containers I run

@mmohoney - I just imported and didn't have any issues.  You may need to let it collect logs for a few minutes and refresh the fields. (Kibana>>Management>>Index Patterns>>pf-* and click the refresh icon.
When importing be sure to select the corresponding index pattern - see image below:

Yep that was it. Refreshing the index after a while brought in the missing fields. Liking the docker install so far.
Thanks for the time!


Forms

In this pull request:

Create a method called current_user in your ApplicationController to make current user data available to all controllers.
Create forms to perform the functions:

Creates a Post on behalf of the current_user.
Create a comment on behalf of the current_user.

Allow Users to add likes to Posts.

Hi @Swarzstein,
While you made a great effort in this project, unfortunately, I cannot proceed to review your code.
Invalid Code Review Request
You have submitted a project, that is invalid because the stylelint linter is failing
Your Code Review Request will be marked as invalid in your Dashboard, so please submit a new one once you are ready 🙏
Cheers and Happy coding!👏👏👏
Feel free to leave any questions or comments in the PR thread if something is not 100% clear.
Please, remember to tag me in your question so I can receive the notification.
Please, do not open a new Pull Request for re-reviews. You should use the same Pull Request submitted for the first review, either valid or invalid unless it is requested otherwise.

Invalid Code Review Request does not count into the code reviews limit.


1.0: redirectTo does not let me proceed to the requested state

I checked the docs and see that redirectTo can contain a condition.
// a fn conditionally returning a {state, params}
.state('F', {
  redirectTo: (trans) => {
    if (trans.params().foo < 10)
      return { state: 'F', params: { foo: 10 } };
  }
})

In my own code, I check if the user is logged in. If he is, I redirect to another state. Otherwise, I just want to go to the requested state. The problem is that if the condition is not met an error occurs and we won't go in the state initially requested.

angular.js:13920 TypeError: Cannot read property 'state' of undefined
at handleResult (redirectTo.ts:25)
at processQueue (angular.js:16383)
at angular.js:16399
at Scope.$eval (angular.js:17682)
at Scope.$digest (angular.js:17495)
at Scope.$apply (angular.js:17790)
at angular.js:19621
at completeOutstandingRequest (angular.js:5964)
at angular.js:6243

As a workaround, I returned an empty object {} instead of nothing. It allows your code to go to the end without errors.
function handleResult(result: any) {
    let $state = trans.router.stateService;

    if (result instanceof TargetState) return result;
    if (isString(result)) return $state.target(<any> result, trans.params(), trans.options());
    if (result['state'] || result['params'])
      return $state.target(result['state'] || trans.to(), result['params'] || trans.params(), trans.options());
  }

Thanks, that does sound like a bug.

Think we simply need to exit early from this function when result is null or undefined
https://github.com/ui-router/core/blob/master/src/hooks/redirectTo.ts#L20-L27

Perfect. Thanks.


FYI: Managed processes started using deno task cannot be stopped

Caused by a Deno/deno_task_shell issue where deno task leaves ghost processes
https://github.com/denoland/deno/issues/18445
https://github.com/denoland/deno_task_shell/issues/33
Context in this closed dax-issue
https://github.com/dsherret/dax/issues/146
Workaround is to use deno run ... instead of deno task when defining a process command in pup.

Not related to pup, but still relevant. Closing as there is no fix.


Fix onClose

Currently, onClose can get called before the listener is able to produce a value. Also, any error raised in onClose is swallowed if the onClose function is a promise. This merge request attempts to resolve both of those issues.

#26


ros_cvb_camera_driver: 0.0.1-1 in 'kinetic/distribution.yaml' [bloom]

Increasing version of package(s) in repository ros_cvb_camera_driver to 0.0.1-1:

upstream repository: https://github.com/gleichaufjo/ros_cvb_camera_driver.git
release repository: https://github.com/gleichaufjo/ros_cvb_camera_driver.git
distro file: kinetic/distribution.yaml
bloom version: 0.9.1
previous version for package: null

ros_cvb_camera_driver
* Added license in package.xml
* Changed package xml
* Finished ros_cvb_camera_driver. Rectified image can now be published.
* Added camera_info
* Cropped fish eye image
* Initial commit
* Contributors: Johanna Gleichauf

Holding for sync


[beta] Scheduling keys broken in "Today" & "Next 7 days"

Note, this issue only happens in beta.todoist.com (for now).
The broken keys are t and T. Instead of opening the scheduling window, they take me into task-editing mode.
Weirdly, this only happens in the "Today" and "Next 7 days" views. (Er...not true, it also happens in certain kinds of custom filter views, but trying to describe that would just muddle things.)

Thanks for reporting this issue!  It's now fixed in version 64.


refactor(optimizer): reset expression display id for explain

I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
What's changed and what's your intention?

As title.

Checklist

[x] I have written necessary rustdoc comments
[x] I have added necessary unit tests and integration tests
[x] I have added fuzzing tests or opened an issue to track them. (Optional, recommended for new SQL features).
[x] I have demonstrated that backward compatibility is not broken by breaking changes and created issues to track deprecated features to be removed in the future. (Please refer to the issue)
[x] All checks passed in ./risedev check (or alias, ./risedev c)

Documentation

[x] My PR DOES NOT contain user-facing changes.

Click here for Documentation
Types of user-facing changes
Please keep the types that apply to your changes, and remove the others.

Installation and deployment
Connector (sources & sinks)
SQL commands, functions, and operators
RisingWave cluster configuration changes
Other (please specify in the release note below)

Release note

#8005

Don't do this! Because of #7998, the optimizer calls explain_to_string in the middle of optimization

Don't do this! Because of #7998, the optimizer calls explain_to_string in the middle of optimization

Any problem? We will reset the expr_display_id back after explaining.


Sitemap.xml date update checker

⚠ Please verify that this feature request has NOT been suggested before.

[x] I checked and didn't find similar feature request

🏷 Feature Request Type
New Monitor
🔖 Feature description
I think it would be good if a function was added that would check the sitemap's up-to-dateness
✔ Solution
I have eshops that have items and I have to regenerate sitemaps with cron, sometimes it happens that cron crashes and I find out about it after a long time.
❓ Alternatives
No response
📝 Additional Context
No response

Monitor you cronjobs:
https://cronitor.io/
https://healthchecks.io/

sometimes it happens that cron crashes

I think this should be monitored via the ´push´-monitor instead.


Add rewrite-templating annotation processor to also produce OpenRewrite recipes

Hi all! As discussed both offline and on https://github.com/openrewrite/rewrite-templating/issues/5 here's a PR that adds the  rewrite-templating annotation processor. This generates OpenRewrite recipes from the same Refaster rules in error-prone-contrib, which can then be run through OpenRewrite and Moderne as well using the same jar.
Increase in file size
There's an increase in the file size after adding this annotation processor. Nothing shocking in absolute sense, but figured point it out here for review in case anyone is sensitive to that. All dependencies I've added as <scope>provided</scope>
- -rw-rw-r-- 1 tim tim 2,9M dec 17 17:26 error-prone-contrib-0.14.1-SNAPSHOT.jar
+ -rw-rw-r-- 1 tim tim 3,4M dec 17 16:59 error-prone-contrib-0.14.1-SNAPSHOT.jar

To do here

[ ] Go over "forbidden" licenses used
[ ] Run through any additional checks
[ ] Potentially leverage more of the existing tests, depending on generated recipe coverage

Future work in rewrite-templating
rewrite-templating doesn't yet support all features of Refaster used in error-prone-support; here's a quick link to a few open issues. Well possible that we discover more as we go, but figured we can start somewhere and iterate.

https://github.com/openrewrite/rewrite-templating/issues/47
https://github.com/openrewrite/rewrite-templating/issues/21
https://github.com/openrewrite/rewrite-templating/issues/49

Fixes https://github.com/openrewrite/rewrite-templating/issues/5

As for the forbidden licenses; these new warnings are logged from mvnd -U clean package -Dverification.warn
[WARNING] There are 7 forbidden licenses used:
[WARNING] License: 'BSD 3-Clause "New" or "Revised" License (BSD-3-Clause)' used by 1 dependencies:
 -abego TreeLayout Core (org.abego.treelayout:org.abego.treelayout.core:1.0.3 - http://treelayout.sourceforge.net)
[WARNING] License: 'The MIT License (MIT)' used by 1 dependencies:
 -ClassGraph (io.github.classgraph:classgraph:4.8.165 - https://github.com/classgraph/classgraph)
[WARNING] License: 'Public Domain, per Creative Commons CC0' used by 2 dependencies:
 -HdrHistogram (org.hdrhistogram:HdrHistogram:2.1.12 - http://hdrhistogram.github.io/HdrHistogram/)
 -LatencyUtils (org.latencyutils:LatencyUtils:2.0.3 - http://latencyutils.github.io/LatencyUtils/)
[WARNING] License: 'The BSD License' used by 1 dependencies:
 -StringTemplate 4 (org.antlr:ST4:4.3.4 - http://nexus.sonatype.org/oss-repository-hosting.html/ST4)
[WARNING] License: 'BSD-2-Clause' used by 1 dependencies:
 -HdrHistogram (org.hdrhistogram:HdrHistogram:2.1.12 - http://hdrhistogram.github.io/HdrHistogram/)
[WARNING] License: 'Unicode/ICU License' used by 1 dependencies:
 -ICU4J (com.ibm.icu:icu4j:71.1 - https://icu.unicode.org/)
[WARNING] License: 'BSD licence' used by 1 dependencies:
 -ANTLR 3 Runtime (org.antlr:antlr-runtime:3.5.3 - http://www.antlr.org)

Some can likely be merged, although I've only briefly looked into this as I'm not a lawyer to know the exact differences between the number of clauses for instance.
https://github.com/PicnicSupermarket/error-prone-support/blob/94023ed1d7afdd021f1c9dd8226dc5774843ed15/pom.xml#L1238-L1299

The license aliases are all safe; I've added a commit to suppress then. (The formatting, classification and comments may look a bit odd, but this is fully sync'ed from our internal Maven Parent.)

Added one more commit; build should now pass :eyes:.
The increase in artifact size isn't an issue I think. :heavy_check_mark:
I'll need to play a bit more with the PR before finalizing the review (which may not happen this evening), but let me say: very cool and thanks for pushing this forward! :rocket:

Hmm, the SonarCloud analysis fails with:

Project not found. Please check the 'sonar.projectKey' and 'sonar.organization' properties, the 'SONAR_TOKEN' environment variable, or contact the project administrator

That's a setup issue on our side; will have to check the docs on that one. (Most PRs we get are from Picnic colleagues, who push a branch to this repo, rather than creating a separate fork.)
The JDK 21 build also fails when analyzing the generated sources. If OpenRewrite can be tweaked to generate compliant files: great! Otherwise we'll have to check how to suppress those warnings. (But that may then require a separate compilation phase, which wouldn't be nice. :thinking:.)

Thanks for the quick feedback! Looking at the Java 21 build failures it seems to stumble over new warnings mostly:
[WARNING] /home/runner/work/error-prone-support/error-prone-support/error-prone-contrib/target/generated-sources/annotations/tech/picnic/errorprone/refasterrules/PrimitiveRulesRecipes$LessThanRecipe$1_before.java:[7,8] use of default constructor, which does not provide a comment
[WARNING] /home/runner/work/error-prone-support/error-prone-support/error-prone-contrib/target/generated-sources/annotations/tech/picnic/errorprone/refasterrules/PrimitiveRulesRecipes$LessThanRecipe$1_before.java:[9,8] no main description
[WARNING] /home/runner/work/error-prone-support/error-prone-support/error-prone-contrib/target/generated-sources/annotations/tech/picnic/errorprone/refasterrules/PrimitiveRulesRecipes$LessThanRecipe$1_after.java:[7,8] use of default constructor, which does not provide a comment
[WARNING] /home/runner/work/error-prone-support/error-prone-support/error-prone-contrib/target/generated-sources/annotations/tech/picnic/errorprone/refasterrules/PrimitiveRulesRecipes$LessThanRecipe$1_after.java:[9,8] no main description
[WARNING] /home/runner/work/error-prone-support/error-prone-support/error-prone-contrib/target/generated-sources/annotations/tech/picnic/errorprone/refasterrules/PrimitiveRulesRecipes$LessThanOrEqualToRecipe$1_before.java:[7,8] use of default constructor, which does not provide a comment

What's the magic comment I need to add to the generated template files to make that warning go away?
As for the SonarCloud issue: by default forks don't have (and shouldn't have) access to secrets I believe, which might cause your issues here. Not quite sure about what the best way forward is there, since you also don't want untrusted forks from running away with your Sonar and other secrets. Fun times.

use of default constructor, which does not provide a comment

This is one we've also seen on other code; we work around it by making the constructor explicit and adding a comment, like this. Seems a bit artificial, but okay.

no main description

Haven't seen that one before, but based on this thread I assume it's about making sure that the Javadoc has an initial summary line.
W.r.t. Sonarcloud: there's this feature request. Perhaps it'd be secure if the code on the target branch would be executed. But if we can't find a fix, we can look into making the analysis conditional. (Which would kind of defeat the purpose, but alas.)

I added a commit to try and skip the SonarCloud analysis; that worked. Opened a separate PR for that improvement (also to test the "other side" of the equation): #926.

I added another commit to deal with some dual-licensed dependencies; by whitelisting more entries we avoid some redundant build output.
Two open points:

The GitHub Actions Windows build still fails. I have a suspicion that this is due to -XepExcludedPaths:\Q${project.build.directory}${file.separator}\E.* not working with Windows paths. OTOH, IIRC that used to work before, so not sure.

Though we should better understand this ^, one suggestion: @timtebeek WDYT of adding an @Generated annotation to the generated recipe classes? Then they'll (also) be covered by -XepDisableWarningsInGeneratedCode and similar logic for Checkstyle.

Build time seems to be increased by ~15 seconds. Not a deal breaker, but it may be nice to understand why. (Solving point (1) may largely also solve this, though.)

Not sure I'll have (much) more time to look into this PR today, so next update may be a while.

Added a commit to see whether indeed only the Windows build tries to run Error Prone against the generated recipes, and the answer turns out to be "yes", because now the other (previously cancelled) builds pass. This'll require more investigation (likely EOD earliest).
Will revert the test commit.

Seems something got stuck. Since there's now also a conflict with the target branch, I'll retrigger by rebasing.

Right, so for Windows we have -XepExcludedPaths:\QD:\a\error-prone-support\error-prone-support\refaster-runner\target\\E.*. The double-backslash looks odd, but should work:
jshell> Pattern.compile("\\QD:\\a\\error-prone-support\\error-prone-support\\target\\\\E.*").matcher("D:\\a\\error-prone-support\\error-prone-support\\target\\x").matches()
$1 ==> true

This matches most paths as printed in the logs. However, Error Prone (Javac?) output uses a different path format:
[WARNING] /D:/a/error-prone-support/error-prone-support/refaster-runner/target/generated-test-sources/test-annotations/tech/picnic/errorprone/refaster/runner/FooRulesRecipes.java:[11,1] [RemoveUnusedImports] Unused imports: org.openrewrite.java.template.Primitive

Perhaps we should just match against .*/target/.* then (to be tested), but that does seem unfortunate. Anyway, meetings now :)

Alright, I figured out why -XepExcludedPaths:\Q${project.build.directory}${file.separator}\E.* doesn't work: Error Prone matches against a path that's derived from a file's URI, which in practice will always contain forward slashes.
So without overly complicated Maven logic (e.g. involving an extra plugin to do some value transformations) I think that matching against ${project.build.directory} won't work.
I rebased and added a commit with a possible "fix". Let's see whether this works :eyes:

Looks good. No mutations were possible for these changes. Mutation testing report by Pitest. Review any surviving mutants by inspecting the line comments under Files changed.

As a side note it would be nice if this were a GitHub Check rather than a (repeated) comment, but that might just be me. 😇

Looks good. No mutations were possible for these changes. Mutation testing report by Pitest. Review any surviving mutants by inspecting the line comments under Files changed.

As a side note it would be nice if this were a GitHub Check rather than a (repeated) comment, but that might just be me. 😇

Very much. I guess that would be a feature request for @hcoles; we followed the instructions for Pitest. Perhaps we can look into and contribute a better solution; not high on the TODO list, though :grimacing:.

NB: It may be that #515 is merged before this PR. In that case I can take care of the resultant conflict.

NB: It may be that #515 is merged before this PR. In that case I can take care of the resultant conflict.

Done!

Forgot to say; the only thing I wasn't yet able to fix is running the new test in my IntelliJ 🤔. Not sure that works for you guys?

Forgot to say; the only thing I wasn't yet able to fix is running the new test in my IntelliJ 🤔. Not sure that works for you guys?

Did you mark the generated folder as sources in your IDE?

Forgot to say; the only thing I wasn't yet able to fix is running the new test in my IntelliJ 🤔. Not sure that works for you guys?

Did you mark the generated folder as sources in your IDE?

I hadn't tried until now (I think), but (IIUC) for me IDEA fails during the build step that precedes the test run. The error I get is:
java: java.lang.LinkageError: Tried to instantiate an instance of the annotation com.google.errorprone.annotations.DoNotCall while processing after, but the annotation class file was not present on the classpath.

IDEA did (automatically) mark the directory as a source folder. I tried to add com.google.errorprone:error_prone_annotations to the same annotationProcessorPaths declaration as rewrite-templating, but that didn't help.
One thing that's interesting, is that OpenRewrite indeed copies over the annotation to the recipe, even though that won't have any functional impact (see e.g. javap -v 'error-prone-contrib/target/classes/tech/picnic/errorprone/refasterrules/TestNGToAssertJRules$Fail.class'). Perhaps the annotation processor should discard such annotations instead, which would also yield smaller recipe class files? :thinking:

Indeed sounds like we ought not to pass that annotation into the recipe; thanks for pointing that out! On the (long) list here to fix, possibly fixed as side effect of

https://github.com/openrewrite/rewrite-templating/pull/57

Top! I think that this isn't a blocker for merging the PR. I synced the branch; will let @rickie merge if he agrees.

No blocker, lets merge! Sorry for my late response, I am (still) recovering from being sick..

Awesome! Look forward expanding this further in the near future and trying out the next release!

The IDEA issue described in this comment turns out to be IDEA-342187, unrelated to OpenRewrite; I filed #958.


Add resetDatabase method

fix #4

Hmm.. calling the method throws because process is not available on the client side. Any ideas?

You need to add the cleaner.js file only on the server and remove the if (Meteor.isClient) condition. Then it should work. You define methods always on the server side and only on the client side if you need a client method stub for latency compensation reasons. We don't need a client method stub in this case.

Also we may should namespace the method name to avoid conflicts. E.g. xolvio:cleaner/resetDatabase.

Fixed by #10


chore: test

Test

Test

Test

Test

This comment was written by a bot!

This comment was written by a bot!

This comment was written by a bot!

This comment was written by a bot!

This comment was written by a bot!

This comment was written by a bot!

Test

Test

Test

Test

Deploy Preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview

Deploy preview


Embedded CSS is weird in HTMLs.

Highlighting ', 'html', function(codes) { console.log(codes); });

Result (line breaks added for readability):

  &
  lt
  ;
  style
  >
  {
  </
  style
  >

It seems like it's trying to parse that opening


PlatformException on write

When I start my app and click a button (which executes the following code), I get a PlatformException(IOError, null, null, null) in the line, where the tag is written. This issue seems to have nothing to do with the tag itself, because when I try to write that particular string in a NFC-write-app, everything works correctly.
  Future<void> nfc() async {
    print("start reading");
    Stream<NDEFMessage> stream = NFC.readNDEF();
    NDEFMessage tag = await stream.first;
    // do something with tag content
    print("read finished");

    NDEFMessage msg = NDEFMessage.withRecords([
      NDEFRecord.text("docmanagement:5a900ee9-003b-4777-9295-a656d8c8810a:aa351a8f-227a-4658-a672-48a319305740"),
    ]);
    await tag.tag.write(msg);
    print("write finished");
  }

Same thing here. It seems to be working but then it just stops.

This same problem is affecting me. It worked completely fine before then suddenly this starts happening.
Some insight into the problem: To me, it only happens with empty NFCs, otherwise it works fine.


Need help on userspace reboot issue

Hi, I am porting permaflex (https://github.com/shiftcmdk/PermaFlex) to Dopamine (1.0.5), and encountered a userspace reboot issue.
Situation:

Currently it works if no userspace reboot happen. When I install the tweak via theos/Sileo and it works after a respring.
If an userspace reboot happens with tweak installed + tweak injection enabled, device stuck on apple logo for 1-2 minutes and eventually fully reboot.
If tweak gets uninstalled and/or tweak injection disabled then userspace reboots work.

Need help on:

Do you have idea of what could possibily go wrong? I guess the tweak might hooked something it shouldn't touch but can't figure out what it is.
How can I diagnose this?

p.s. tried to print a log of hooked processes upon userspace reboot, here is what I got:
com.opa334.Dopamine
/var/containers/Bundle/Application//Dopamine.app/Dopamine
<- this is when I pressed the userspace reboot button
com.apple.springboard
/System/Library/CoreServices/SpringBoard.app/SpringBoard
com.apple.Preferences
/Applications/Preferences.app/Preferences
com.apple.springboard
/System/Library/CoreServices/SpringBoard.app/SpringBoard
com.apple.springboard
/System/Library/CoreServices/SpringBoard.app/SpringBoard
<- device reboots here

Try uncommenting all NSLog calls. If you try calling that inside logd itself it will make the process stuck. Other than that, no idea.

Try commenting out all NSLog calls. If you try calling that inside logd itself it will make the process stuck. Other than that, no idea.

Tried and it still not work :(
Found a few logs in settings, seems watchdog killed a few SpringBoards due to timeout, but the problem still present even I commented out everything it does inside SpringBoard (including NSlogs).

https://github.com/shiftcmdk/PermaFlex/blob/master/Tweak.xm#L243 Instead of this, use this https://github.com/opa334/Choicy/blob/master/Tweak.x#L45

https://github.com/shiftcmdk/PermaFlex/blob/master/Tweak.xm#L243-L245 Instead of these, use these https://github.com/opa334/Choicy/blob/master/Tweak.x#L40-L55

Fixed using the save variant but no lock :-(
P.S. My modifications were available via this fork:
https://github.com/bgli100/PermaFlex

Also I feel like this is only supposed to be called for SpringBoard but the logic is wrong and it will be called for everything that's an app https://github.com/shiftcmdk/PermaFlex/blob/master/Tweak.xm#L261

It works correctly but it is bad code. I re-structured this part.
The method initForSpringBoard checks bundle identifier again inside itself and runs if it is springboard. Redundent.

Update:
It seems SpringBoard is not related to the fault. I played with the .plist file and found if the tweak injects to any of the following 2 bundle, userspace reboot fails (now sure why, it fails when the tweak does not run anything):
com.apple.UIKit
com.apple.security
But it works when injecting both com.apple.springboard and com.apple.AdSupport.
At least I have a partial fix now

I will test this soon.

I had similar issue and this fixed it, please try and if it helps you Opa is going to finally fix this issue!!
1)Download and Install Xina 1.1.8 from TrollStore and Filza Trollstore edition and hit Jailbreak it will proccess it and it will work with Dopamine
2)You dont need Xina, Reboot, Go to Xina settings hit safe mode hit jailbreak
3)Now you can delete everything from /var/jb/Application!!!! in Filza but don't do it since there will be nothing because you are on Xina so
4)Go to /private/preboot/(YOUR SPECIAL ID)/jb-(some letters)/procursus/Application and delete every file inside there
If you need TrollStore version of Sileo until Opa fixes it, I can give it to you and Zebra too

I had similar issue and this fixed it, please try and if it helps you Opa is going to finally fix this issue!!
1)Download and Install Xina 1.1.8 from TrollStore and Filza Trollstore edition and hit Jailbreak it will proccess it and it will work with Dopamine 2)You dont need Xina, Reboot, Go to Xina settings hit safe mode hit jailbreak 3)Now you can delete everything from /var/jb/Application!!!! in Filza but don't do it since there will be nothing because you are on Xina so 4)Go to /private/preboot/(YOUR SPECIAL ID)/jb-(some letters)/procursus/Application and delete every file inside there If you need TrollStore version of Sileo until Opa fixes it, I can give it to you and Zebra too

you really want to get blocked, do you?

I had similar issue and this fixed it, please try and if it helps you Opa is going to finally fix this issue!!
1)Download and Install Xina 1.1.8 from TrollStore and Filza Trollstore edition and hit Jailbreak it will proccess it and it will work with Dopamine 2)You dont need Xina, Reboot, Go to Xina settings hit safe mode hit jailbreak 3)Now you can delete everything from /var/jb/Application!!!! in Filza but don't do it since there will be nothing because you are on Xina so 4)Go to /private/preboot/(YOUR SPECIAL ID)/jb-(some letters)/procursus/Application and delete every file inside there If you need TrollStore version of Sileo until Opa fixes it, I can give it to you and Zebra too

you really want to get blocked, do you? your bs has NOTHING to do with this issue so keep it out of it please

I mean if this fix works for many people, than I might be just right, why don't you consider that?

Right now Im flawless Dopamine user with Trollstored all apps because of this issue and its fine

the real question is when did we even ask, we didn't

no successful checkins from backboardd since load
service: backboardd, no successful checkins since load (180 seconds ago)
service: mediaserverd, no successful checkins since load (180 seconds ago)
service: logd, total successful checkins since load (180 seconds ago): 19, last successful checkin: 0 seconds ago
service: thermalmonitord, no successful checkins since load (180 seconds ago)
service: runningboardd, no successful checkins since load (180 seconds ago)
service: wifid, total successful checkins since load (180 seconds ago): 13, last successful checkin: 0 seconds ago
This panic was prevented by Dopamine and jailbreakd triggered a userspace reboot instead.

Tried to add com.apple.UIKit back in 1.1 and it seems Dopamine collects more info on failure now.
Not sure if it helps or gives hint on what I am breaking. (Or, how to avoid injecting those deamons?)

Figured out the issue.

A silly mistake, I used theos' default SDK (for 14.5) for compiling tweak which is intended for 15.0+.
Tweak should have BOTH arm64 and arm64e for ARCH. It is not gonna work if you only have one.

By viewing crash log of Mail/News app, it seems dyld refuse to work with such dylibs and choose to crash (not sure if it is the same issue for userspace reboot).


Chrome does not offer to save username / password.

Chrome does not seem to recognize that a username / password are being input, and thus does not offer to save / remember information.
Better yet - the ability to offer a "Remember Me" option that saves both username and password would be ideal.

Hello Ricky,
I ran into this problem myself recently, and in order to get Chrome to recognize the fields as login fields you need "Name=Username"/"Name=Password" attributes on the Username and Password fields respectively.
I added an HTML Snippet widget that uses JavaScript with Jquery, with the following code:
jQuery(document).ready(function(){
$(".form-control.username").attr("name","Username");
$("#LoginForm_widget_LoginForm_0_password").attr("name","Password");
});
Keep in mind that this is just a temporary solution I've come up with, and it can be temperamental. For example: if you get redirected on the login via javascript, the function won't run, and you'll get inconsistent behavior.
Also I couldn't find a solution to get IE to remember passwords, if you do, please let me know.

For IE10, I found this info.
Because the widget submit the form via JS and not a standard form submit, it looks like they recommend that you call this function to save form details

Not only in Chrome, also in Safari on iOS, rather annoying especially for mobile pages because mobile users do not want to login everytime they open the app. I tried setting the name attributes as suggested above, this did not work on iOS safari. I use LastPass on Chrome, which does recognize the login form. I double checked: when using the default login.html, all browsers ask to save the user/idpassword.

Could you check if this possible fixed version will work? It's a bit of a long shot. I have looked into it and come up with a possible fix, I will keep @Da-Dude fix in mind (haven't tested it yet). Love to hear your feedback. This version does remember my password in Firefox, in Chrome it's less stable, but that might be the test-project I'm working in.

Tested in IE and it asks if I want to save the password as well :-)

It works on iOS Safari and that is where I needed it most. Also works on Chrome. Lastpass starts asking me again whether I want to save the password. Speedy Jelte rides again!

Thanks for testing. As I have tested it in IE as well, I'm confident that this fixes the other issue as well. Will be updating this widget today in the AppStore

Fixed in 3.4.0, will be updated in the AppStore today


GeoAnalytics Server Role

I'm setting up an all-in-one ArcGIS Enterprise + GeoAnalytics Server.  First I run InstallLicenseConfigure for a 10.7 Enterprise Base then a second InstallLicenseConfigure for GeoAnalytics Server.  In the Enterprise Server settings there is no Feature Analysis (GeoAnalytics Tools) selected.  I need to select the hosting server from the drop-down and save before the site is ready.

Hello @bweisberg,
Is the Base ArcGIS Enterprise and GeoAnalytics server all on the same node? Perhaps you could share your role json files?
Thanks,
Cameron

Hi @cameronkroeker
Yes, all on the same node.  The base deployment and geoanalytics json files are attached in the zip.
rolejson.zip

@bweisberg
I suspect the issue is that the Hosting server and GeoAnalytics server reside on the same node. This isn't a recommended workflow.
"It is recommended that you install GeoAnalytics Server on a separate machine than those used by the rest of your ArcGIS Enterprise deployment. This workload separation ensures that the distributed computing framework does not compete with other resources on your machines used for other operations."
Additionally, even though the Spatiotemoral Data Store is registered with the hosting server, it should also be on its own node as well.

closing due to inactivity.


Sending PN to specific user(s)

Hello, thank you for this awesome module (if I can call it so).
I've set up it successfully and can receive notifications, however, what I'm not figuring out is that how to target a specific user (or users) to send them a notification?
Presumably, I think I'd modify the table to include a unique ID column, but how can I call the desired functions to send PNs WHERE unique ID matches my needs?
Thank you.

Hi there,
sorry that I am only now writing - but I was heavily involved in other areas and could only now devote myself to the problem described.
To be able to send notifications to one or more selected users, three extensions or steps are required:

In order for a user ID to be saved at all, it must first be transferred from the client side when subscribing (only the client itself can 'know who he is') - I will explain this problem in more detail below!
As you have already written, the table (and thus the data provider) in which the subscriptions are stored must of course be supplemented with an additional data field for the user ID to assign this subscription to an specific user. The ID will be passed in first step in the same way, the userAgent is passed so far.

a new data provider class based on one of the two contained in the package should be created and used.

In order to finally send a notification to one or more selected users, the corresponding data records must be selected accordingly and transferred to the PNServer class.

For this purpose, either a new class can be created that extends PNServer and implements an additional loadSubscriptionsEx($userID) method or the desired subscription(s) can be transferred to a PNServer object in a loop using addSubscription()
If only a single notification is to be sent, the (new!) method pushSingle() from PNServer can also be used directly.

Extending the client script to transfer an (existing) user ID.
Since the service worker runs in a separate thread in the browser that does not have access to the currently active page (or its DOM), the process of subscribing has to be slightly modified in order to pass the user ID (or any further data) to the service worker before it subscribes to the push notifications.
In the current code example, the service worker subscribes to the push notifications immediately upon activation and the returned information is then sent directly to the server for storage. This means that it is not possible to pass additional data that can be sent to the server for storage together with the subscription information.
To pass data before subscribing, this call at last must be made later:
Calling the subscription is moved from the handler for the 'activate' event into the handler of the 'message' event. This event have to be triggered manuall by the client by calling postMessage(...), whereby it is possible to pass any data object. In the handler for this event, the passed data have to be saved locally so that it can be transferred to the server for storage after the subscription has been made.
Since these changes are a bit more complex, I have them implemented in the following sample scripts:

PNClientEx.js
PNServiceWorkerEx.js
PNTestClientEx.html

... it should be noted that these are sample scripts that I didn't have too much time to test for ...
The server-side changes/extensions should be feasible according to the comments above ;-)


config: fix panic in type assertion

when use shim v2 interface to run container, no need to use kata-proxy
and kata-shim, remove kata-proxy and kata-shim in config file will cause
panic since type assertion. add check to avoid panic
Fixes: #1440
Signed-off-by: Ace-Tang<EMAIL_ADDRESS>

/test

/retest

/test


Update branding to 3.1.0-preview2

@SteveSandersonMS why merge this despite the blocked label❔

Will revert until this repo has branched…

Sorry @dougbu - my mistake. Thanks for reverting.


⚠ Bofrost.at has degraded performance

In 6d9078a, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 2114 ms

Resolved: Bofrost.at performance has improved in 1e63d95.


Slow add_actions.to_pydict for tables with large number of columns, impacting read performance

Environment
Delta-rs version:

pip show deltalake
Name: deltalake
Version: 0.18.1
Summary: Native Delta Lake Python binding based on delta-rs with Pandas integration

Binding:  Python

OS: Ubuntu, MacOS

Bug
What happened: Slow add_actions.to_pydict() for large numbers of columns.
What you expected to happen: same info faster
How to reproduce it:
df = pd.DataFrame(np.random.random(size=(4000, 40000)))
deltalake.write_deltalake("table", df)
add_actions = deltalake.DeltaTable("table").get_add_actions()

start = time.time()
add_actions.to_pydict()
print("duration", time.time() - start)

On some azure instances I see ~27 seconds. On my M2 mac performance is better at ~9 seconds, but this still seems slow.
More details:
This seems unusually slow, and also impacts deltalake read operations here.

@xbrianh it's mainly slow because .to_pydict moves all values of the RecordBatch in a python dict. Due to wide amount of cols, you also get a lot of unnecessary stuff.
I've pushed a PR to fix this


make test fails

bin/test.sh: line 26: cd: /usr/local/google/home/howardjohn/go/src/istio.io/istio: No such file or directory
Istio is going into /usr/local/google/home/howardjohn/go/src/istio.io instead of /usr/local/google/home/howardjohn/go/src/istio.io/istio it looks like from investigating with kind-shell.
Will investigate more later

From the docs: https://docs.docker.com/engine/reference/commandline/cp/

DEST_PATH does not exist
DEST_PATH is created as a directory and the contents of the source directory are copied into this directory


Getting the exact number of frames from a stream

Hi There !
We're investigating how to handle loading wav files whose size - as declared in the RIFF header - is incorrect and a lot larger than the data actually contained in the file.
In such cases, we would like to crop the sound to the actual data and ideally, be able to determine the exact size without having to read the whole file upfront.
As expected, ifstream::num_frames will return the value read in the header.
However, the documentation states:
num_frames may differ from the actual number of frames in the stream
as this information relies on the codec. The only way to obtain the exact
number of frames is by seeking to the end of stream and retrieving the frame position.

So, we're trying to use ifstream::frame_tellg but it seems to return the same value as num_frame.
Here's an example code that evaluates the number of frame using num_frames, frame_seekg and by reading the data,.
  // Build a ifstream
  const auto filePath = makeTestFilePath("BB3_100_drum_break_paprika.wav");
  auto stream = audio::ifstream{filePath.string()};

  // Get the number of frames reported
  const auto reportedFrameNum = stream.info().num_frames();

  // Position the stream at the end
  stream.frame_seekg(0, std::ios_base::end);
  const auto seekedNumFrame = size_t(stream.frame_tellg());

  // Read the data until exhaustion to get the actual data contained in the file
  const auto dataFrameNum = [&]() {

    stream.frame_seekg(0, std::ios_base::beg);
    size_t frameCount{0};

    constexpr std::size_t kNiMediaReadChunkSize = 4096 / sizeof(float);
    const auto samplesPerChunk =
      std::min<std::size_t>(kNiMediaReadChunkSize, reportedFrameNum);
    std::vector<float> data(samplesPerChunk * stream.info().num_channels(), 0.0f);

    while (stream.read((char*)data.data(), std::streamsize(samplesPerChunk)))
    {
      frameCount += stream.frame_gcount();
    }

    return frameCount;
  }();

  std::cout << "Number of frames returning by num_frames " << reportedFrameNum
            << std::endl;
  std::cout << "Number of frames in the file " << dataFrameNum << std::endl;
  std::cout << "Number of frames from seeking " << seekedNumFrame << std::endl;

  CHECK(seekedNumFrame == dataFrameNum);

The output will be
Number of frames returning by num_frames 423360
Number of frames in the file 98090
Number of frames from seeking 423360

our expectation would be that seeking would also return 98090.
Is this the api we're supposed to use ? is there another way ?
Cheers.
PS: Here's the file this test was ran with BB3_100_drum_break_paprika.zip

I looked into this. It seems that indeed using seekg and tellg doesn't provide different information that num_frames.
The reason is that the subview_device used in wav_source and other sources to create a stream view on the data portion of the file trusts that the provided view end position is accurate. It doesn't check if it is located past the end of the file. To my understanding, at least on Windows, the internal call to SetFilePointer will also allow moving the pointer past the end of file and the consecutive tellg will simply return the pointer offset.
I think it's interesting that ni-media allows loading wav files which proclaim they are longer than they actually are. So I would expect some file size check to ensure the RIFF and data chunk lengths are valid and an exception if not.


Runtime errors potentially due to incomplete pattern desugaring in switch statements

The following tests started surfacing runtime errors after the switch-pattern desugaring was partially introduced. It's most likely that the incomplete desugaring is the root of the issue, and it will be resolved eventually as desugaring becomes more complete.

co19/LanguageFeatures/Patterns/list_A01_t02 (additionally, possibly 'records' not enabled on dart2js tests)
co19/LanguageFeatures/Patterns/logical_and_A06_t01
co19/LanguageFeatures/Patterns/logical_or_A02_t02
co19/LanguageFeatures/Patterns/logical_or_A05_t01
co19/LanguageFeatures/Patterns/wildcards_A01_t04

The error was encountered during work on https://dart-review.googlesource.com/c/sdk/+/276524.
This issue is assigned label area-front-end tentatively, and it needs further investigation, and possibly reassignment of the tags.

I can confirm that the following tests fail because Object pattern is not implemented yet:
co19/LanguageFeatures/Patterns/list_A01_t02
co19/LanguageFeatures/Patterns/logical_and_A06_t01
co19/LanguageFeatures/Patterns/logical_or_A05_t01
co19/LanguageFeatures/Patterns/wildcards_A01_t04

co19/LanguageFeatures/Patterns/logical_or_A02_t02 fails for another reason: https://github.com/dart-lang/sdk/issues/50797.

More of the failing tests for the same reason.

tests/co19/src/LanguageFeatures/Patterns/list_A04_t05.dart
co19/LanguageFeatures/Patterns/record_A01_t01
co19/LanguageFeatures/Patterns/record_A01_t02
co19/LanguageFeatures/Patterns/record_A01_t03
co19/LanguageFeatures/Patterns/record_A01_t04

These are detected by the try bots on the following CL: https://dart-review.googlesource.com/c/sdk/+/276940.

More of the failing tests:

co19/LanguageFeatures/Patterns/list_A01_t04
co19/LanguageFeatures/Patterns/record_A02_t02
co19/LanguageFeatures/Patterns/record_A02_t03
co19/LanguageFeatures/Patterns/record_A02_t04
co19/LanguageFeatures/Patterns/record_A03_t01
co19/LanguageFeatures/Patterns/record_A04_t01
co19/LanguageFeatures/Patterns/record_A02_t08
co19/LanguageFeatures/Patterns/map_A05_t01

An example of the stack trace is as follows:
Unhandled exception:
  Crash when compiling file:///b/s/w/ir/tests/co19/src/LanguageFeatures/Patterns/list_A01_t04.dart at character offset 1070:
UnimplementedError: TODO(paulberry)

#0      SharedTypeAnalyzerErrors.patternTypeMismatchInIrrefutableContext (package:front_end/src/fasta/type_inference/shared_type_analyzer.dart:94:5)
#1      TypeAnalyzer.analyzeDeclaredVariablePattern (package:_fe_analyzer_shared/src/type_inference/type_analyzer.dart:386:15)
#2      InferenceVisitorImpl.visitVariablePattern (package:front_end/src/fasta/type_inference/inference_visitor.dart:9102:29)
#3      VariablePattern.acceptInference (package:front_end/src/fasta/kernel/internal_ast.dart:5547:20)
#4      InferenceVisitorImpl.visitListPattern (package:front_end/src/fasta/type_inference/inference_visitor.dart:9201:15)
#5      ListPattern.acceptInference (package:front_end/src/fasta/kernel/internal_ast.dart:4371:20)
#6      InferenceVisitorImpl.dispatchPattern (package:front_end/src/fasta/type_inference/inference_visitor.dart:8873:12)
#7      TypeAnalyzer.analyzePatternVariableDeclarationStatement (package:_fe_analyzer_shared/src/type_inference/type_analyzer.dart:1042:5)
#8      InferenceVisitorImpl.visitPatternVariableDeclaration (package:front_end/src/fasta/type_inference/inference_visitor.dart:8268:5)
#9      PatternVariableDeclaration.acceptInference (package:front_end/src/fasta/kernel/internal_ast.dart:5029:20)
#10     InferenceVisitorImpl.inferStatement (package:front_end/src/fasta/type_inference/inference_visitor.dart:157:26)
#11     InferenceVisitorImpl._visitStatements (package:front_end/src/fasta/type_inference/inference_visitor.dart:741:50)
#12     InferenceVisitorImpl.visitBlock (package:front_end/src/fasta/type_inference/inference_visitor.dart:762:31)
#13     Block.accept (package:kernel/ast.dart:9694:43)

/cc @stereotype441

One more example:

co19/LanguageFeatures/Patterns/wildcards_A01_t01

More of the test failing due to the pattern desugaring being incomplete:

co19/LanguageFeatures/Patterns/map_A04_t02
co19/LanguageFeatures/Patterns/map_A05_t01
co19/LanguageFeatures/Patterns/object_A01_t01
co19/LanguageFeatures/Patterns/object_A02_t01
co19/LanguageFeatures/Patterns/record_A01_t07
co19/LanguageFeatures/Patterns/record_A01_t08
co19/LanguageFeatures/Patterns/variable_A02_t01
co19/LanguageFeatures/Patterns/variable_A02_t03
co19/LanguageFeatures/Patterns/variable_A02_t04
co19/LanguageFeatures/Patterns/variable_A02_t06

One of the tests tracked in this issue fails with a missed compile-time error, and all other pass. I'm closing this issue.


not able to load the home page after edit - https://www.nutanix.dev/api_references/move/#/7YItQxTyEW-Kth0rDHd2s-index

Context
I edited the home page and published it. now I am unable to load the index.md on our portal.
Current Behavior

Expected Behavior

Possible Workaround/Solution

Steps to Reproduce

Environment

Version used:
Environment name and version (e.g. Chrome 39, node.js 5.4):
Operating System and version (desktop or mobile):
Link to your environment/workspace/project:

@smitabh84
https://www.nutanix.dev/api_references/move/#/ZG9jOjQ1Mg-index
This seems to be the correct link and it loads fine. Anything we are missing here?

Not sure what made it work. thanks anyways.


transfer chunks of data

Hi,
have you thought about transfer chunks of data instead of bytes  for a full screen update ?
https://github.com/noopkat/oled-js/blob/master/oled.js#L398
What do you think ?

I expect this to be much faster as updating dirty bytes

https://github.com/MaBecker/oled-i2c-bus/commit/c099f6145024ea9b7c190d16a936eba45232e2a8

@MaBecker hi! Thanks for the suggestion. Would you mind explaining this technique in a bit more detail, and how it differs to this here, which finds the smallest chunk area to update (so that the 7 byte header is only sent once overall)?
I'm sure it's faster as you're telling me it is, I'm just not quite grokking the concept from the code alone. Thanks! 😁

@MaBecker it looks like perhaps it saves on the repetitive firmata I2C calls? That's my best understanding, it's been a while since I wrote this library hehe

Hi @noopkat,
sure - let me try ;-)
so first of all I use all call with sync = false to avoid   this._updateDirtyBytes(this.dirtyBytes);
because this does a byte by byte update of all the changes in buffer.
The big thing is to send the complete buffer with 8 calls of 128 bytes to the oled and not with 1024 calls of 1 byte.
So a total update is even fast as a update of dirty bytes.
please let me know if you need more information.

Hi, I did this in my fork of a fork of this library and it's indeed MUCH faster. I was using the C++ library to access the display before and was a bit shocked by how slow the JS library was so I investigated.
https://github.com/normen/oled_ssd1306_i2c

that's so interesting! I have always tested this library with an Arduino Micro also 🤔  What is the largest chunk size you're able to successfully send using my version of this library rather than any forks (if you just quickly change the chunk size in my source)?

Sorry, the fork I am using is running on RasPi completely, using the i2c library to access the displays via the RasPis GPIOs so I can't test your code. However, the C library I am using for Arduino and RasPi seems to send 16 bytes per package:
https://github.com/normen/ArduiPi_OLED/blob/4119148b051a6975816de2319eb6d11f6769499d/ArduiPi_OLED.cpp#L943
With my modified version for your JS library on RasPi-I2C I can send 32 bytes per package at 600kHz without issues. With the C library I do get the occasional hiccup when writing a lot at 600kHz - it does seem to push the data yet a bit faster for some reason. But with that I already get pretty much fluent animations at 100kHz.

ah! I see. Yes this is definitely not an apples to apples comparison. This library was originally designed for Johnny-Five specifically which uses Firmata protocol. Firmata running on the board is probably the main bottleneck when using my library (it's almost the full 32kb in size), and combined with the emulated USB connection there's going to be issues. This is why I was super conservative after noticing problems with chunk size initially 😄

I was just wondering because you seem to have a reason to pin the issue to the data transfer to the OLED - and I saw these little things handle more data that I expected. In my experience data transfer issues are hardware issues more often than not so maybe a few caps around the data transfer lines could make the appropriate bug fix? :)

Alright, I see. My impression was mainly coming from how the JS code for the OLED is laid out - the error check and always sending one byte at a time. That looked like there was issues being solved in the past :) As said I am using a fork of your code and have really no idea of this johnny-five related setup. So my perspective is pretty much solely the JS code and while I was looking into getting this change in as far upstream as possible I found this issue.
So yeah, broadening my view to all of that I suppose your problem could be anything ;P

thanks for getting in touch about it all the same. I'll consider implementing the dynamic chunk size option in the API but as far as my tests go not many will be able to make use of this feature given the nature of how this is integrated.


Ability to create nested group

It would be nice to make sub groups to gain clarity and segmentation.
I did not find any existing ticket on this idea.
Thx Pierre.

I think there is a ticket talking about tag somewhere, that's a better alteernative to subgroup.


How to make it work using CRNA Template?

Hi, newbie in react native here.
I'm sure your plugin works great when installed on a non-CRNA installation, but I have an app made up of CRNA, I was wondering if your plugin currently supports it?
I've tried installing your plugin on my CRNA app, but i'm getting undefined is not an object (evaluating 'imagepickermanager....
I couldn't do your manual installation steps from the README.MD because CRNA template doesn't have  android and ios folders.

+1


MAINT: io: Change the encoding comment of test_mio.py to utf-8.

The file test_mio.py had a comment indicating that its encoding
was latin-1.  The only non-ASCII character in the file is ö (in
the string 'Schrödinger').  Inspection of the raw bytes of this
file shows that this character is represented as the two byte
sequence 0xC3 0xB6, which is the UTF-8 encoding of ö. Apparently
the encoding of the file is actually UTF-8, not latin-1, so the
coding comment is changed accordingly.

Oops... in order for this PR to pass the lint check, the file test_mio.py still needs an explicit encoding comment that sets the encoding to UTF-8.  I updated the PR with that change.   If https://github.com/scipy/scipy/pull/12393 (or something like it) is merged, we can then do a clean up of all the redundant coding comments that specify UTF-8 encoding.

Only test failure is the old 60 minute timeout.

Thanks @WarrenWeckesser


Is it possible to use s2i with docker-compose?

Is it possible to create a service in docker-compose that build the image with s2i script?

I'm not familiar w/ the docker-compose service component, but in general s2i requires the docker socket be available to the context in which it is invoked.  As long as it is, you can use it (so for example you can start a container that contains the s2i binary and bind-mount your host's docker socket into that container.  That container can then invoke the s2i binary to perform an image build (and if it wants, also push the output image somewhere).  That's effectively how openshift s2i builds work.

@luiscoms , if your mind contains this idea #1063  , please vote there.


2591  - Update base SPO Command to show an error when AuthType is secret

#2591  - Update base SPO Command to show an error when AuthType is secret

The implementation verifies the authType in SpoCommand and calls the base action if authType is not secret - to keep the existing implementation unchanged. If the authType is secret, an error is displayed.

Thank you for a quick turnaround @vipulkelkar! We're in a feature lock pending the upcoming release. We'll start reviewing PRs after the release this week. 👍

Merged manually. Thank you! 🚀


Smoke test

Coverage decreased (-0.6%) to 89.427% when pulling b585f75eb9c8f5c526c5f96791f4491112305dfc on SAP:smoke_test into 657dc24b07d34d3e7c38ff9b592ffcf815df9df4 on cloudfoundry-incubator:master.

Coverage decreased (-0.6%) to 89.427% when pulling 7cfd3bdae0b20942c007fbb5c042219811179c09 on SAP:smoke_test into 657dc24b07d34d3e7c38ff9b592ffcf815df9df4 on cloudfoundry-incubator:master.

Coverage decreased (-0.6%) to 89.427% when pulling 7cfd3bdae0b20942c007fbb5c042219811179c09 on SAP:smoke_test into 657dc24b07d34d3e7c38ff9b592ffcf815df9df4 on cloudfoundry-incubator:master.

Coverage decreased (-0.6%) to 89.427% when pulling b108196631364f851afcd529a1369c474b65d258 on SAP:smoke_test into 657dc24b07d34d3e7c38ff9b592ffcf815df9df4 on cloudfoundry-incubator:master.

Coverage decreased (-0.6%) to 89.427% when pulling 9b8558aa3a61b71d005795246d156b604faa81b1 on SAP:smoke_test into 657dc24b07d34d3e7c38ff9b592ffcf815df9df4 on cloudfoundry-incubator:master.

Coverage decreased (-0.7%) to 89.369% when pulling 05d19df7c28d51e63a12311d7421bf22dae6e4cd on SAP:smoke_test into 657dc24b07d34d3e7c38ff9b592ffcf815df9df4 on cloudfoundry-incubator:master.


[WIP] Navigation Preferences

Description

added NavigationPreferences Model
added NavigationPreferencesView

Related Issue

#371

Checklist

[x] I read and understood the contributing guide as well as the code of conduct
[x] My changes generate no new warnings
[x] My code builds and runs on my machine
[x] I documented my code
[x] Review requested

Screenshots

CodeEdit
Xcode

Maybe convert this to a draft PR?

@aaryankotharii How is this coming along? Let me know if you need anything.

@aaryankotharii How close is this to being complete? Are you able to wrap this up? If not let me know so someone else can.


US_4.3: Email to participants

As organizer I want to send a bulk mail to all participants of an event in order to avoid coping the email addresses.

Dependency: Event, Role Organizer, Role Pupil

Additional details: The sender of the Email can be a single person (e.g<EMAIL_ADDRESS>or a mailing list (e.g. mintcamp2016@hpi.de). Please ensure, that this will not lead to access violation and discuss your solution with the HPI admins and my team.


latest SciTE v5.3.0 not working with scintillua 5.3 (Windows)

Hi,
Thanks for Scintillua!
SciTE v5.3.0 seems to have broken something?
SciTE v5.2.4 & Scintillua v5.3 worked together perfectly.
before,

after (simply updating SciTE.exe, Scintilla.dll & Lexilla.dll),

I'm using SciTE 64bit on Windows 8.1.
best regards,
Rafael.

Scintillua is currently in a transition period. I submitted some changes for SciTE 5.3.0 that are incompatible with Scintillua 5.x. When Scintillua 6.0 is released, which I hope will be soon, it will work with SciTE 5.3.0. Sorry for the inconvience :(

@orbitalquark
Thanks for the update.
That's great news.
Thanks again for the awesome work on Scintillua.
All the best,
Rafael.

Scintillua 6.0 has been released and should work with SciTE. Please see the updated manual with instructions how to use the new version. It is quite different from the previous version, such as when it comes to themes. (Lua themes have been replaced by SciTE-style properties files.)


adding support for qubitplaceholders to pragmas

Fixes #439.

Everything addressed, tests all tucked into their files. @ntezak @mpharrigan @stevenheidel

@mpharrigan @stevenheidel @ntezak Is this good to go? Can we merge? (I don't have permission.)

In the future, add it as a new commit so I can just see the one change :)


No reliable function to access MAC address of the device itself

I want to name by device based on its MAC Address, as I plan to have multiple devices and I wanted to differentiate between them. For example, an ESP with addr: 43:5A:12:03:fA:65:02 would have myDevice 6502 as its BLE device name.
The examples I found on the internet only do this by first advertising, then scanning, and then getting the MAC address from the scanned data. That would work okay if there was only 1 BLE device in the area. But in case there are multiple devices, there's a change that a different BLE device's address will get scanned.
Can I not access the MAC Address without starting the advertisement? Is there a way to add it to the library?

You can get the device address with NimBLEDevice::getAddress.

    uint8_t mac[6] = {};
    esp_read_mac(mac, ESP_MAC_BT);

All you have to do is to convert hex values to chars.

Thanks!
NimBLEAddress addr = NimBLEDevice::getAddress();
const uint8_t *addrs = addr.getNative();
String name = "myDevice " + String((addrs[4]<<8)|(addrs[5]), HEX);
NimBLEDevice::init(name.c_str());

This is how I'm doing it. The code is untested right now, but I just wanted to know if this is anywhere near how it should be.

This is the final code snippet that has been tested:
  NimBLEDevice::init("X");
  NimBLEAddress addr = NimBLEDevice::getAddress();
  const uint8_t *addrs = addr.getNative();
  char name[15];
  sprintf(name, "myDevice %X\n", (addrs[1] << 8) | (addrs[0]));
  NimBLEDevice::setDeviceName(name);

Some things to note:

I wasn't able to access Mac address if the BLE stack wasn't initialized. That's why I did the first init with a random name, and then changed the name later on.
The getNative() function writes Right-Most Byte(idk if I can call it LSB) at index 0. I wanted the name to be myDevice EEFF if my MAC Address was AA:BB:CC:DD:EE:FF, but addrs[4] and addrs[5] returned BB and AA respectively. So, I changed it index to 1 and 0.
I'm pretty sure it can be made even better with some more optimizations.

Thanks for the update, glad it's working for you 😄


bubble mutationObserver options up to modifier

It's very easy to accidentally create an infinite loop that crashes the browser because by default you're observing the entire tree.
<div {{create-ref "outer" bucket=this tracked=true}}>
  <div style={{this.style}}/>
</div>

@trackedRef("outer") _outer;

get style() {
  return htmlSafe(`font-height:${this._outer.clientHeight}px`);
}

Default should be to only monitor the element that has the modifier. Options should be provided:

subtree: false - this is the expensive one
children: false
attributes: true
resize: true

@BryanCrotaz agree, I was thinking about config hash, to allow users customize obervers flags

that's complex to write in the template, I'd prefer optional attributes on the modifier directly

{{create-tracked-ref "mine" children=true}}
And there's a warning if you try and use them with tracking=false ("did you mean to turn tracking on?")

plus the observer options include old attribute values which aren't accessible through the modifier, so that might get confusing

implemented in<EMAIL_ADDRESS>