Add ponzu generate myfield:"xml"

This would add a new field type "xml". This could configure the field to use editor.Richtext, and install by default some additional markup-friendly editor features, plus the ability to specify XML validation.
I see that nilslice/summernote uses Codemirror(.net), so I guess Codemirror is used for ponzu richtext codeview mode (the "<>" button) ? So all the features & options that Codemirror offers are in principle available for ponzu richedit in codeview mode, and maybe in non-codeview mode too ?

Hi @fbaube -
Could you elaborate on how this would be used? Or, how does myfield:"string" and using the editor.Richtext doesn't already satisfy any requirements since you can put markup directly in the code view "<>", as you mentioned. You can add markup directly in the editor.Textarea function as well, but be mindful of how it is escaped.
I don't know if all the codemirror features/options are available, but if you test for a specific one and find that it is not available, let me know!

I'm just thinking, specialised modes in editors always add nice functionalities. Codemirror has http://codemirror.net/mode/xml/
Schema-guided autocomplete is demo'd in https://codemirror.net/demo/xmlcomplete.html ; after you type "<" and select a tag, typing a space offers attributes.
I'd like to use this functionality for DITA. DITA has schemata in DTD, RNG, and XSD.
Unfortunately I've never actually configured Codemirror myself, so I have no idea how to proceed....

Hi @fbaube - sorry for the delay, I must've missed the notification.
So just to be clear, you're looking to gain auto complete in the code view mode of the richtext editor?
I agree that this would be useful to add/edit markup, but I'm not as sure about adding a CLI specifier would be necessary. It should just be available in that mode by default IMO.
Unfortunately, the codemirror configuration is likely buried within the "materialnote" library I use to instantiate the richtext editor, and I'm not as familiar with its codebase as I probably should be. I will take a look at it though and let you know what i find.

Autocomplete is the most desirable feature add, altho Codemirror has other XML enhancements too. I skimmed the Materialnote website and yes, it's a layer of complication if the goal is to directly tinker with Codemirror. But anything you can discover would be great !
I could provide a simplified version of the LwDITA DTD for testing purposes. The inline elements are much like HTML5; the block elements would be mostly new. There are additional attributes for things like links.

Ok, thank you for clarification. I have added this as a suggested feature and will do my best to get it started. I created a Community Suggested Features project where I try to lay out a rough road map of whats to come, and what is in planning or development, so that anyone can come check out ideas to contribute if they would like.
I would love to get a PR for this, since admittedly the XML stuff is a bit outside my domain. If you'd like to work on it, let me know and I'll happily help get you started.
Since this feature is added to the project above, I will close out this issue for the time being. Feel free to join the #ponzu slack channel in the Gophers organization here: https://invite.slack.golangbridge.org and we can discuss further.
Thanks,
Steve

DITA uses Relax NG for its master grammars, and specializations of DITA (which are encouraged) should be based on the RNG grammar. FWIW I found a codemirror derivative called "xmlmirror" ( https://lastlog.de/blog/posts/xmlmirror.html ) that claims to do schema-driven editing, including RNG-driven. Unfortunately xmlmirror's dependencies are very complex and it failed to install. But I'll keep looking around.
 But I'll leave notes here on this issue.)

Thanks! I will keep an eye on this too. I'm planning to dedicate more time over the next couple weeks to these types of issues.

Now that I have found the RNGs for LwDITA (Lightweight DITA) I think I'll simply take a page in ponzu where the text edit widget works and then experiment with it until I get codemirror's XML functionality working.

Sounds good. Let me know if you run into any issues -- I will admit, that code is a little messy :smile:


Hooks

Definitions
Anchor Point: a point in the program where a hook can be set.
Hook: A PHP class which is called at a certain point in the Program.
What is a Hook?
A hook is a class that will be called at a certain point of the program's flow. Using this, devs can for example log the generated response into the database or alter it in other ways.
What anchor points are there?
These are still subject to change and therefore non-final

PreFindRoute
PostFindRoute
PreCallFunction
PostCallFunction (give returned response)
PrePrintResponse
PostPrintResponse

How?
There will be a 'HookInterface' Interface. All hooks that are added to the configuration need to extend this. This contains one function, call().
Additionally, every anchor point has it's own hook interface, so for example, the 3 point PreCallFunction has the interface PreCallFunctionHookInterface. this is how the anchor point of a hook is defined

Optionally, there could be support for "dynamic" hooks, meaning devs can create their own hooks. Though I am not yet clear on how they will be called


The source directory "/home/dep" does not appear to contain CMakeLists.txt. please quote a solution

    The standard `cmake` technique is to add the location of `librealsense` to your `CMAKE_PREFIX_PATH` with something like this (run in your build directory):

cmake -DCMAKE_PREFIX_PATH="C:\Program Files (x86)\Intel RealSense SDK 2.0" .

and then to ask cmake to find librealsense using that path in your CMakeLists.txt like so
find_package(realsense2)

target_link_libraries(${PROJECT_NAME} PRIVATE realsense2::realsense2)

this should deal with the include paths, finding the DLL, etc. automatically.
Originally posted by @radfordi in https://github.com/IntelRealSense/librealsense/issues/4277#issuecomment-505242118

E: Unable to locate package librealsense2-dkms
Please suggest solutions for it

Hi @Sashraa  As you are quoting https://github.com/IntelRealSense/librealsense/issues/4277#issuecomment-505242118 it sounds as though you are attempting to compile a project that you have created yourself.  Is that correct, please?
If it is then the Getting Started project at the link below may be a helpful reference.
https://github.com/zivsha/librealsense/tree/getting_started_example/examples/getting-started
It is the rs-hello-realsense RealSense SDK example program but with a more complex CMakeLists.txt file that has the instructions mentioned in https://github.com/IntelRealSense/librealsense/issues/4277#issuecomment-505242118 that enable the project to find the RealSense libraries.

In regard to the error E: Unable to locate package librealsense2-dkms - were you attempting to install the librealsense SDK when this error occurred?  If you were then what installation instructions were you following, please?

Hi @Sashraa As you are quoting #4277 (comment) it sounds as though you are attempting to compile a project that you have created yourself. Is that correct, please?
If it is then the Getting Started project at the link below may be a helpful reference.
https://github.com/zivsha/librealsense/tree/getting_started_example/examples/getting-started
It is the rs-hello-realsense RealSense SDK example program but with a more complex CMakeLists.txt file that has the instructions that enable the project to find the RealSense libraries and build the project as a standalone executable.
Can you confirm please whether you are using Windows or Linux? The quoted prefix path cmake -DCMAKE_PREFIX_PATH="C:\Program Files (x86)\Intel RealSense SDK 2.0" is for a folder location on a Windows computer. The title of the issue about /home/dep sounds as though you are using a Linux computer.

I have solved this one referring to your previous solutions
Thank you.

I am not able to access opencv I installed in the home directory.. Kindly suggest links for installing opencv in the correct manner.

thank you

Hi @Sashraa  Do you require further assistance with this case, please?  Thanks!

hello,
rs2::pipeline _pipe;
rs2::config _cfg;
_cfg.enable_stream(RS2_STREAM_COLOR, 640, 480, RS2_FORMAT_BGR8, 30);
_pipe.start(_cfg);
     rs2::frameset cframes=_pipe.wait_for_frames();

there is an error in the execution at this particular line: rs2::frameset cframes=_pipe.wait_for_frames();
wait_for_frames() seems to not work...kindly assist.

I have retrieved IR and depth frames in .png but I am not able to retrieve the color image due to the above issue.. kindly assist.

What is the error message that you receive, please?

it's simply an error...there are frames captured

if there are any methods to retrieve the color image ..kindly share

Does the script work if you do it like this:
rs2::frameset cframes;
   for(int i = 0; i < 30; i++)
   {

       cframes = _pipe.wait_for_frames();
   }

   rs2::frame color_frame = cframes.get_color_frame();

No, it doesn't work...I am using D410 sensor.
Can color image be retrieved in png format?

color image for gender classification

If you are using a D410 Depth Module Kit then it will not be equipped with an RGB sensor and so will not support the color stream format.
You could try obtaining RGB from the left infrared sensor though.
_cfg.enable_stream(RS2_STREAM_INFRARED, 640, 480, RS2_FORMAT_BGR8, 30);

Thanks a lot for your guidance...

The RealSense OpenVINO Toolkit wrapper for C++ supports object detection and gender / age detection in its Face and DNN examples.  However, both those examples use the color stream.  And because they use depth to color alignment, it does not seem to be practical to adapt them to use RGB from the infrared stream.
https://github.com/IntelRealSense/librealsense/tree/master/wrappers/openvino

Thank you.
Imshow doesn't work.. what do I do?

Are you using an OpenVINO example program that uses OpenCV, please (imshow is an OpenCV instruction).
https://github.com/IntelRealSense/librealsense/tree/master/wrappers/openvino#getting-started

no I am using opencv example only...

Thank you.  Which example are you using?

Th rs-align example

When you said "imshow doesn't work", do you mean the OpenCV imshow example.
https://github.com/IntelRealSense/librealsense/tree/master/wrappers/opencv/imshow
If you are using that example then it does not make use of color or infrared, only depth.  It color shades the depth coordinates and does not use any other type of stream.
But if you are trying to align depth to infrared then that will not work with these OpenCV examples.  This is because you can only use an alignment instruction to align the depth stream to the color stream, or the color stream to the depth stream.

okay..got it... Thank you soo much.

hello, I've installed the opencv v.4.6... what is the content I must add in the pkgconfig opencv.pc file?

Unable to init server: Could not connect: Connection refused
terminate called after throwing an instance of 'cv::Exception'
what():  OpenCV(4.6.0) /home/me/opencv/modules/highgui/src/window_gtk.cpp:635: error: (-2:Unspecified error) Can't initialize GTK backend in function 'cvInitSystem'
This is the error I get when I use imshow.
this is the code I used.
https://github.com/IntelRealSense/librealsense/blob/master/wrappers/opencv/imshow/rs-imshow.cpp

The answer at the link below seems to fit your situation with imshow.
https://www.reddit.com/r/opencv/comments/rb8z0q/bug_problems_with_opencv_and_raspberrypi_imshow/

thank you....
I've got an issue with the realsense viewer... This is the op I get...

It's not streaming... will there be streaming if I connect it to a monitor...? Is there an option to enable RGB in D410?

As you mention about whether it would work if you attached a monitor, this suggests to me that you are using a 'headless' computer setup that does not have a display.  Is that correct, please?
If you are using graphical examples and tools such as realsense-viewer then a display should be attached, otherwise there may be problems if your librealsense source-code build includes support for graphics (which it does by default) but a display is not attached.  In Intel's build configuration guidance (at the link below) it is recommended to include the build flag -DBUILD_GRAPHICAL_EXAMPLES=false in your CMake build instruction if your system is headless, though graphical tools such as realsense-viewer will not be installed as a consequence of doing so.
https://dev.intelrealsense.com/docs/build-configuration

If DBUILD_GRAPHICAL_EXAMPLES is false then graphicless text console tools and examples should still be built because the flag DBUILD_EXAMPLES is true by default.

yeah I am using headless...is this the reason for imshow not working?

Yes, I believe that it is expecting a display to be attached for a graphical function like imshow.

Hi @Sashraa  Do you require further assistance with this case, please?  Thanks!

Nope! Thank you soo much for your guidance.

You are very welcome, @Sashraa - thanks very much for the update!

Hello I am trying to create a Http server client communication...
while compiling my code.. I keep getting the below errors:
undefined references to `gstProxySettings

I cannot find any references to the term gstProxySettings.  What method are you using to set up your http connection please?

Hello,
I have been trying to install Librealsense through all the methods.. but it fails in the make.. I have tried the debian, RSUSB methods and the Libusb backend version in Banana Pi.
Kernel Version: 4.9.241-BPI-M5
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 11 (bullseye)
Release:        11
Codename:       bullseye
Is there support for Librealsense in BananaPi? or please suggest any other methods ..
Kindly support..
Thank You.

There are known problems with installing librealsense on Raspian Bullseye.  The previous version, Raspbian Buster, usually works better.
If you would prefer to use Bullseye, at https://github.com/IntelRealSense/librealsense/issues/9943#issuecomment-966048785 a RealSense user describes their method for adjusting Bullseye for librealsense compatibility by copying two binaries from Buster to Bullseye.

Thank you soo much...It is of a great help


Add support for Office 2019.

I'll have to wait until Microsoft releases the previews to support Office 2019 because I don't know what the version number or install folder will be. It's only supported on Windows 10, but I don't know if I'll have it only show up in the dropdown box in the Options window on Windows 10 and hide it on older Windows versions.

Office 2019 now officially supported in e9811fe!


Can you explain this part of code for traffic light detection

How this part of code help to detect stop sign and traffic light?
how height and width will be calculated?
for (x_pos, y_pos, width, height) in cascade_obj:
cv2.rectangle(image, (x_pos + 5, y_pos + 5), (x_pos + width - 5, y_pos + height - 5), (255, 255, 255), 2)
v = y_pos + height - 5
# print(x_pos+5, y_pos+5, x_pos+width-5, y_pos+height-5, width, height)
        # stop sign
        if width / height == 1:
            cv2.putText(image, 'STOP', (x_pos, y_pos - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.7, (0, 0, 255), 2)

        # traffic lights
        else:
            roi = gray_image[y_pos + 10:y_pos + height - 10, x_pos + 10:x_pos + width - 10]
            mask = cv2.GaussianBlur(roi, (25, 25), 0)
            (minVal, maxVal, minLoc, maxLoc) = cv2.minMaxLoc(mask)

            # check if light is on
            if maxVal - minVal > threshold:
                cv2.circle(roi, maxLoc, 5, (255, 0, 0), 2)

                # Red light
                if 1.0 / 8 * (height - 30) < maxLoc[1] < 4.0 / 8 * (height - 30):
                    cv2.putText(image, 'Red', (x_pos + 5, y_pos - 5), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 0, 255), 2)
                    self.red_light = True

                # Green light
                elif 5.5 / 8 * (height - 30) < maxLoc[1] < height - 30:
                    cv2.putText(image, 'Green', (x_pos + 5, y_pos - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 0),2)
                    self.green_light = True

                # yellow light
                # elif 4.0/8*(height-30) < maxLoc[1] < 5.5/8*(height-30):
                #    cv2.putText(image, 'Yellow', (x_pos+5, y_pos - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 255), 2)
                #    self.yellow_light = True

@Devanshice020
This "for loop" is used to draw bounding boxes for the detected object. The height, width along with x, y positions are returned by cascade_obj, with those you can draw a bounding box.
Because we used two cascade classifiers (stop sign and traffic light), and we also know the bounding box of stop sign is a square, traffic light is a rectangle (based on training data shape), so we can simply separate these two by calculating width/height, then put different texts on top of the box.

Then for traffic light I have to measure size of my traffic light box?

@Devanshice020 No need to measure, because there are only two objects, if width / height == 1 then it's a square, if not it's a rectangle.

I trained my own classifier for traffic light but when camera detects red or green light some times it detects and some times it does not detect. What changes should I do?
Should I change this part of code ?
check if light is on
        if maxVal - minVal > threshold:
            cv2.circle(roi, maxLoc, 5, (255, 0, 0), 2)

            # Red light
            if 1.0 / 8 * (height - 30) < maxLoc[1] < 4.0 / 8 * (height - 30):
                cv2.putText(image, 'Red', (x_pos + 5, y_pos - 5), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 0, 255), 2)
                self.red_light = True

            # Green light
            elif 5.5 / 8 * (height - 30) < maxLoc[1] < height - 30:
                cv2.putText(image, 'Green', (x_pos + 5, y_pos - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 0),2)
                self.green_light = True

            # yellow light
            # elif 4.0/8*(height-30) < maxLoc[1] < 5.5/8*(height-30):
            #    cv2.putText(image, 'Yellow', (x_pos+5, y_pos - 10), cv2.FONT_HERSHEY_SIMPLEX, 0.5, (0, 255, 255), 2)
            #    self.yellow_light = True

@Devanshice020 Not really, the code is just for adding text, if the classifier doesn't detect the object in the first place, there won't be a bounding box to draw.

Should I retrain my traffic_light_claassifier classifier ?
Is there any alternate option for classifying traffic light in windows?

This is a traffic light I have made plz help
Thanks in Advance

@Devanshice020 The traffic light classifier was trained only with images of that small toy you see in the video. I think you may give it a try to make the shape of your traffic light look like that toy, before training your own.


Add postinst to the released ZIP as well

Hello,
I try to install this layout in a Fedora based distro so I can't use deb or AUR.
Unfortunately, the zip filed is not enough to install this layout. I probably need to alter files in /usr/share/X11/xkb/rules/ like evdev.xml or such.
Is it possible to get any help or create a rpm package from the postinst file in the .deb file ?
Thanks.

I managed to get it working.
After unziping the zip file to / I extracted postinst from the deb file.
I then did in a terminal :
sudo ./postinst triggered

That did the trick.
Could be nice to add the script in the zip file and change instructions accordingly.

@r9r-dev Feel free to do a PR

Will do but can you then update the ci to package the rpm file ? Look like you don't use github actions to deploy your release.

@devnoname120 after searching on web, it look like there is an easy way to fix the issue. You can create an rpm package from a deb package in your deployment script
sudo apt install alien

after that, just run the command
sudo alien -r qwerty-fr_0.7.3_linux.deb --scripts

So, no need for a PR, just a command in your ci.

@r9r-dev In which repo are RPM packages usually stored? I don't want to maintain the Fedora package so I would rather have it be handled by an external packager just like it's already done on AUR.

You don't have to manage it, just add the line in your release/deployment script. I don't know which repositories to publish to be sure that every fedora based distro can use it. It doesn't work like AUR.
Furthermore, there can be quite a long time between the publication on a repo and its availability in the various distributions based on Fedora. Unfortunately, I don't have enough knowledge in the field to help.


remove some implicitly any

I am not sure what you are fixing here in particular, as these appear to be never[] and not any[]?

Also, I think if you wanted to change this, I think something like this (that doesn't use as type assertions) might be better:
const emptyRoleToPartyNames = (): Record<Role, string[]> => {
  return {
    tank: [],
    healer: [],
    dps: [],
    crafter: [],
    gatherer: [],
    none: [],
  };
};


Add linear and dynamic RoPE to Mistral and Mixtral

What does this PR do?

As per title.
Before submitting

[ ] This PR fixes a typo or improves the docs (you can dismiss the other checks if that's the case).
[ ] Did you make sure to update the documentation with your changes?
[ ] Did you write any new necessary tests?

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@regisss for the configuration, do we need to change the model card or let user to pass from cmd line? so we need to add arguments from run_generation?

We don't need to change the config.json. It will use regular RoPE by default. If users want linear or dynamic RoPE, they can modify the config of the model. That's exactly the same as with Llama so I don't think we should add any new argument.


I can't seem to post

I've done everything but now I can't post anything

give me a screenshot please


JSON communication working

For now just a heads-up that my vlime-repo has JSON communication working on the master branch.
That needs a few small changes to swank (see the slime repo here), I'll try to get them upstream.
Motivation:

No extra thread in the inferior lisp needed
Easier to port (eg. swankR could benefit)
Faster decoding than when decomposing S-expressions via vimscript
Much less (communication)-specific code (net diff is a reduction!)

Not entirely clean right now, TODO:

I need to define some prefix to know what is a string and what is a symbol across JSON; currently §§ is used. Better ideas?
Not sure whether auto-detect of encoding (( vs. [) will be accepted in upstream-swank.
swank needs cleanups.

Any discussion welcome, of course!

Quick update:

I am not sure when that happend, but yason changes have finally been published to Quicklisp, so there is no need to locally clone Philipp's fork anymore
slime changes on the other hand, still need to be merged upstream; @phmarek, how likely it is for these changes to land upstream? Is there anything we can do to help?
Looks like it's no more possible to start a Vlime server and have it connect to an already running Swank server: the :start-swank key argument disappeared; I will look into this over the following days, but do let me know if there was a specific reason as to why support for this was dropped

Looks like it's no more possible to start a Vlime server and have it connect to an already running Swank server:

Oh yes, this still works.
The swank/vlime connection switches to json communication without using a separate translator thread (with some associated TCP port).

@phmarek, is phmarek/slime@master and and phmarek/vlime@master still the way to go?  I am currently running into some problems when trying to make this work on a Ubuntu WSL2 machine.
Current version of Slime:
ubuntu at ... in ~/opt/slime/__main__ on phmarek-master
$ g ll -n1
66d13592 Sometimes the thread name is not simple? (Thu Jan 26 12:42:20 2023 +0100 by Philipp Marek) (HEAD -> phmarek-master, phmarek/master, origin/master, master)

Current version of Vlime:
ubuntu at ... in ~/opt/vlime/__main__ on phmarek-master
$ g ll -n1
25f7bf0 Highlight ***HERE*** and the snippet a bit in the SLDB buffer. (Fri Sep 2 08:36:32 2022 +0200 by Philipp Marek) (HEAD -> phmarek-master, phmarek/master)

This is the startup script I have been using for Vlime (do let me know if there is anything that looks suspicious):
sbcl \
    --eval '(pushnew #P"~/opt/slime/__main__/" asdf:*central-registry*)' \
    --load ~/opt/slime/__main__/swank-loader.lisp \
    --eval '(swank-loader:init :load-contribs t)' \
    --eval '(setq swank:*log-events* t)' \
    --load ~/opt/vlime/__main__/lisp/start-vlime.lisp

If I run it, I get a ton of warnings (see later), but ultimately I get a listening port:
$ bash start-vlime.sh
This is SBCL 2.3.8.nixos, an implementation of ANSI Common Lisp.
More information about SBCL is available at <http://www.sbcl.org/>.

SBCL is free software, provided as is, with absolutely no warranty.
It is mostly in the public domain; some portions are provided under
BSD-style licenses.  See the CREDITS and COPYING files in the
distribution for more information.
[...]
Server created: (<IP_ADDRESS> 7002)

All the startup warnings

WARNING:
   redefining EMACS-INSPECT (#) in DEFMETHOD
WARNING:
   redefining THREAD-FOR-EVALUATION (#
                                     #) in DEFMETHOD
WARNING: redefining SWANK-LOADER::Q in DEFUN
WARNING: redefining SWANK-LOADER::LISP-VERSION-STRING in DEFUN
WARNING: redefining SWANK-LOADER::UNIQUE-DIR-NAME in DEFUN
WARNING: redefining SWANK-LOADER::FILE-NEWER-P in DEFUN
WARNING: redefining SWANK-LOADER::STRING-STARTS-WITH in DEFUN
WARNING: redefining SWANK-LOADER::SLIME-VERSION-STRING in DEFUN
WARNING: redefining SWANK-LOADER::DEFAULT-FASL-DIR in DEFUN
WARNING: redefining SWANK-LOADER::BINARY-PATHNAME in DEFUN
WARNING: redefining SWANK-LOADER::HANDLE-SWANK-LOAD-ERROR in DEFUN
WARNING: redefining SWANK-LOADER::COMPILE-FILES in DEFUN
WARNING: redefining SWANK-LOADER::LOAD-USER-INIT-FILE in DEFUN
WARNING: redefining SWANK-LOADER::LOAD-SITE-INIT-FILE in DEFUN
WARNING: redefining SWANK-LOADER::SRC-FILES in DEFUN
WARNING: redefining SWANK-LOADER::APPEND-DIR in DEFUN
WARNING: redefining SWANK-LOADER::CONTRIB-DIR in DEFUN
WARNING: redefining SWANK-LOADER::LOAD-SWANK in DEFUN
WARNING: redefining SWANK-LOADER::DELETE-STALE-CONTRIB-FASL-FILES in DEFUN
WARNING: redefining SWANK-LOADER::COMPILE-CONTRIBS in DEFUN
WARNING: redefining SWANK-LOADER::LOADUP in DEFUN
WARNING: redefining SWANK-LOADER::SETUP in DEFUN
WARNING: redefining SWANK-LOADER::LIST-SWANK-PACKAGES in DEFUN
WARNING: redefining SWANK-LOADER::DELETE-PACKAGES in DEFUN
WARNING: redefining SWANK-LOADER:INIT in DEFUN
WARNING: redefining SWANK-LOADER:DUMP-IMAGE in DEFUN
WARNING: redefining SWANK-LOADER:LIST-FASLS in DEFUN
WARNING: SWANK/BACKEND also exports the following symbols:
  (SWANK/BACKEND:BACKGROUND-SAVE-IMAGE SWANK/BACKEND:FIND-EXTERNAL-FORMAT
                                       SWANK/BACKEND:UNWRAP
                                       SWANK/BACKEND:PACKAGE-LOCAL-NICKNAMES
                                       SWANK/BACKEND:FRAME-LOCALS
                                       SWANK/BACKEND:FRAME-CATCH-TAGS
                                       SWANK/BACKEND:FLOAT-NAN-P
                                       SWANK/BACKEND:PROFILE
                                       SWANK/BACKEND:GETPID
                                       SWANK/BACKEND:WHO-SPECIALIZES ...)
See also:
  The ANSI Standard, Macro DEFPACKAGE
  The SBCL Manual, Variable SB-EXT:*ON-PACKAGE-VARIANCE*
WARNING: SWANK also exports the following symbols:
  (SWANK:INSPECTOR-POP SWANK:RELOAD-SYSTEM SWANK:DELETE-SYSTEM-FASLS
                       SWANK:SLDB-RETURN-FROM-FRAME
                       SWANK:LIST-ALL-SYSTEMS-IN-CENTRAL-REGISTRY
                       SWANK:COMPILE-MULTIPLE-STRINGS-FOR-EMACS
                       SWANK:FRAME-LOCALS-AND-CATCH-TAGS SWANK:COMPLETIONS
                       SWANK:PACKAGE= SWANK:EXPORT-SYMBOL-FOR-EMACS ...)

If I then try to evaluate the following DEFUN, it all behaves as expected, i.e., the REPL buffer pops up, to inform me HELLO was the result of the last evaluation:
(defun hello ()
  (print "Hello!"))

Swank logs of the first DEFUN

dispatch-event: (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(defun hello ()
  (print \"Hello!\"))") "\"))" :REPL-THREAD 15)
send-event: # (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(defun hello ()
  (print \"Hello!\"))") "\"))" 15)
dispatch-event: (:PRESENTATION-START 1 :REPL-RESULT)
dispatch-event: (:PRESENTATION-START 1 :REPL-RESULT)
_) (:EMACS-CHANNEL-SEND . SWANK::_)) NIL
encode-message
dispatch-event: (:WRITE-STRING "HELLO" :REPL-RESULT)
encode-message
dispatch-event: (:PRESENTATION-END 1 :REPL-RESULT)
encode-message
dispatch-event: (:WRITE-STRING "
" :REPL-RESULT)
encode-message
dispatch-event: (:RETURN # (:OK NIL) 15)
encode-message

If I re-evaluate the same DEFUN again, I do get on the REPL buffer a warning message about the function redefinition (that's expected!); however the Swank output seems to be a bit short as compared to the previous one.
Swank logs of the redefinition

dispatch-event: (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(defun hello ()
  (print \"Hello!\"))") "\"))" :REPL-THREAD 16)
send-event: # (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(defun hello ()
  (print \"Hello!\"))") "\"))" 16)
wait-for-event: (:WRITE-DONE) NIL
wait-for-event: (:WRITE-DONE) NIL
dispatch-event: (:WRITE-STRING "WARNING: redefining COMMON-LISP-USER::HELLO in DEFUN
" NIL 1)
encode-message

A confirmation that something might have broken along the way is that after the last redefinition, Vlime/Swank will now refuse to evaluate any new expression I throw at it.
(defvar *foo* nil)

Swank logs of the DEFVAR invocation

dispatch-event: (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(defvar *foo* nil)") ")" :REPL-THREAD 17)
send-event: # (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(defvar *foo* nil)") ")" 17)

Note: you don't have to redefine the same function, to trigger this; it seems like simply asking Vlime/Swank to evaluate QL:QUICKLOAD will cause it to hang.
Swank logs of the QL:QUICKLOAD invocation
dispatch-event: (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(ql:quickload \"hu.dwim.walker\")") "https" :REPL-THREAD 15)
send-event: # (:EMACS-REX (SWANK-REPL:LISTENER-EVAL "(ql:quickload \"hu.dwim.walker\")") "https" 15)
wait-for-event: (:WRITE-DONE) NIL
dispatch-event: (:WRITE-STRING "To load \"hu.dwim.walker\":
  Load 1 ASDF system:
    hu.dwim.walker
" NIL 1)
encode-message
Swank logs of the DEFVAR invocation
Please tell me I am doing something silly!

Looks like switching to vlime/vlime@direct-json makes all these problems disappear.  Should that be used going forward, instead of phmarek/vlime@master?

Well, the vlime:master branch should work with a current swank:master; but the commits you referenced are quite a bit old; I merged some slime stuff in the meantime.
I'm using the vlime:direct-json branch with the https://github.com/vlime/slime master branch -- there the swank server sends JSON directly, without needing a Lisp thread doing the conversion. I haven't got the necessary modifications to swank upstream, sadly.

I have been using your work for quite some time now, so I am aware of architectural change; it's just that between the branches on your fork, and similar branches on this repo, things have gotten a bit messy and I wasn't sure which branch to track to stay current.
So, to recap, to test this out one should use the following:

Slime: https://github.com/vlime/slime (branch: master)
Vlime: https://github.com/vlime/vlime (branch: direct-json)

Also, this is startup script I have been using to start Vlime/Swank and connect to it through Vim:
sbcl \
    --eval '(pushnew #P"~/opt/slime/__main__/" asdf:*central-registry*)' \
    --load ~/opt/slime/__main__/swank-loader.lisp \
    --eval '(swank-loader:init :load-contribs t)' \
    --eval '(setq swank:*log-events* t)' \
    --load ~/opt/vlime/__main__/lisp/start-vlime.lisp


Lamp package is not turning on flashlight on android  9(Pie) even after giving permissions .

Steps to Reproduce

In pubspec.yaml

dependencies:
  flutter:
    sdk: flutter
  cupertino_icons: ^0.1.2
  lamp: ^0.0.6
  permission: ^0.1.1

In lib/main.dart :

 getCameraPermissionStatus() async {
    var get = '';
    List<Permissions> permissions = await Permission.getPermissionsStatus([PermissionName.Camera,]);
    permissions.forEach((permission) {
      get += '${permission.permissionName}: ${permission.permissionStatus}';
      if (get != "PermissionName.Camera: PermissionStatus.allow") {
        requestCameraPermission();
      } else {
          Lamp.turnOn(intensity:1.0);
      }
    });
  }
requestCameraPermission() async {
    final res = await Permission.requestPermissions([PermissionName.Camera]);
    res.forEach((permission) {
      String a = '${permission.permissionStatus}';
      setState(() {
        if (a == 'PermissionStatus.allow') {
       Lamp.turnOn(intensity:1.0);
        }
        else {
          Permission.openSettings;
        }
      });

    });
  }

flutter run

flutter run --verbose:
Navdeep-Android:flutter_app_pure_demo_shavi navdeepkaur$ flutter run --verbose
[  +38 ms] executing: [/Users/navdeepkaur/Downloads/flutter/] git rev-parse
--abbrev-ref --symbolic @{u}
[  +47 ms] Exit code 0 from: git rev-parse --abbrev-ref --symbolic @{u}
[        ] origin/stable
[        ] executing: [/Users/navdeepkaur/Downloads/flutter/] git rev-parse
--abbrev-ref HEAD
[  +10 ms] Exit code 0 from: git rev-parse --abbrev-ref HEAD
[        ] stable
[        ] executing: [/Users/navdeepkaur/Downloads/flutter/] git ls-remote
--get-url origin
[  +10 ms] Exit code 0 from: git ls-remote --get-url origin
[        ] https://github.com/flutter/flutter.git
[        ] executing: [/Users/navdeepkaur/Downloads/flutter/] git log -n 1
--pretty=format:%H
[  +14 ms] Exit code 0 from: git log -n 1 --pretty=format:%H
[        ] 5391447fae6209bb21a89e6a5a6583cac1af9b4b
[        ] executing: [/Users/navdeepkaur/Downloads/flutter/] git log -n 1
--pretty=format:%ar
[  +13 ms] Exit code 0 from: git log -n 1 --pretty=format:%ar
[        ] 2 months ago
[   +1 ms] executing: [/Users/navdeepkaur/Downloads/flutter/] git describe
--match v*.*.* --first-parent --long --tags
[  +14 ms] Exit code 0 from: git describe --match v*.*.* --first-parent --long
--tags
[   +1 ms] v1.0.0-0-g5391447fa
[ +309 ms] executing: /Users/navdeepkaur/Library/Android/sdk/platform-tools/adb
devices -l
[  +10 ms] Exit code 0 from:
/Users/navdeepkaur/Library/Android/sdk/platform-tools/adb devices -l
[        ] List of devices attached
[   +6 ms] executing: idevice_id -h
[  +43 ms] /usr/bin/xcrun simctl list --json devices
[ +113 ms] No connected devices.
[        ] Run 'flutter emulators' to list and start any available device
emulators.
[        ] If you expected your device to be detected, please run "flutter
doctor" to
           diagnose
[        ] potential issues, or visit https://flutter.io/setup/ for
troubleshooting tips.
[  +17 ms] "flutter run" took 422ms.

#0      throwToolExit (package:flutter_tools/src/base/common.dart:26:3)
#1      RunCommand.validateCommand
(package:flutter_tools/src/commands/run.dart:249:7)
<asynchronous suspension>
#2      FlutterCommand.verifyThenRunCommand
(package:flutter_tools/src/runner/flutter_command.dart:379:11)
<asynchronous suspension>
#3      FlutterCommand.run.<anonymous closure>
(package:flutter_tools/src/runner/flutter_command.dart:335:33)
<asynchronous suspension>
#4      AppContext.run.<anonymous closure>
(package:flutter_tools/src/base/context.dart:142:29)
<asynchronous suspension>
#5      _rootRun (dart:async/zone.dart:1124:13)
#6      _CustomZone.run (dart:async/zone.dart:1021:19)
#7      _runZoned (dart:async/zone.dart:1516:10)
#8      runZoned (dart:async/zone.dart:1463:12)
#9      AppContext.run (package:flutter_tools/src/base/context.dart:141:18)
<asynchronous suspension>
#10     FlutterCommand.run
(package:flutter_tools/src/runner/flutter_command.dart:326:20)
#11     CommandRunner.runCommand (package:args/command_runner.dart:196:27)
<asynchronous suspension>
#12     FlutterCommandRunner.runCommand.<anonymous closure>
(package:flutter_tools/src/runner/flutter_command_runner.dart:401:21)
<asynchronous suspension>
#13     AppContext.run.<anonymous closure>
(package:flutter_tools/src/base/context.dart:142:29)
<asynchronous suspension>
#14     _rootRun (dart:async/zone.dart:1124:13)
#15     _CustomZone.run (dart:async/zone.dart:1021:19)
#16     _runZoned (dart:async/zone.dart:1516:10)
#17     runZoned (dart:async/zone.dart:1463:12)
#18     AppContext.run (package:flutter_tools/src/base/context.dart:141:18)
<asynchronous suspension>
#19     FlutterCommandRunner.runCommand
(package:flutter_tools/src/runner/flutter_command_runner.dart:361:19)
<asynchronous suspension>
#20     CommandRunner.run.<anonymous closure>
(package:args/command_runner.dart:111:29)
#21     new Future.sync (dart:async/future.dart:224:31)
#22     CommandRunner.run (package:args/command_runner.dart:111:11)
#23     FlutterCommandRunner.run
(package:flutter_tools/src/runner/flutter_command_runner.dart:241:18)
#24     run.<anonymous closure> (package:flutter_tools/runner.dart:60:20)
<asynchronous suspension>
#25     AppContext.run.<anonymous closure>
(package:flutter_tools/src/base/context.dart:142:29)
<asynchronous suspension>
#26     _rootRun (dart:async/zone.dart:1124:13)
#27     _CustomZone.run (dart:async/zone.dart:1021:19)
#28     _runZoned (dart:async/zone.dart:1516:10)
#29     runZoned (dart:async/zone.dart:1463:12)
#30     AppContext.run (package:flutter_tools/src/base/context.dart:141:18)
<asynchronous suspension>
#31     runInContext (package:flutter_tools/src/context_runner.dart:43:24)
<asynchronous suspension>
#32     run (package:flutter_tools/runner.dart:51:10)
#33     main (package:flutter_tools/executable.dart:51:9)
<asynchronous suspension>
#34     main
(file:///b/build/slave/Mac_Flutter_Packaging/build/archive/flutter/packages/flut
ter_tools/bin/flutter_tools.dart:8:3)
#35     _startIsolate.<anonymous closure>
(dart:isolate/runtime/libisolate_patch.dart:287:32)
#36     _RawReceivePortImpl._handleMessage
(dart:isolate/runtime/libisolate_patch.dart:171:12)

flutter analyze:
Navdeep-Android:flutter_app_pure_demo_shavi navdeepkaur$ flutter analyze
Analyzing flutter_app_pure_demo_shavi...

   info • Unused import: 'package:flutter/services.dart' • lib/main.dart:2:8 •
          unused_import
   info • This class inherits from a class marked as @immutable, and therefore
          should be immutable (all instance fields must be final) •
          lib/main.dart:11:7 • must_be_immutable
   info • The value of the field '_hasFlash' isn't used • lib/main.dart:47:8 •
          unused_field
   info • Avoid using unnecessary statements • lib/main.dart:117:3 •
          unnecessary_statements
   info • Name non-constant identifiers using lowerCamelCase •
          lib/main.dart:128:8 • non_constant_identifier_names
   info • Avoid using unnecessary statements • lib/main.dart:161:11 •
          unnecessary_statements
   info • The method '_turnFlash' isn't used • lib/main.dart:167:10 •
          unused_element

7 issues found. (ran in 12.6s)

flutter doctor -v:
Navdeep-Android:flutter_app_pure_demo_shavi navdeepkaur$ flutter doctor -v
[✓] Flutter (Channel stable, v1.0.0, on Mac OS X 10.12.6 16G29, locale en-US)
    • Flutter version 1.0.0 at /Users/navdeepkaur/Downloads/flutter
    • Framework revision 5391447fae (2 months ago), 2018-11-29 19:41:26 -0800
    • Engine revision 7375a0f414
    • Dart version 2.1.0 (build 2.1.0-dev.9.4 f9ebf21297)

[✓] Android toolchain - develop for Android devices (Android SDK 28.0.3)
    • Android SDK at /Users/navdeepkaur/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling
      support)
    • Platform android-28, build-tools 28.0.3
    • Java binary at: /Applications/Android
      Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build
      1.8.0_152-release-1248-b01)
    • All Android licenses accepted.

[✓] iOS toolchain - develop for iOS devices (Xcode 9.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 9.2, Build version 9C40b
    • ios-deploy 2.0.0
    • CocoaPods version 1.5.3

[✓] Android Studio (version 3.3)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 32.0.1
    • Dart plugin version 182.5124
    • Java version OpenJDK Runtime Environment (build
      1.8.0_152-release-1248-b01)

[✓] Connected device (1 available)
    • XT1068 • ZX1D64H6G6 • android-arm • Android 6.0 (API 23)

• No issues found!

My full main.dart class:
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';

import 'package:lamp/lamp.dart';
import 'dart:io' show Platform;
import 'package:permission/permission.dart';

void main() => runApp(MyApp());

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  bool _isOn = false;
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Simple Flashlight',
      theme: ThemeData(
        // This is the theme of your application.
        // Try running your application with "flutter run". You'll see the
        // application has a blue toolbar. Then, without quitting the app, try
        // changing the primarySwatch below to Colors.green and then invoke
        // "hot reload" (press "r" in the console where you ran "flutter run",
        // or simply save your changes to "hot reload" in a Flutter IDE).
        // Notice that the counter didn't reset back to zero; the application
        // is not restarted.
        primarySwatch: Colors.blue,
      ),
      home: MyHomePage(title: 'Simple Flashlight'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  MyHomePage({Key key, this.title}) : super(key: key);
  final String title;

  @override
  _MyHomePageState createState() => _MyHomePageState();

}

class _MyHomePageState extends State<MyHomePage> {
  String platform;
  bool  _isOn=false;
  double _intensity=1.0;
  bool _hasFlash=true;
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(widget.title),
      ),
      body:
      Container(
        decoration: new BoxDecoration(
            image: new DecorationImage(image:
            new AssetImage("images/blue_gradient.png"),
                fit: BoxFit.fill
            )
        ),
        child: new Center(
          //  child: new Column(
          //    children: <Widget>[
          child: ButtonTheme(
            minWidth: 160.0,
            height: 40.0,
            child: RaisedButton(
              shape: new RoundedRectangleBorder(
                  borderRadius: new BorderRadius.circular(5.0)),
              color: Colors.lightBlueAccent,
              child: Text("Flashlight", style: TextStyle(fontSize: 18),),
              elevation: 15.0,
              onPressed: () {
                if (platform == 'Android') {
                  checkAndroidCameraPermissions();
                } else
                 //checkAndroidCameraPermissions();
                  // _turnFlash();
                TurnOnflashLight();
                //Lamp.turnOff();
              },
            ),
          ),
          //    ],
          //  ),
        ),
      ),
      // This trailing comma makes auto-formatting nicer for build methods.
    );
  }

  @override
  void initState() {
    // TODO: implement initState
    super.initState();
   // Lamp.turnOn();
   // requestCameraPermission();
    initplatform();
  }

//its just for getting the platform version
  initplatform() async {
    if (Platform.isIOS) {
      platform = "IOS";
      print('is a IOS');
    } else if (Platform.isAndroid) {
      platform = "Android";
      print('is a Android');
      //requestAndroidPermissions();
    }
  }

void killAppState(){
  deactivate();
  Lamp.turnOn(intensity:1.0);
  mounted==false;
}

  void resumeAppState(){
    Lamp.turnOn(intensity:1.0);
    //mounted==true;
    Lamp.turnOn(intensity:1.0);
    //initState();
    Lamp.turnOn(intensity:1.0);
    main();
  }
  void TurnOnflashLight() {
   Lamp.turnOn(intensity:1.0);
     Navigator.push(context, MaterialPageRoute(builder: (context) => SecondScreen()));

 }

  checkAndroidCameraPermissions() {
    getCameraPermissionStatus();
  }

  getCameraPermissionStatus() async {
    var get = '';
    List<Permissions> permissions = await Permission.getPermissionsStatus([PermissionName.Camera,]);
    permissions.forEach((permission) {
      get += '${permission.permissionName}: ${permission.permissionStatus}';
      if (get != "PermissionName.Camera: PermissionStatus.allow") {
        requestCameraPermission();
      } else {
        TurnOnflashLight();
      }
    });
  }

  requestCameraPermission() async {
    final res = await Permission.requestPermissions([PermissionName.Camera]);
    res.forEach((permission) {
      String a = '${permission.permissionStatus}';
      setState(() {
        if (a == 'PermissionStatus.allow') {
          //RestartWidget.restartApp(context).
          TurnOnflashLight();
        }
        else {
          Permission.openSettings;
        }
      });

    });
  }
  Future _turnFlash() async {
    _isOn ? Lamp.turnOff() : Lamp.turnOn(intensity: _intensity);
    var f = await Lamp.hasLamp;
    setState((){
      _hasFlash = f;
      _isOn = !_isOn;
    });
  }
}

Issues i am facing :

requestCameraPermission() async {
    final res = await Permission.requestPermissions([PermissionName.Camera]);
    res.forEach((permission) {
      String a = '${permission.permissionStatus}';
      setState(() {
        if (a == 'PermissionStatus.allow') {
          Lamp.turnOn(intensity:1.0);
        }
        else {
          Permission.openSettings;
        }
      });

    });
  }

, when i allow camera permission Lamp.turnOn( ) runs , but it doesn't turn on flash light first time .I have to restart app to make it work .

In android 9 (pie)  version , it is not turning on the flashlight even after restarting the app .

Please look into these issues . If anybody has any solution or same kind of issue ,Please share .
Any help will be appreciated  . Thanks  .

Duplicate of https://github.com/clovisnicolas/flutter_lamp/issues/9

Duplicate of clovisnicolas/flutter_lamp#9

Hello zoechi, Yes we can say say that this is duplicate of that issue, but please give a solution for that issue . Its being difficult for us to make an app without using java or swift .
Hope a solution will be provided soon ....


⚠ Bofrost.be has degraded performance

In 72ee41f, Bofrost.be (https://www.bofrost.be) experienced degraded performance:

HTTP code: 200
Response time: 1248 ms

Resolved: Bofrost.be performance has improved in ae96ef7.


proxy: Added a connectivity test on startup to test for bad routing

Fixes #348
It's just a basic test for now. Maybe we should put this behind a flag. This will help customers fail fast instead of it being "ready for connections" but being unable to dial into the DB at all, which is obviously pretty important.

Definitely want this behavior flagged. Currently leaning towards disabled by default.

Sure, I'll get some flags behind it.
Should we include the examples to have it?

Sure, I'll get some flags behind it.
Should we include the examples to have it?

One thing I've been meaning to add is a section with troubleshooting suggestions. Perhaps this would be a good place to highlight it?

Sure, that sounds good. Had a couple more customer cases come through about this; wouldn't be bad to have something to help people troubleshoot this themselves.

https://cloud.google.com/sql/docs/mysql/sql-proxy#troubleshooting
I can add the flag to this page once we have decided on the details; I think that's the best bet?

@hilts-vaughan can you rebase this? I'm planning on a release soon and I'd like to include this.

Thanks for the review. I'll look at getting some of those changes integrated today. I'll rebase it too while I'm at it.
Would you prefer one commit kvg?

Thanks for the review. I'll look at getting some of those changes integrated today. I'll rebase it too while I'm at it.
Would you prefer one commit kvg?

What ever makes sense is fine. I usually do larger changes in separate commits but I also often group misc feedback into a single "Addresses feedback." commit.

I had to remove the defer since it was trying to operate on the nil and was dereferencing it. It works fine under the new model.

Closing this PR since it's gone stale.


Update README.md

Updated README with section about filing issue in this repo.

Reminder this is a public repo

Oh wow, didn't realize that, thank you for pointing it out!
I think we'd want to leave on issues for this repo in that case.

thanks for pointing that out @mrfaizal.

I think we should leave issues in same repo if its public.

FYI I lost access to this repo when I left GitHub but I'm the original author and happy to keep maintaining it and responding to issues if someone can add be back as a maintainer.

FYI I lost access to this repo when I left GitHub but I'm the original author and happy to keep maintaining it and responding to issues if someone can add me back as a maintainer.

Thats funny we don't have access either. Wondering if you wouldn't mind sharing the story on why we OSS'd the work?

Everyone on the SRE/Service Catalog team should have admin access. cc @ninjapenguin This started originally as a chaos engineering project. It was open sourced just because it's generic and was fun to share with more people.

OK, thats great @lingrino. We'll do a little leg work and see if we can't get back to you on doing some co-maintership here as well.
Thanks!

With reference to conversation above, we dont want to commit this change. For public repos, we will keep the issues in same repo. Closing this PR out.

@lingrino so that you can continue to provide maintainership on the repo I've added you as admin. We are taking a backlog issue to make sure the repo is still relevant for internal services as well so will get back to you on more about that as well to see what we might do with future maintainership. For now, thanks so much for helping us maintain it. We've added our team as GitHub maintainers as well for any other updates/fixes we might have to work through.
Thanks! 💟

Thank you!


[Issue]: User's agency is not reflected in upload dropdown

Why is this issue important?
If the user's agency is not the default selected, we expect to see files uploaded to the wrong agency frequently which will cause a lot of data issues
Current State
in staging, when click Upload Workbook and are brought to the new workbook page, "Main Agency" is autoselected from the dropdown regardless of the users' agency
Expected State

On the new uploads page, organization staff users should only see their own agency in the dropdown, and it should be auto-selected as their own agency. Organization staff users should not be able to select any other agency from the dropdown.
organization admin & USDR Admin users should be able to select any agency from the dropdown on the new upload page, but their own agency should be auto-selected when they go to the page

Implementation Plan
The following functions need to be added...
Relevant Code Snippets
No response

Tested in staging, looks great!!


Enhance utils

Coverage increased (+0.03%) to 98.028% when pulling e987a33f3501c928c32af67f350e46d33278e377 on enhance-utils into ca1acae97806eb024c8f91b6b6c24cf824ff43a8 on master.

Coverage increased (+0.03%) to 98.028% when pulling 2cbe10615129a612a378e77b38a8bc4243242957 on enhance-utils into ca1acae97806eb024c8f91b6b6c24cf824ff43a8 on master.

Coverage increased (+0.03%) to 98.028% when pulling e119b0990a1128c89a319494e38d924256ed2d4b on enhance-utils into ca1acae97806eb024c8f91b6b6c24cf824ff43a8 on master.

Coverage increased (+0.03%) to 98.028% when pulling fc8a7504c606f9909b004cd7ba10775d4e0ef151 on enhance-utils into d2a015d8c274b0f035b3567f296609f92645ec46 on master.

Coverage increased (+0.03%) to 98.028% when pulling df30014188ce06e40425137ee1b46a1bf7a2eb21 on enhance-utils into d2a015d8c274b0f035b3567f296609f92645ec46 on master.

Coverage increased (+0.03%) to 98.028% when pulling 0e1fff121ab822de3e96c14b6e02b9e9c5a5f0e9 on enhance-utils into d2a015d8c274b0f035b3567f296609f92645ec46 on master.


Update service-connection-tool-not-download-updates.md

Updated the workaround and added Access requirements

@rashid2982 : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@helenclu : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@helenclu : Thanks for your contribution! The author(s) have been notified to review your proposed change.


[bug] Can't open this file Error

I'm trying to open a tldraw file from tldraw website in chrome on a mac. I'm doing file > open > selecting a file in a Dropbox folder on my mac.
I get this error:

Can't open this file
can't open files in this folder because it contains system files

The files are perfectly fine in the folder. If I copy them to another spot and then open them it works.
Any ideas what is happening?

Closing this as we won't be addressing a fix for this version. Check https://github.com/tldraw/tldraw for the latest! And please share there if the bug persists.


 I can't find them.

http://www.gildor.org/projects/umodel/faq
Look for "Where could I get older version of UModel?"

Hold on. How do I download it?

Well, it seems github changed the way how it works. However I didn't know that, so I had to do some checks (you had to do that by yourself!).
In history, select a version which you want to download. Press "<>" button. It will open repository for given commit. Now, select umodel.exe, and in new page - hit "Download" button.

ok

idk what version of UE fortnite is using

4.16 i know now

the skeletal mesh is my problem

CLOSED


Using docker client CLI to connect to docker api through portainer does not work for interactive commands

Bug description
When using the docker client CLI to connect to the docker API of a specific endpoint (e.g. "localhost:9000/api/endpoints/1/docker") it is possible to issue a "docker ps". However, when issuing a "docker run hello-world" the container is created but the docker client CLI does not respond anymore.
Expected behavior
When issuing a "docker run hello-world" to the docker API of a specific endpoint, the docker client CLI should print the message generated by the hello-world container.
Portainer Logs

2020/08/20 16:23:49 Warning: the --template-file flag is deprecated and will likely be removed in a future version of Portainer.
2020/08/20 16:23:50 Templates already registered inside the database. Skipping template import.
2020/08/20 16:23:50 server: Reverse tunnelling enabled
2020/08/20 16:23:50 server: Fingerprint 11:33:04:af:52:d8:46:72:78:f2:23:ae:94:e0:91:ba
2020/08/20 16:23:50 server: Listening on <IP_ADDRESS>:8000...
2020/08/20 16:23:50 Starting Portainer 1.24.1 on :9000
2020/08/20 16:23:50 [DEBUG] [chisel, monitoring] [check_interval_seconds: 10.000000] [message: starting tunnel management process]

Steps to reproduce the issue:

Run the Portainer container, then navigate to the Portainer web UI and create a local endpoint
Request an authentication token from the Portainer API
Create a config.json file inside a new folder that looks like this (replace TOKEN with your actual token):
{ "HTTPHeaders": { "Authorization": "Bearer TOKEN" } }
See that the "docker ps" command works:
docker -H localhost:9000/api/endpoints/1/docker --config PATH/TO/CONFIG/FOLDER ps
Now try to run the hello-world image:
docker -H localhost:9000/api/endpoints/1/docker --config PATH/TO/CONFIG/FOLDER run hello-world
The docker client does not respond anymore

Technical details:

Portainer version: 1.24.1
Docker version (managed by Portainer): 19.03.12
Platform (windows/linux): Docker Desktop for Windows using WSL 2 integration (Ubuntu 20.04), Linux
Command used to start Portainer: docker run -d -p 8000:8000 -p 9000:9000 --name=portainer --restart=always -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer

Additional context
I am working on a tool to forward docker commands directly to a specific Portainer endpoint using the docker client CLI. The Portainer HTTP API by example states that the docker API of a Portainer endpoint is available at "/api/endpoints/x/docker" and works exactly like the actual docker API. Thus it should allow the docker client CLI to talk to it just like it would to the actual docker API.

@deviantony not sure of the expect result here, but after the create request at first the connection appears stuck with no output from the container piped to the CLI. However I noted that the container was still in the created state and to get output to its logs I have to start it

Closing as I believe I have answered your question

I just tried creating a container first and starting it just like you suggested and that worked (yay 🙂). However, starting a container and attaching does not work: when I execute "docker start -a hello_world_container" the client does not respond for some time and then exits with error: "unable to upgrade to tcp, received 405". Instead of the error I would expect to see the hello world message from the hello-world container printed back to me.

I would ask the community for help with this further on our slack, forum or discord or pay for personal support then we could look into it.

If anyone is still interested, I've developed (or rather adopted a different similar tool originally intended for Racher) a tool for remotely opening shells for containers managed by Portainer. It's far from perfect and it lacks a few features but it works.
https://github.com/devbranch-vadym/portainerssh


Base Appveryor and TravisCI configs

Fixed by: https://github.com/crezefire/cxp/commit/7aecd4456171cb9cb4b3b10fbe4fbafd5d72cd14


Unable to paste over visual selection in TTY mode only

What did you expect to happen?
Text within visual selection is replaced by previously-yanked text
Previous text within visual selection is yanked instead for future pasting
What actually happened?
Visually-selected text left intact, and yanked
Additional details:
OS: MacOS 10.14.6 (Mojave)
Emacs: 26.3 via Nix on nixpkgs-darwin-19.09 channel (nixpkgs-19.09pre194823.57a4956bc25), also occurs with Emacs 26.3 via emacs-plus as well as Emacs 28.0.50 via emacs-overlay@ac62d6d25a13787da2b8e0b2d0cc2b84816aa7bf.
Minimal init.el, packages.el and config.el emptied:
;;; init.el -*- lexical-binding: t; -*-
(doom! :ui doom :editor evil)

Steps to reproduce:

emacs test.txt
Enter "foo"\n"bar"
Place point inside foo
Press yi"
Press $p to confirm foo was yanked
Place point inside bar
Press vi"p to visual-select bar and then attempt to paste over it
Press $p to confirm bar was yanked while replacing it

Unsuccessful version:

emacs -nw test.txt instead of command above, no other configuration or installation changes
Repeat 2-8 above
Final outcome:

"foo"foo
"bar"bar

System information:

emacs   version    26.3
        features   NOTIFY ACL GNUTLS LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS MODULES THREADS
        build      Feb 26, 2020
        buildopts  (--prefix=/nix/store/bcnb39cgi9d0im9qpm58lhx8hcsgdxfm-emacs-26.3 --disable-build-details --with-modules --with-ns --disable-ns-self-contained CFLAGS=-DMAC_OS_X_VERSION_MAX_ALLOWED=101200)
        windowsys  ns
        daemonp    server-running
doom    version    2.0.9
        build      HEAD -> develop, origin/develop, origin/HEAD 9f8cede4c 2020-02-26 17:48:45 -0500
        dir        ~/.config/doom/
system  type       darwin
        config     x86_64-apple-darwin17.7.0
        shell      /bin/sh
        uname      Darwin 18.7.0 Darwin Kernel Version 18.7.0: Thu Jan 23 06:52:12 PST 2020; root:xnu-4903.278.25~1/RELEASE_X86_64 x86_64
        path       (/usr/local/Caskroom/google-cloud-sdk/latest/google-cloud-sdk/bin ~/.asdf/shims ~/.asdf/bin /run/current-system/sw/bin ~/.emacs.d/bin /opt/X11/bin ~/.nix-profile/bin /nix/var/nix/profiles/default/bin /usr/local/bin /usr/bin /bin /usr/local/sbin /usr/sbin /sbin ~/.cargo/bin /nix/store/bcnb39cgi9d0im9qpm58lhx8hcsgdxfm-emacs-26.3/libexec/emacs/26.3/x86_64-apple-darwin17.7.0/)
config  envfile    envvar-file
        elc-files  0
        modules    (:ui doom :editor evil)
        packages   (n/a)
        unpin      (n/a)
        elpa       (n/a)

I can't seem to reproduce it. This suggests a communication issue between Emacs and your clipboard.
Could you check if xclip-mode is enabled in your tty session of Emacs? If so, try disabling it (M-x xclip-mode) and see if that resolves your issue.
(What xclip-mode does is it facilitates communication between Emacs and your clipboard. Despite it's name, it uses pbcopy/pbpaste on the mac)

Disabling xclip-mode does indeed seem to correct the behavior! I will try to run further with this now that I have an area to look into, and report back if I come up with anything constructive. I may just tolerate the lack of integration with OS clipboard for the interim.
Was using this in my config.el so I don't forget about it:
(remove-hook 'tty-setup-hook 'doom-init-clipboard-in-tty-emacs-h)

Based on the existing setup here.


Fix idxmin/idxmax aggregation implementation

[ ] Closes #9882
[ ] Tests added / passed
[ ] Passes pre-commit run --all-files

Yup, right now just looked through the existing tests for idxmin/idxmax aggregations and consolidated/modified to capture the failing cases encountered in #9882


Reporting typos in Hello World tutorial notebook

Thanks for the great work.
The Hello World tutorial notebook was very well designed and surely helpful for me to catch up to speed. Thanks :)
https://github.com/tensorflow/similarity/blob/master/examples/supervised_hello_world.ipynb
I think I found some minor typos while walking through the tutorial, so here is the list.
First, I think the point of the last section of this tutorial is to query the reloaded model. However, the model used here for the query appears to be not the reloaded model, but the original one.
I might be wrong, but
# lookup the nearest neighbors
nns = model.lookup(x_display, k=num_neighboors)

might be
# lookup the nearest neighbors
nns = reloaded_model.lookup(x_display, k=num_neighboors)

.
Secondly, renaming some constants to match the parameter names of MultiShotMemorySampler might be great for a baby programmer like me ^^
CLASS_PER_BATCH -> CLASSES_PER_BATCH
EXAMPLE_PER_CLASS -> EXAMPLES_PER_CLASS

Finally, the output of this cell appears to be a bit strange and may need to be re-evaluated.

Best,

Thanks for taking the time to review the notebook and glad the notebook was helpful.
Regarding the typos:

Looks like you're right, we should be calling lookup() on the reloaded model. I'll push a quick fix for that.
Those are some good suggestions for updating the parameter names. We'll look at updating that as part of the bump to 0.14.0
The table rows are correct, but it looks like we just needed to rerun the cell to get the correct header output. I'll add this as part of the reload.lookup() fix.

Thanks for the update.
Regarding the second point, I didn't mean to update the parameter names (they are already good) but renaming the name of constants that are passed as arguments to MultiShotMemorySampler. Sorry for this confusion.
Here is the cell that defines the constants passed as arguments to MultiShotMemorySampler.

and suggested modification:
CLASS_PER_BATCH -> CLASSES_PER_BATCH
EXAMPLE_PER_CLASS -> EXAMPLES_PER_CLASS or EXAMPLES_PER_CLASS_PER_BATCH

Anyway, they are very minor details, so please feel free to close this issue when you feel appropriate :)

oh, thanks for clarifying. Both the constants in the notebook and the parameter names are now updated in the 0.14 branch.

Closing this issue as the changes are now in 0.14.


Updating sample to work with recent aspnet changes.

Thanks @tushargupta51, sorry for the delay in getting to this.


Update dependencies in setup.py and dev.yml

Description

Closes #167
Closes #160

Summary of Changes

Reorder dependencies alphabetically by section
Update dev.yml pins to the latest versions
Update .pre-commit-config.yaml to latest versions
Update docs for installing xcdat

Checklist

[ ] My code follows the style guidelines of this project
[ ] I have performed a self-review of my own code
[ ] My changes generate no new warnings
[ ] Any dependent changes have been merged and published in downstream modules

If applicable:

[ ] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass with my changes (locally and CI/CD build)
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] I have noted that this is a breaking change for a major release (fix or feature that would cause existing functionality to not work as expected)

Codecov Report

Merging #174 (2d2b425) into main (3c6f165) will not change coverage.
The diff coverage is n/a.

:exclamation: Current head 2d2b425 differs from pull request most recent head 9a1db0b. Consider uploading reports for the commit 9a1db0b to get more accurate results

@@            Coverage Diff            @@
##              main      #174   +/-   ##
=========================================
  Coverage   100.00%   100.00%
=========================================
  Files            8         8
  Lines          381       381
=========================================
  Hits           381       381

Continue to review full report at Codecov.

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


doi2ietf crashes on a DOI that has "editor" but no "author"

From a gentleman Alon Ben Refael:

The above module is really great. Thank you!
I would like to turn your attention to the fact that not all doi's work correctly.
Here is an example:

10.1002/9783527647941
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "~/.local/lib/python3.8/site-packages/doi2ietf/utils.py", line 285, in process_doi_list
return parse_doi_data(data_lst, xml_output)
File "~/.local/lib/python3.8/site-packages/doi2ietf/utils.py", line 253, in parse_doi_data
ascii_lowercase[i]: transform_doi_metadata(doi_data)
File "~/.local/lib/python3.8/site-packages/doi2ietf/utils.py", line 72, in transform_doi_metadata
result["author"] = author_name(data["author"])
KeyError: 'author'

I guess it's because there is no author, rather than an "editor" in the METADATA.

So we shouldn't crash when there is no author, and need to handle the case of "editor".
Thank you Alon for reporting!

@ronaldtse ok, I will fix it now and add this case (10.1002/9783527647941) to tests.
But original ruby script does not handle case of "editor" (it just ignoring this field).
I will add editor data as <author> with role="editor", as it described at rfc7749 sec. 2.6.3. Also I will add this change to test fixtures.
If it correct, I can tag this fix as release.

The format should follow RFC 7991 which isn’t so different from RFC 7799.
The proposed fix should be correct, just help double check. Thanks!

Yes this library should work better than the original script 😉

@yablokov since the commit e9298fd fixes this issue, can you help make a new release? You just need to tag it and it should auto-release. Thanks.

Ok, update published to PyPi.
But I have a question. If we change output strictly according to RFC 7991, we lost full compatibility with original doilit.
I thought it would be full analogue of doilit with same behavior to be compatible with some third party CI, pipelines, tests, etc.
So, if doi2ietf should be just alternative implementation of converter DOI to RFC 7991, can I update tests and don’t use doilit output as reference for the future?

@yablokov we don't actually care about doilit from this point onwards, so we should do whatever is correct (not necessarily compatible). Thanks!


WiFi scan freezes networking

I have exactly the same issue as described at https://groups.google.com/group/controlplane-support/browse_thread/thread/eb88a193e18fc3d0/a75de32ff0373a8c or my MacBook Air.
Also, I'm getting exactly the same symptoms when clicking on "Wi-Fi" in System Information.app or by running "airport -s" (however, airport utility for some reason does this scan much more faster, so instead of missing ping packets or lost network due to re-authentication timeout, I'm getting just 200-300 msec delays)
So I believe this issue is cased by scan. But, frankly, in my case I don't need all available WLANs as evidence, I need only WLAN I'm currently associated with. And it's (B)SSID might be obtained without scanning environment.
Is that possible to provide another evidence source, called, i.e., 'WLAN', which will just check what (B)SSID I'm associated with now?
Thank you.

To be precise, this issue actually renders WIFI evidence unusable. It might be so, though, that this issue appears only on certain hardware. Here are details for my case:
Software Versions:
CoreWLAN:	2.1.1 (211.3)
CoreWLANKit:	1.0.1 (101.1)
Menu Extra:	7.0.1 (701.2)
configd plug-in:	7.1.1 (711.1)
System Profiler:	7.0 (700.3)
IO80211 Family:	4.1.1 (411.1)
WiFi Diagnostics:	1.0.1 (101.1)
AirPort Utility:	5.5.3 (553.20)
Interfaces:
en0:
Card Type:	AirPort Extreme  (0x14E4, 0xE9)
Firmware Version:	Broadcom BCM43xx 1.0 (<IP_ADDRESS>.18)

sorry, didn't mean to close it :)

Unless you've checked the option in advanced settings screen the wifi scanner doesn't actually scan if it is already associated.  Relevant code - https://github.com/dustinrue/ControlPlane/blob/master/Source/CoreWLANEvidenceSource.m#L91
Debug output from my machine which is connected to an access point.
2012-01-24 09:10:36.757 ControlPlane[37526:7423] -[WiFiEvidenceSourceCoreWLAN doUpdate] already associated with an AP, using connection info
2012-01-24 09:10:36.757 ControlPlane[37526:7423] -[WiFiEvidenceSourceCoreWLAN doUpdate] WiFiEvidenceSourceCoreWLAN >> (
{
"WiFi BSSID" = "[redacted]";
"WiFi SSID" = zerocool;
}
)

However, if you have multiple wifi cards or multiple cards that would report themselves as being wifi it is still possible for CoreWLAN to cause a scan.  You also need to verify that you're not actually dealing with a weak signal, which causes the exact same symptoms as scanning while in use.

Nope, I haven't even tried advanced options and didn't know this option exists.
There are no other wifi interfaces. There are virtualbox and openvpn virtual interfaces though.
There are plenty of networks in the building and nearby, some if them have quite a weak signal. But my own AP is just nearby to be with a perfect signal, so I doubt this might be the case.

You're welcome to download a DEBUG build and watch the logs for yourself.  If it doesn't say it is already associated and lists out all of the local wifi APs then I can try to figure out why.
http://dl.dropbox.com/u/12850/ControlPlane/ControlPlane-1.1.6-DEBUG.dmg

Thank you, will do.
By the way, building from scratch ends up with
"2012-01-24 19:51:04.073 defaults[2627:707]
The domain/default pair of (/Applications/Tedium.app/Contents/Info, CFBundleIdentifier) does not exist
sdp: option `--bundleid' requires an argument
usage: sdp -f{ahmst} [-o directory | file | -] [options...] [file]
Command /bin/sh failed with exit code 2
"

... and running debug version ends with
"Application Specific Information:
objc[2684]: garbage collection is OFF
*** Terminating app due to uncaught exception 'SUNoFeedURL', reason: 'You must specify the URL of the appcast as the SUFeedURL key in either the Info.plist or the user defaults!'
*** First throw call stack:
(
0   CoreFoundation                      0x00007fff87072286 __exceptionPreprocess + 198
1   libobjc.A.dylib                     0x00007fff87ff1d5e objc_exception_throw + 43
2   CoreFoundation                      0x00007fff870720ba +[NSException raise:format:arguments:] + 106
"

Yea, currently the master branch doesn't build unless you have Tedium installed.  I'm working on a tool to manage Time Machine backup destinations.  Once I get the AppleScript stuff figured out in Tedium this error will go away.  If you're good with AppleScript I'll take any hints you have :)

Sorry about the debug build, I fixed that issue in my nightly script but forgot about the debug script, download it again.  It'll ask to send a crash report, you can cancel it :)

Okay, it seems it doesn't do the scan:
20:42:46.083 -[WiFiEvidenceSourceCoreWLAN doUpdate]
Attempting to do the scan
already associated with an AP, using connection info
WiFiEvidenceSourceCoreWLAN >> (
{
"WiFi BSSID" = "...";
"WiFi SSID" = ...;
}
)
However, the issue is 100% reproducible. With Control Plane running I'm having huge jitter and timeout pinging router, without ControlPlane wifi works smoothly, not timeouts and jitter is below 3 msec.
Worth noting that I'm at home now so it's a different AP and environment, but same issue.
I know a bit about what to do with gcc and gdb (mostly linux experience though), so I probably could help with debugging if given a hint where to look.

Okay, now this is really funny.
It seems that the issue with WiFi is actually caused by Bluetooth evidence.
I tried to turn WiFi evidence off and launch ControlPlane again. And got the same problem.
Then I tried to turn off Bluetooth evidence and got issue gone. Then I tried to turn WiFi evidence back again, and, yes, you're right, no problem at all, WiFi works smoothly.
I have no idea if this is common issue for any mac or just for these tiny MBAs, and if this issue is software, hardware or, well, physical, but the Bluetooth evidence does something weird with wifi on every run.
I guess issue might be closed now :)

I was just coming here to ask if you also use bluetooth.  Bluetooth scanning is a really shitty process. At one point I had split the two up, connected bluetooth devices and nearby (scanning).  Might be worth actually doing that and leaving it that way.

I'll check if bluetooth evidence does the same thing with WiFi on my office iMac 27"

Say, that wouldn't happen to be a 2.4Ghz wifi network, would it? 'cause bluetooth uses the same frequency but transmits data differently --> interference. If it is, then there's nothing we can do about it, it's due to the overcrowded frequency band(s).

Tried with iMac, no proble at all. So this issue is specific to macbooks, and, most probably, is hardware related.

I'll go back to having the bluetooth scanning and associated bluetooth devices has separate evidence sources.

I have a better idea. Instead of scanning environment all the time, you might be just trying to setup an L2CAP Channel to target device. The simplest way do to so, I guess, would be inquiring device name. You might set timeout for this operation as low as 8 timeslots or 5 msec, but real life timeout would be around 200-300 msec. This has another advantage as the target device might be not discoverable.

Also, it might make sense to maintain a state for the target devices (nearby/lost) and, once device is found nearby and there were a timeout during next try, to make a few another immediate tries in order to make sure it wasn't just a missed transmission and device is still nearby.


MacOS Brew script: Complaining about boost_python missing.

Hi,
First of thanks for those amazing repos. Making better build scripts together is a really neat idea.
I did not knew that you could use brew to create isolated environments. It's pretty effective and powerful.
There seems to be an issue with boost_python. It does install well in the stage's brew folder but is not picked up by USD's Cmake.
 Unable to find the requested Boost libraries.

  Boost version: 1.67.0

  Boost include path:
  /USD_Explorations/usdview-native/deps/src/USD-18.09/stage/homebrew/include

  Could not find the following Boost libraries:

          boost_python

I have tried setting envs like so:
BOOST_LIBRARYDIR=/Volumes/4TB/PROJETS/FX/USD_Exploration/usdview-native/deps/src/USD-18.09/stage/homebrew/Cellar/boost-python/1.67.0/lib

But I'm still getting the same issue.
Except from that all deps seems to build well.

Thanks for the report. The official cmake script to find Boost is very fussy. There might be further steps necessary to teach cmake where the  boost python library is. If you look at the CMakeCache.txt file, where did it find the other boost libraries? From your homebrew directory, or some other place?

It seems others have had success. If this issue persists, please reopen.

I haven't tried in a long time, but perfect timing as I'm actually back at it!
Thanks


Add JetBrains to users list

We use Storybook to develop and document our shared web UI components library
Unfortunately, I haven't found a place for a link to our live Storybook:
https://jetbrains.github.io/ring-ui

Thanks! Will bring back the community gallery as part of #31 👍


corrected service_cmd string in BCPC-Hadoop-Head-ResourceManager role

This is intended to fix #573

LGTM


Wrong setting when using custom domain

How did you install the Amplify CLI?
npm
If applicable, what version of Node.js are you using?
v18.2.0
Amplify CLI Version
10.5.2
What operating system are you using?
Mac
Did you make any manual changes to the cloud resources managed by Amplify? Please describe the changes made.
No manual changes made
Describe the bug
If you provide a custom auth.mydomain.com for OAuth in cognito, every time you run amplify push it overwrites aws-exports.js and changes:
oauth: {    domain: auth.mydomain.com --> gets changed to . "appname-env.auth.region.amazoncognito.com" }
https://github.com/aws-amplify/amplify-cli/blob/06300cc1444bf6e018cc50e18f9cce1967e00426/packages/amplify-frontend-javascript/lib/frontend-config-creator.js#L359-L362
Expected behavior
If a custom domain name is used, '.auth.region.amazoncognito.com' should not be added to the end.
Reproduction steps

An existing cognito for amplify auth is integrated
Added custom domain for Cognito
Changes are pulled locally or pipeline is triggered
'auth.domain' appears incorrectly in aws-exports.json

Project Identifier
77facb24fcba8c9dee551c27006d6b76
Log output
No response
Additional information
No response
Before submitting, please confirm:

[X] I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
[X] I have removed any sensitive information from my code snippets and submission.

Hey @sametkabay thank you for taking the time to file this! To clarify, how is the custom domain added to Cognito? Is this through the amplify update auth flow or via overrides?

Hi @josefaidt, aws cognito user pool settings in browser. Own domain added and amazon cognito domain removed in domain name tab. Then when I pull with the cli, I can see the error. same issue appears when issuing release with amplify pipeline

Hey @sametkabay thanks for clarifying! Unfortunately the CLI will not be able to sync changes made in the AWS Console with your Amplify project on amplify pull, and upon amplify push Amplify can overwrite those manual changes. Instead can you try setting the custom domain via overrides with amplify override auth?

Hi @josefaidt,
I agree with you, override can be used as a solution to this problem. It can even be solved within the application with a simple condition. After doing some research, I came across an example of this:
https://github.com/aws-amplify/amplify-cli/issues/1880#issuecomment-626331305
But i don't think this is the right fix
That's exactly what Cli does:
If can use cognito standart domain: selected-subdoman => [selected-subdoman].{region}.amazoncognito.com => this is true
If can use custom domian: [custom-domain] =>  [custom-domain].{region}.amazoncognito.com => ex: auth.example.com.auth.us-west-2.amazoncognito.com => this is wrong
when i debug i saw this:
standart domain: cognitoResource.output.HostedUIDomain = selected subdomain. ex: auth
custom domain: cognitoResource.output.HostedUIDomain = full url. ex: auth.example.com
the code I marked above works the same for both.
We use a custom domain because we want to show our own domain name when using identity providers (google/facebook)
I solved this problem temporarily by overriding the aws-exports.json file in the application but I know that this is not true, the changes I make through the browser will be reflected, and I need to make changes in the application.
I've seen different issues about this as well. Hope it can be fixed soon

