Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Console parameter and multi parameter log v3 #2243

Closed
mburger81 opened this issue May 10, 2017 · 8 comments
Closed

Console parameter and multi parameter log v3 #2243

mburger81 opened this issue May 10, 2017 · 8 comments
Assignees
Labels
Milestone

Comments

@mburger81
Copy link

Short description of the problem:

I have two questions or bugs to communicate, perhaps the first one we already discussed it some months ago, I think it should be resolved but to my side it was never resolved and is still there, so I'm not sure if it is or it is not a bug or if it is by design.

  1. Should we are able to call ionic cordova run -c and ionic cordova emulate -c without passing the -l for livereload? Passing the console parameter without livereload parameter seems to have no impact.
    If we can not call console without livereload it is much more difficult debugging app on device in production mode, so without IonicDevServer launched and others. Is this by design, is this a bug?
    In ionic console docs, there is nothing written about if the -l is mandatory for -c

  2. the Other problem which is a little bit annoying, if we have a console log with two parameter like that console.log('First part', 'Second part'); the output in the console for emulator is like that
    [14:18:34] error opening ws message: {"category":"console","type":"log","data":["First part","Second part"]}
    So in this case the output is not readable and that's annoying, is this by design, is this a bug or can we do something to prevent this?

Post the output of ionic info below please

ionic info

global packages:
    @ionic/cli-utils : 1.0.0
    Cordova CLI      : 7.0.0 
    Ionic CLI        : 3.0.0

local packages:
    @ionic/app-scripts              : 1.3.7
    @ionic/cli-plugin-cordova       : 1.0.0
    @ionic/cli-plugin-ionic-angular : 1.0.0
    Ionic Framework                 : ionic-angular 3.0.1

System:
    Node       : v6.10.2
    OS         : Linux 4.10
    Xcode      : not installed
    ios-deploy : not installed
    ios-sim    : not installed
@imhoffd imhoffd added this to the CLI Future milestone May 10, 2017
@imhoffd imhoffd added the bug label May 10, 2017
@imhoffd
Copy link
Contributor

imhoffd commented May 10, 2017

For part 1: -l should be required for -c to work. This was not communicated well and is an easy fix.

For part 2: You're probably using Android, because you're on Linux. I'm assuming console.log being quirky with multiple arguments is due to this: https://cordova.apache.org/docs/en/latest/reference/cordova-plugin-console/#android-quirks

@mburger81
Copy link
Author

mburger81 commented May 10, 2017

Okay thx it would be better if you document the parameter and their combination better.
I can't remember but I wasn't sure if the log was never working on device.
BTW perhpase you can help us.
What is the best way to debug on real devices? Often we need to debug and to log.
We do not want use a mail or db logging so for now we simple use toast messages.
But for sure there is a better method, which is the best in your opinion?

@imhoffd imhoffd modified the milestones: CLI 3.0.1, CLI Future May 10, 2017
@imhoffd
Copy link
Contributor

imhoffd commented May 10, 2017

@mburger81 I did some digging and I think I'm wrong on both accounts. Sorry. I myself am still unfamiliar with the magic behind the scenes.

@jthoms1 Can we clear things up here?

@imhoffd imhoffd assigned imhoffd and jthoms1 and unassigned imhoffd May 10, 2017
@imhoffd imhoffd modified the milestones: CLI Future, CLI 3.1.0 May 15, 2017
@mburger81
Copy link
Author

@dwieeb
The bug is not show in Milestone CLI 3.1.0? When do you think you will release this?

If I can I will call your attention to another bug for which I'm waiting to have an response: #2263 I think this is very urgent too.
thx

@mburger81
Copy link
Author

This is not resolved in version 3.1 and also not in version 3.2

@imhoffd
Copy link
Contributor

imhoffd commented Aug 15, 2017

Hi @mburger81 sorry for the huge delay. I finally got around to fixing this. It'll be fixed with the next version of app-scripts.

@imhoffd imhoffd modified the milestones: CLI Future, 3.9.0 Aug 16, 2017
imhoffd added a commit that referenced this issue Aug 16, 2017
@mburger81
Copy link
Author

mburger81 commented Aug 16, 2017

Hi @dwieeb ok good news to hear :)
On your old post you wrote "I think I'm wrong on both accounts", so this commit is resolving the parameters problem, whats about the second one with the console log on android? I think in meantime for my one this is really a problem of android and you can't resolve it? :) Or can you?
thx

EDIT:
Ok I saw, the app-scripts commit is resolving the problem with the console log on android and the cli commit is resolving the problem with the parameters.
right?

@imhoffd
Copy link
Contributor

imhoffd commented Aug 16, 2017

@mburger81 Correct, both were our fault. 😂

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants