atymic

atymic

I'm a full stack developer from Australia. I maintain @laravel-notification-channels, @SocialiteProviders and @geocoder-php.

Member Since 2 years ago

Australia

Experience Points
149
follower
Lessons Completed
3
follow
Lessons Completed
199
stars
Best Reply Awards
156
repos

3712 contributions in the last year

Pinned
⚡ Twitter API for Laravel 5.5+, 6.x, 7.x & 8.x
⚡ The most featured Geocoder library written in PHP.
⚡ Test, Run & Share Laravel Collection Examples!
⚡ A package to simplify automating future notifications and reminders in Laravel
⚡ Generate Data Transfer Objects directly from JSON objects
⚡ Deploy PHP projects using Deployer from Github Actions
Activity
Oct
22
6 days ago
Activity icon
delete

atymic in atymic/vapor-core delete branch feat/secret-env

deleted time in 6 days ago
Activity icon
created branch

atymic in atymic/vapor-core create branch master

createdAt 6 days ago
Activity icon
delete

atymic in atymic/vapor-core delete branch master

deleted time in 6 days ago
push

atymic push atymic/vapor-core

atymic
atymic

[2.x] Allows persisting database sessions between queue jobs (#97)

  • Allows to persist database connections on queue lambda

  • Apply fixes from StyleCI

  • Fixes comparision

  • Update QueueHandler.php

  • Update QueueHandler.php

Co-authored-by: Taylor Otwell [email protected] Co-authored-by: Taylor Otwell [email protected]

commit sha: 8ee48b3a8effc0a3724a913ef0b9152bc02c7904

push time in 6 days ago
push

atymic push atymic/vapor-core

atymic
atymic

[2.x] Allows persisting database sessions between queue jobs (#97)

  • Allows to persist database connections on queue lambda

  • Apply fixes from StyleCI

  • Fixes comparision

  • Update QueueHandler.php

  • Update QueueHandler.php

Co-authored-by: Taylor Otwell [email protected] Co-authored-by: Taylor Otwell [email protected]

commit sha: 2c0875a95e51b4788ed9333af754d27c3e9abced

push time in 6 days ago
Oct
21
1 week ago
Activity icon
issue

atymic issue comment atymic/json2dto

atymic
atymic

When keys have a duplicate value, their DTO get overwritten

I was fetching some posts with their corresponding insights data from the Facebook graph API into my Laravel app and wanted to generate their DTO's, but the result is missing some DTO's.

Here is the response for the facebook call

{
  "data": [
    {
      "insights": {
        "data": [
          {
            "name": "post_impressions",
            "period": "lifetime",
            "values": [
              {
                "value": 614
              }
            ],
            "title": "Lifetime Post Total Impressions",
            "description": "Lifetime: The number of times your Page's post entered a person's screen. Posts include statuses, photos, links, videos and more. (Total Count)"
          }
        ],
        "paging": {
          "previous": "xxxxxxxxxxxxxxx",
          "next": "yyyyyyyyyyyyyyy"
        }
      },
      "created_time": "2021-10-13T16:11:55+0000",
      "message": "Very important message"
    }
  ],
  "paging": {
    "cursors": {
      "before": "xxxxxxxxxxxxxxx",
      "after": "yyyyyyyyyyyyyyy"
    },
    "next": "zzzzzzzzzz"
  }
}

As you can see, there is paging for the data and paging for the insights, but the general response contains "data" aswell as the insights. When generating nested DTO's we only get 1 paging and 1 data DTO, while we expect 2.

Maybe we can keep track of the parent key and store children in their own folder/namespace?

atymic
atymic
Activity icon
issue

atymic issue atymic/twitter

atymic
atymic

getting error when installing

when I run command composer require atymic/twitter on a fresh laravel project, I get this error:

 Problem 1
    - atymic/twitter[3.1.0, ..., 3.1.13] require psr/log ^1.1 -> found psr/log[1.1.0, ..., 1.1.4] but the package is fixed to 2.0.0 (lock file version) by a partial update and that ve
rsion does not match. Make sure you list it as an argument for the update command.
    - Root composer.json requires atymic/twitter ^3.1 -> satisfiable by atymic/twitter[3.1.0, ..., 3.1.13].

How can I solve it?

Activity icon
issue

atymic issue comment atymic/twitter

atymic
atymic

getting error when installing

when I run command composer require atymic/twitter on a fresh laravel project, I get this error:

 Problem 1
    - atymic/twitter[3.1.0, ..., 3.1.13] require psr/log ^1.1 -> found psr/log[1.1.0, ..., 1.1.4] but the package is fixed to 2.0.0 (lock file version) by a partial update and that ve
rsion does not match. Make sure you list it as an argument for the update command.
    - Root composer.json requires atymic/twitter ^3.1 -> satisfiable by atymic/twitter[3.1.0, ..., 3.1.13].

How can I solve it?

Activity icon
published release [3.1.14]

atymic in atymic/twitter create published release [3.1.14]

createdAt 1 week ago
Activity icon
created tag

atymic in atymic/twitter create tag 3.1.14

createdAt 1 week ago
Activity icon
delete

atymic in atymic/twitter delete branch analysis-7awDgE

deleted time in 1 week ago
push

atymic push atymic/twitter

atymic
atymic

chore: style fixes

Co-authored-by: atymic [email protected]

commit sha: d02680e17d8b2192fb1cc042299f31d4d982f109

push time in 1 week ago
pull request

atymic pull request atymic/twitter

atymic
atymic

chore: style fixes

This pull request applies code style fixes from an analysis carried out by StyleCI.


For more information, click here.

pull request

atymic pull request atymic/twitter

atymic
atymic

Apply fixes from StyleCI

This pull request applies code style fixes from an analysis carried out by StyleCI.


For more information, click here.

Activity icon
created branch

atymic in atymic/twitter create branch analysis-7awDgE

createdAt 1 week ago
Activity icon
delete

atymic in atymic/twitter delete branch fix/psr-log

deleted time in 1 week ago
push

atymic push atymic/twitter

atymic
atymic

fix: psr log v2/v3 support (#379)

commit sha: 1e226a6d3591a6a55127c7042c8daae83210410e

push time in 1 week ago
pull request

atymic pull request atymic/twitter

atymic
atymic

fix: psr log v2/v3 support

pull request

atymic pull request atymic/twitter

atymic
atymic

fix: psr log v2/v3 support

Activity icon
created branch

atymic in atymic/twitter create branch fix/psr-log

createdAt 1 week ago
Activity icon
issue

atymic issue comment atymic/twitter

atymic
atymic

getting error when installing

when I run command composer require atymic/twitter on a fresh laravel project, I get this error:

 Problem 1
    - atymic/twitter[3.1.0, ..., 3.1.13] require psr/log ^1.1 -> found psr/log[1.1.0, ..., 1.1.4] but the package is fixed to 2.0.0 (lock file version) by a partial update and that ve
rsion does not match. Make sure you list it as an argument for the update command.
    - Root composer.json requires atymic/twitter ^3.1 -> satisfiable by atymic/twitter[3.1.0, ..., 3.1.13].

How can I solve it?

atymic
atymic

What version of laravel are you running?

Activity icon
issue

atymic issue atymic/twitter

atymic
atymic

getting error when installing

when I run command composer require atymic/twitter on a fresh laravel project, I get this error:

 Problem 1
    - atymic/twitter[3.1.0, ..., 3.1.13] require psr/log ^1.1 -> found psr/log[1.1.0, ..., 1.1.4] but the package is fixed to 2.0.0 (lock file version) by a partial update and that ve
rsion does not match. Make sure you list it as an argument for the update command.
    - Root composer.json requires atymic/twitter ^3.1 -> satisfiable by atymic/twitter[3.1.0, ..., 3.1.13].

How can I solve it?

Oct
20
1 week ago
Activity icon
issue

atymic issue cypress-io/cypress

atymic
atymic

Saving `cy.request` response fails, but only on the first run after opening cypress when `cy.visit` is not called first

Current behavior

Having a very weird issue. Basically, I am testing a integration in a software product. The flow is as follows:

  • Make post request to /auth endpoint to get a session
  • Load some data using a post request (ie, not from browser)
  • Open browser and load a URL, which has the data present (it uses the session from auth request.

In cypress, we are calling cy.request() twice, before calling cy.visit(). When calling cy.visit() the browser appears to flash and reset.

The last request call stores some data using .as

In the next step (see example code), we get this data. On the first run of cypress, the data is undefined (seems related to the refresh of the screen)

On subsequent runs, it works fine.

I accidently managed to fix it by making a cy.visit() call before any cy.request() calls. This means the weird refresh happens before the step with the issue, and thus the data persists across properly.

Any ideas? Thanks

Desired behavior

No response

Test code to reproduce

describe('test', function () {
  beforeEach(() => {
    Cypress.Cookies.preserveOnce('PHPSESSID')
    cy.fixture('merge.txt').as('mergeData')
  })

  it('can authenticate with api', () => {
    cy.request({
      method: 'POST',
      url: `/authentication`,
      body: { email },
      auth: { user, pass },
      form: true,
    }).as('auth')

    cy.get('@auth').should((response) => {
      expect(JSON.parse(response.body)).to.have.property('authenticate')
    })
  })

  it('can load merge data into api', function () {
    cy.request({
      method: 'POST',
      url: `/load-merge`,
      body: this.mergeData,
      auth: { user, pass },
      headers: { 'content-type': 'application/x-www-form-urlencoded' },
    }).as('merge')

    cy.get('@merge').should((response) => {
      expect(JSON.parse(response.body)).to.have.property('session')
    })

    cy.get('@merge').its('body').as('mergeResponse')
  })

  it('Can  and fill out merge sms form', function () {

    const sessionId = JSON.parse(this.mergeResponse).session
    // random refresh seems to happen here, and the step restarts from the start, and errors when its tries to access mergeResponse
    cy.visit(`merge?email=${email}&session=${sessionId}`)
  })
})

Cypress Version

8.6.0

Other

No response

Previous