Hey @sametkabay thanks for clarifying! Are you saying when you override the hosted UI domain with amplify override auth and push, you are seeing the correct domain in the AWS Console but not in your aws-exports.js file?

@josefaidt I said it works but it shouldn't be needed

Hey @sametkabay glad to hear it works for you, but to clarify are you able to override the domain in the override.ts file for auth and that domain is not being reflected in the aws-exports file?

@josefaidt I didn't use override.ts, I solved it in my own code, so I can't give a clear answer. If this is important information, i can try it for you

Hey @sametkabay apologies for the delay.

If you provide a custom auth.mydomain.com for OAuth in cognito,

How was the custom domain originally added to the Cognito resource? Was this added manually in the AWS Console or via a parameter in your project locally?

Hi @josefaidt, we added it with the AWS Console.

Hey @sametkabay thanks for clarifying! Typically it is not recommended to modify settings of resources in the AWS Console as they can be overwritten on subsequent updates/amplify push attempts. Amplify CLI will create infrastructure-as-code with AWS CloudFormation, and amplify pull is not able to sync the changes made in the console with the local definitions. Instead, it is recommended to use overrides where you can modify settings of resources that will be carried across environments and subsequent updates.
Unfortunately, using overrides will not update your aws-exports to reflect the custom domain, however this can be configured manually in your frontend

@josefaidt I solved the problem with a method similar to your suggestion. I've been using it for a while.
I am not looking for a solution in this thread. I wanted to let you know that there is such a problem in order to produce a permanent solution.

Hey @sametkabay glad to hear it. I'll mark this as a feature-request to improve the domain generation in aws-exports to read from Cognito rather than constructing it manually

When using Google OAuth they require you to verify domain ownership in order to use it in production (non-test mode).  It's impossible for us to verify amazoncognito.com, so using a custom user pool domain is required.  Every user of Google OAuth will run into this problem.  Please fix it or provide good documentation around it, including examples of a recommended workaround.

I encountered the same problem.
I have created a Cognito User Pool and added a custom domain auth.m.jaznu.com

Auth is imported into Amplify.
My application is on the m.jaznu.com domain.
But src\aws-exports.js looks like this:
...
"oauth": {
"domain": "auth.m.jaznu.com.auth.eu-central-1.amazoncognito.com",
...
Of course it doesn't work.
Because the correct value should be "domain": "auth.m.jaznu.com",
The value was generated as if I had not a custom domain, but a Cognito domain.
In amplify\backend\amplify-meta.json there is correct data:
...
"auth": {
"jaznuXXXXX9f": {
"service": "Cognito",
"serviceType": "imported",
...
"HostedUIDomain": "auth.m.jaznu.com",

When I click Sign Up with Google:

I see this incorrect page auth.m.jaznu.com.auth.eu-central-1.amazoncognito.com:

Insted of correct auth.m.jaznu.com

Maybe the idea is that by adding a custom domain to Cognito - under its hood, the domain ${cognitoResource.output.HostedUIDomain}.auth.${projectRegion}.amazoncognito.com is created
And in Route 53 I link my custom domain auth.m.jaznu.com to auth.m.jaznu.com.auth.eu-central-1.amazoncognito.com
But in my case, auth.m.jaznu.com.auth.eu-central-1.amazoncognito.com does not open. Although auth.m.jaznu.com works correctly
But the registration form via Google uses auth.m.jaznu.com.auth.eu-central-1.amazoncognito.com, which does not work

I added this hack:
import awsconfig from './aws-exports'

// removing the part of the domain that is causing it not to work
if (awsconfig.oauth.domain.includes('m.jaznu.com')) {
    awsconfig.oauth.domain = awsconfig.oauth.domain.replace('.auth.eu-central-1.amazoncognito.com', '')
}

Amplify.configure(awsconfig)

Only after that did it start working. But I'm interested in how it is supposed to work without such a hack?


A

What version of Go are you using (go version)?

$ go version

Does this issue reproduce with the latest release?
What operating system and processor architecture are you using (go env)?
go env Output
$ go env

What did you do?

What did you expect to see?
What did you see instead?

Looks like this may have been opened by mistake?


Fixed issue #50

Added support to filter the array of strings
Added test cases

looks good, @solodynamo can you release a new version?


Remove usages of unsafe lifecycle methods

React team recently published a blogpost: https://reactjs.org/blog/2018/03/27/update-on-async-rendering.html
TL;DR: cWM, cWRP, and cWU methods are considered unsafe for future async rendering and will be deprecated soon. The recommended way for open source maintainers to deal with it is to use react-lifecycles-compat package and migrate to new static getDerivedStateToProps method

Thanks! I don't have time to work on this now myself but I'd love a PR for it :)

Feel free to borrow ideas from #https://github.com/styled-components/styled-components/pull/1664
Particularly, here's the solution for ThemeProvider lifecycles: https://github.com/styled-components/styled-components/pull/1664/files#diff-9f2631c972fc5bab75b5dee186444983

rewrite this whole Theming system using the new context API

That's a good idea, but that would mean deprecating React <16

I would like to work on this using @kentcdodds suggestion above regarding the theme-provider.

This project is now in an unmaintained status. Please see the README for more information.


First Get set up link does not work

Get set up link points to https://docs.microsoft.com/en-us/windows/apps/get-set-up which doesn't work

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

ID: 1fcd2e7e-612d-29de-6b94-3bed0b772b16
Version Independent ID: cf067679-95df-f7d2-17ec-d15cc18c0b4b
Content: What's a Universal Windows Platform (UWP) app? - UWP applications
Content Source: windows-apps-src/get-started/universal-application-platform-guide.md
Product: uwp
Technology: get-started
GitHub Login: @QuinnRadich
Microsoft Alias: quradic

Sorry for the long delay on this issue. This broken link has been fixed.


Unable to unwatch issues with most recent versions of the App

When trying to unwatch a ticket, MS Teams gets:

Something went wrong in the Jira Server application

And in the application logs, we can see the following when the request to remove a watcher is received by Jira:
2022-05-26 07:33:02,459+0100 OkHttp https://msteams-jira-server.service.signalr.net/... INFO      [c.m.teams.service.SignalRService] Message received: {"requestUrl":"api/2/issue/ISSUE-KEY/watchers?username=some.user.here","requestType":"DELETE","requestBody":"","token":"TRIMMED>...","teamsId":"<TRIMMED>","atlasId":"<TRIMMED>"}
And Jira's response is:
2022-05-26 07:33:02,579+0100 OkHttp https://msteams-jira-server.service.signalr.net/... DEBUG      [c.m.teams.service.SignalRService] SignalR invoke hub method Callback() with response: {"code":415,"response":"","message":"Something went wrong in Jira Server application."}

This does not happens with the latest version on Marketplace. But it's happening at least with the following:

2022.06.95
2022.02.88 - Provided to a customer with additional logging for debug purposes.

fixed by https://github.com/atlassian-labs/msteams-jira-server-addon/issues/10