Giter VIP home page Giter VIP logo

Comments (8)

TimoGlastra avatar TimoGlastra commented on July 19, 2024

Is this bug introduced with the updates to AFJ? Is the connection successfully created?

from aries-mobile-agent-react-native.

amanji avatar amanji commented on July 19, 2024

It looks like the connections is correctly established. I don't think the issue was introduced with AFJ updates (since I've observed the same issues before the latest update) Here is a screenshot of the workflow for accepting a VC. After the screen goes blank, I have to restart the app and I can then see the connection and notification to accept the credential.

Update:
The issue stems from setting the RNCamera component to inactive subsequent to a connection being set, but there is no workflow to proceed after the fact (ex. navigation event, etc.) so the screen stays blank.

Screen.Recording.1080p.mov

from aries-mobile-agent-react-native.

amanji avatar amanji commented on July 19, 2024

I believe the fix should be to navigate to the Home Screen after a scan is successful:

Here is the current block that handles code scanning:

  const handleCodeScan = async (event: BarCodeReadEvent) => {
    setModalVisible('pending')
    try {
      const connectionRecord = await agent?.connections.receiveInvitationFromUrl(event.data, {
        autoAcceptConnection: true,
      })
      setConnectionId(connectionRecord.id)
      // --> Navigate back home here?
    } catch {
      setModalVisible('failure')
    }
  }

Or perhaps in the hook:

  useEffect(() => {
    if (connection?.state === ConnectionState.Complete) {
      setModalVisible('success')
      // --> Navigate back home here?
    }
  }, [connection])

Unless there is supposed to be a different workflow imitated after a connection is established.

from aries-mobile-agent-react-native.

TimoGlastra avatar TimoGlastra commented on July 19, 2024

I'm not too familiar with this code. Maybe @JamesKEbert or @NeilSMyers have some insights here?

from aries-mobile-agent-react-native.

JamesKEbert avatar JamesKEbert commented on July 19, 2024

Yeah this would be a workflow thing vs an AFJ issue (since the connection is being established). But yes, if you wanted to forward them to the home screen after they've connected (potentially even after a 3-5 second timeout), I'd recommend the second code block you mentioned with the useEffect:

   if (connection?.state === ConnectionState.Complete) {
     setModalVisible('success')
        // --> Navigate back home here?
      }
    }, [connection])

from aries-mobile-agent-react-native.

oznfc avatar oznfc commented on July 19, 2024

ı want to use sovring staging network and this example(https://email-verification.vonx.io/). When ı scan the Qr code my screen waiting Failure and ı must close app.I added genesis codes to config/ledgers/indy/indico-test-net . I added genesis url to env file. what is the problem ?

from aries-mobile-agent-react-native.

amanji avatar amanji commented on July 19, 2024

@oznfc if you're using the latest code you no longer need to specify a genesis url in the .env file. AFJ now has multi-ledger support and the mobile application is configured with both Indicio Test Net and Sovrin Staging ledgers by default (although you can add and remove ledgers based on your needs). You will still need to specify a mediator url in the .env file. Are you using the latest commit on main?

from aries-mobile-agent-react-native.

oznfc avatar oznfc commented on July 19, 2024

yes ı updated again today. I added only

GENESIS_URL= https://raw.githubusercontent.com/sovrin-foundation/sovrin/master/sovrin/pool_transactions_sandbox_genesis

to env file.
When ı scan the Qr code my screen waiting on pending secreen and ı must close app. when ı opened app again. ı can see my connection on contact screen. error this : normaly when scaned my qr code by Trinsic wallet. I'm connecting and ı 'm getting message for credential. but ı can not getting credential message in this app.

from aries-mobile-agent-react-native.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.